This Intel® Media SDK tutorial sample is essentially the same as the "simple_5_transcode" sample except for that it uses D3D surfaces instead of system memory surfaces.
Like the "simple_2_decode" tutorial sample this sample supports both Microsoft DirectX* 9 and DirectX* 11 for Windows and VAAPI for Linux. For more details on this topic please refer to "simple_2_decode" sample description.
The use of GPU memory surfaces leads to improved performance. In essence the behavior of this workload is the same as for "simple_5_transcode_opaque" (when executed on a processor that supports HW acceleration). However, since the application manages video memory these surfaces are available to integrate with components that are not in the standard Intel Media SDK decode->process->encode pipeline.
This tutorial sample is found in the tutorial samples package under the name "simple_5_transcode_vmem". The code is extensively documented with inline comments detailing each step required to setup and execute the use case.