Media (Intel® Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools like Intel® oneAPI Video Processing Library and Intel® Media SDK
Announcements
The Intel Media SDK project is no longer active. For continued support and access to new features, Intel Media SDK users are encouraged to read the transition guide on upgrading from Intel® Media SDK to Intel® Video Processing Library (VPL), and to move to VPL as soon as possible.
For more information, see the VPL website.

An error occurs when executing sample_decvpp in MediaSamples_Windows_6.0.0.68.

Intel_C_
Novice
503 Views

 

I refer to sample_decvpp in MediaSamples_Windows_6.0.0.68 using MfxVideoVPP.
However, the following error occurs while executing the Sample code:
CDecodingPipeline :: AllocFrames ()
{
............
Sts = m_pmfxVPP-> Query (& m_mfxVppVideoParams, & m_mfxVppVideoParams); // <- error, sts = MFX_ERR_NULL_PTR
............
}}

I tried to use:
Sts = m_pmfxVPP-> Query (NULL, & m_mfxVppVideoParams);
Or
MfxVideoParam m_mfxOutVppVideoParams
Sts = m_pmfxVPP-> Query (& m_mfxVppVideoParams, & m_mfxOutVppVideoParams);
The result is the same.

What is the problem?
How do I use VPP correctly?


Development Environment:
Win10
Vs2013
Intel (R) _Media_SDK_2016
Intel (R) HD Graphics 4600
Driver version: 10.18.15.4256

0 Kudos
1 Solution
Intel_C_
Novice
503 Views

I've figured out why.
The sample code in mfx_pipeline_decvpp.cpp line 426~437 Is below: 

#if MFX_D3D11_SUPPORT
    if (D3D11_MEMORY == m_memType)
        m_hwdev = new CD3D11Device();
        if (m_hwdev) {
            reinterpret_cast<CD3D11Device *>(m_hwdev)->DefineFormat((m_fourcc == MFX_FOURCC_A2RGB10) ? true: false);
        }
    else
#endif // #if MFX_D3D11_SUPPORT
        m_hwdev = new CD3D9Device();
        if (m_hwdev) {
            reinterpret_cast<CD3D9Device *>(m_hwdev)->DefineFormat((m_fourcc == MFX_FOURCC_A2RGB10) ? true: false);
        }

Must be fixed to the following code:

#if MFX_D3D11_SUPPORT
	if (D3D11_MEMORY == m_memType){
		m_hwdev = new CD3D11Device();
		if (m_hwdev) {
			reinterpret_cast<CD3D11Device *>(m_hwdev)->DefineFormat((m_fourcc == MFX_FOURCC_A2RGB10) ? true : false);
		}
	}
	else
#endif // #if MFX_D3D11_SUPPORT
	{
		m_hwdev = new CD3D9Device();
		if (m_hwdev) {
			reinterpret_cast<CD3D9Device *>(m_hwdev)->DefineFormat((m_fourcc == MFX_FOURCC_A2RGB10) ? true : false);
		}
	}

Can solve this problem.

View solution in original post

0 Kudos
2 Replies
Intel_C_
Novice
503 Views

I found the cause of the problem,
When the command line argument is
>>H264 -hw -d3d11 -i "C: \ Program Files (x86) \ IntelSWTools \ Intel (R) _Media_SDK_2016.0.2 \ samples \ 6.0.0.68 \ _build \ Win32 \ Debug \ 1080p.avi" -r
Will fail.
>>H264 -hw -d3d -i "C: \ Program Files (x86) \ IntelSWTools \ Intel (R) _Media_SDK_2016.0.2 \ samples \ 6.0.0.68 \ _build \ Win32 \ Debug \ 1080p.avi" -r
success

VPP can only use d3d9 device?

0 Kudos
Intel_C_
Novice
504 Views

I've figured out why.
The sample code in mfx_pipeline_decvpp.cpp line 426~437 Is below: 

#if MFX_D3D11_SUPPORT
    if (D3D11_MEMORY == m_memType)
        m_hwdev = new CD3D11Device();
        if (m_hwdev) {
            reinterpret_cast<CD3D11Device *>(m_hwdev)->DefineFormat((m_fourcc == MFX_FOURCC_A2RGB10) ? true: false);
        }
    else
#endif // #if MFX_D3D11_SUPPORT
        m_hwdev = new CD3D9Device();
        if (m_hwdev) {
            reinterpret_cast<CD3D9Device *>(m_hwdev)->DefineFormat((m_fourcc == MFX_FOURCC_A2RGB10) ? true: false);
        }

Must be fixed to the following code:

#if MFX_D3D11_SUPPORT
	if (D3D11_MEMORY == m_memType){
		m_hwdev = new CD3D11Device();
		if (m_hwdev) {
			reinterpret_cast<CD3D11Device *>(m_hwdev)->DefineFormat((m_fourcc == MFX_FOURCC_A2RGB10) ? true : false);
		}
	}
	else
#endif // #if MFX_D3D11_SUPPORT
	{
		m_hwdev = new CD3D9Device();
		if (m_hwdev) {
			reinterpret_cast<CD3D9Device *>(m_hwdev)->DefineFormat((m_fourcc == MFX_FOURCC_A2RGB10) ? true : false);
		}
	}

Can solve this problem.

0 Kudos
Reply