locked
Direct3D 12 Video Decoding RRS feed

  • Question

  • I have an application using D3D11 video decoding with interfaces such as ID3D11VideoDevice, ID3D11VideoContext, ID3D11VideoDecoder etc which I would like to upgrade to Direct3D 12. However I cannot find any video decoding API in d3d12.h. Is that a not yet supported feature? If I render other stuff in Direct3D 12, do I have to be stuck doing the video decoding using D3D11 API interop? This is not an optimal approach if I have to use two sets of APIs and share resources in between.
     
    • Edited by llyzs.vic Wednesday, September 7, 2016 3:16 AM
    Tuesday, September 6, 2016 10:30 AM

Answers

  • D3D11On12 is an emulation layer which exposes a Direct3D 11 like API on top of Direct3D 12. It's intended to make things like existing Direct3D 11 libraries work in an otherwise Direct3D 12 program.

    What you actually want is the real Direct3D 11 device driving Direct3D 11 Video to render to a texture interoping with a Direct3D 12 device that renders that texture into a scene. See MSDN.



    Thursday, September 8, 2016 6:35 AM

All replies

  • You indeed have to use device interop to use Direct3D 11 Video with the DirectX 12 rendering APIs.
    Wednesday, September 7, 2016 7:05 AM
  • I tried to create ID3D11Device using D3D11On12CreateDevice() with D3D11_CREATE_DEVICE_VIDEO_SUPPORT flag set, and I successfully got the ID3D11Device instance. But when I tried to QueryInterface(ID3D11VideoDevice) on it I got E_NOINTERFACE. Am I doing something wrong or video decoding is not supported on D3D11on12?
    Wednesday, September 7, 2016 8:11 AM
  • D3D11On12 is an emulation layer which exposes a Direct3D 11 like API on top of Direct3D 12. It's intended to make things like existing Direct3D 11 libraries work in an otherwise Direct3D 12 program.

    What you actually want is the real Direct3D 11 device driving Direct3D 11 Video to render to a texture interoping with a Direct3D 12 device that renders that texture into a scene. See MSDN.



    Thursday, September 8, 2016 6:35 AM
  • OK thanks, I figured this is the only way to do it for now. Any idea when will native DX12 video decoding be supported?
    Friday, September 9, 2016 3:52 AM
  • I don't have any insight into the priorities here, but I would note that Windows Media was using Direct3D9Ex to render through all of Windows Vista and Windows 7, and was only updated to Direct3D 11 Video with Windows 8.

    Monday, September 12, 2016 5:37 AM