Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Intel_C_
Novice
90 Views

An error occurs when executing sample_decvpp in MediaSamples_Windows_6.0.0.68.

Jump to solution

 

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
90 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

2 Replies
Intel_C_
Novice
90 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?

Intel_C_
Novice
91 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

Reply