Media (Intel® oneAPI Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools from Intel. This includes Intel® oneAPI Video Processing Library and Intel® Media SDK.

Intel MediaSDK MFXVideoEncode::Query Formats

Scannell__Kevin
Beginner
277 Views

Hello,

I'm attempting to write an h.264 encoder based on the simple_3_encode_vmem_async sample that can use the WARP feature of DirectX11.1. However, there seems to be a format conflict.

For MFXVideoEncode::Query() to succeed, the following flags need to be set:

m_mfxEncParams.mfx.FrameInfo.FourCC = MFX_FOURCC_NV12;
m_mfxEncParams.mfx.FrameInfo.ChromaFormat = MFX_CHROMAFORMAT_YUV420;

As far as I can tell, any other values cause a return value of MFX_ERR_UNSUPPORTED. Later, when we try to call g_pD3D11Device->CreateTexture2D(&desc, NULL, &pTexture2D);, it fails. Using the D3D11_CREATE_DEVICE_DEBUG flag, we can see an ouput of "ID3D11Device::CreateTexture2D: Invalid format. The format (0x67, NV12) is not supported as a decoder output."

Is there any way to initialize the decoder with other image formats, so that a device of type D3D_DRIVER_TYPE_WARP can create textures?

 

Thank you.

0 Kudos
0 Replies
Reply