Quantcast
Channel: Intel® Software - Media
Viewing all articles
Browse latest Browse all 2185

h264 problem in GetVideoParam

$
0
0

hi,

I'm trying to test the h264 encoder with ffmpeg muxer using the latest Media SDK 2013R2  in software mode and cannot get it to work, the encoding process is ok but the file created cannot be played.

First thing, the GetVideoParam function returns MFX_ERR_NONE but the buffers contents are not filled and bufffers size value not change:

            mfxU8 SPSBuffer[MAXSPSPPSBUFFERSIZE];
            mfxU8 PPSBuffer[MAXSPSPPSBUFFERSIZE];
   
            mfxExtCodingOptionSPSPPS m_extSPSPPS;
            MSDK_ZERO_MEMORY(m_extSPSPPS);
            m_extSPSPPS.Header.BufferId = MFX_EXTBUFF_CODING_OPTION_SPSPPS;
            m_extSPSPPS.Header.BufferSz = sizeof(mfxExtCodingOptionSPSPPS);
            m_extSPSPPS.PPSBuffer        = PPSBuffer;
            m_extSPSPPS.SPSBuffer        = SPSBuffer;
            m_extSPSPPS.PPSBufSize        = MAXSPSPPSBUFFERSIZE;
            m_extSPSPPS.SPSBufSize        = MAXSPSPPSBUFFERSIZE;
   
            mfxEncParams.ExtParam = new mfxExtBuffer *[1];
            mfxEncParams.ExtParam[0] = (mfxExtBuffer*)&m_extSPSPPS;
            mfxEncParams.NumExtParam = 1;
   
            // Retrieve encoder parameters incl. sequence header
            sts = mfxENC.GetVideoParam(&mfxEncParams);
--------------------- >
        returns sts= MFX_ERR_NONE
       
        m_extSPSPPS.SPSBuffer          contents untouched
        m_extSPSPPS.SPSBufSize      MAXSPSPPSBUFFERSIZE
        m_extSPSPPS.PPSBuffer        contents untouched
        m_extSPSPPS.PPSBufSize      MAXSPSPPSBUFFERSIZE

could be that the problem?

thanks in advance

Attached all the code.

AttachmentSize
Downloadcode.txt5.58 KB

Viewing all articles
Browse latest Browse all 2185

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>