Scaling with DXVA2.0

Hi,

I’m currently studying the DXVA2.0 device management and video processing and I wonder if you could help me with the following trouble:

I’m want to build a MFT who doe’s video processing on video source, one of the features I want to offer is the ability to use the hardware scaling capabilities instead of my software algorithms. Therefore, I came up with some basic questions:

1. When setting the video position by the IMFVideoDisplayControl interface to a larger destination rectangle then the source rectangle – how can I ensure that the resizing is done by the hardware and not software

2. Is there a way to implement scaling using the IDirectXVideoProcessor::Video ProcessBlt in my MFT so I could actually continue performing other processing on my video sample As I understand it, the result is written to the target IDirect3DSurface9 object and I didn’t find a way to “pull” the video sample from it.

I believe that answers to those questions would really help me.

Thanks in advance,

Uri




Answer this question

Scaling with DXVA2.0

  • jchau

    1) The IMFVideoDisplayControl interface is exposed by the EVR. The EVR uses DXVA2 hardware, when available, to perform scaling through the video processor exposed by the video card driver. When hardware is not available, it uses software.

    2) In the MF pipeline, an MFT indicates that it is DXVA2 aware by specifying TRUE as the attribute value for the UINT32 attribute MF_SA_D3D_AWARE. When this attribute is found to be true, ProcessMessage is called on the MFT with message MFT_MESSAGE_SET_D3D_MANAGER and a pointer to the IDirect3DManager9 interface is given. Additionally, the MFT is now expected to be the sample allocator on the output. You should therefore allocate your own output surfaces.

    Jay Senior - This information is provided as-is and conveys no rights.



  • Scaling with DXVA2.0