issues to decode h.264 loss less format

issues to decode h.264 loss less format

Hi,I've tryed to decode a couples of video files having AVC/h264 loss less format using sample_decode compiled from Intel Media SDK 3.0 sample code.However decoding failed after a couple of seconds from it had been started with error (-10) at pipelile_decode.cpp, line 40 -> validation of m_FileReader.ReadNextFrame() statusThe input file according to MediaInfo has the following parameters:=======================================================================GeneralComplete name : C:\\Program Files\\Intel\\Media SDK\\3.0.442.32245 Beta3\\samples\\_build\\x64\\Debug\\test.aviFormat : AVIFormat/Info : Audio Video InterleaveFile size : 637 MiBDuration : 2mn 10sOverall bit rate : 41.0 MbpsWriting library : VirtualDub build 32842/releaseVideoID : 0Format : AVCFormat/Info : Advanced Video CodecFormat profile : High 4:4:4 Predictive@L3.1Format settings, CABAC : YesFormat settings, ReFrames : 1 frameCodec ID : H264Duration : 2mn 10sBit rate : 41.0 MbpsWidth : 480 pixelsHeight : 270 pixelsDisplay aspect ratio : 16:9Frame rate : 50.000 fpsColor space : YUVChroma subsampling : 4:2:0Bit depth : 8 bitsScan type : ProgressiveBits/(Pixel*Frame) : 6.329Stream size : 636 MiB (100%)Writing library : x264 core 811799308Sep 8 2010Encoding settings : cabac=1 / ref=1 / deblock=0:0:0 / analyse=0x3:0x113 / me=hex / subme=5 / psy=1 / psy_rd=0.0:0.0 / mixed_ref=0 / me_range=16 / chroma_me=1 / trellis=0 / 8x8dct=1 / cqm=0 / deadzone=21,11 / chroma_qp_offset=0 / threads=6 / nr=0 / decimate=1 / mbaff=0 / bframes=0 / keyint=250 / keyint_min=1 / scenecut=40 / rc=cqp / mbtree=0 / qp=0=================================================================|My guess, that h264 loss less format isn't supported by Intel Media SDK or by specific example.Anyway, I succeed to decode other h264 encoded videos including AVCHD/h264 HD video.PSI succeed to convert video file encoded by h264 loss less format to YUV format using ffmpeg.The resulting YUV file was played by YUV Player Deluxe.As well, I succeed to encode it back to theregular (not loss less)h264 format using example_encode.exe.The output h264 file has been decoded fine (back to YUV format) using sample_decode.exe, but I had issues to play it with VLC player.Thanks in advance,Ze'ev

9 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Hi Ze'ev,

Thanks for reporting this. We have been able to reproduce that Media SDK sample_decode is having issues decoding H.264 streams encoded with qp=0 (lossless).

We are exploring if this use case is something our decoder should be able support or not.I'll provide some feedback shortly.

However, I have one note regarding what you report. It looks like the file you input to the decoder is an AVI container file? Media SDK does not support demuxing of containers into elementary video streams (ES). Either your AVI file is actully an ES or you are getting lucky with regards to parsing the binary file.

Regards,Petter

Hi Peter,

The tested videos were recorded by camera without audio codec using h264 loss less video codec.
Anyway, I extracted video stream before it processed by sample_decode.
I have another question regarding to performance using SW acceleration mode: the sample_decode is significantly slow than sample_decode (sample_decode, probably is working in frame rate of video file, that may be seen when selected -r option, i.e. make decoding in different window). In both cases, the CPU was not fully utilized. In contradiction, x264 and ffmpeg utilizes 80-100% of CPU. I didn't measure actual performance, i.e. frames per second, but may be is there any way to accelerate encoding/decoding with Intel MSDK (so CPU usage will grow up from 10-60% to 80-100%) ?

Regards,
Ze'ev

Hi Ze'ev,

The Media SDK encode or decode samples are not good at all for estimating performance.Consider the fact that the samples are writing or reading very large uncompressed frames to/from the disk.

Regards,Petter

Hi Petter,

My project is intended to provide HD video data (as RGB frames) to image processing unit for real time tracking. As result I will deal with very large uncompressed frames, that situation may be very similar to encode/decode implementation of Media SDK samples mentioned by you.
Anyway if H264 lossless format will not be supported by Media SDK, it will be useless for the project.
Please let me know, if the support for H264 lossless format will be added.

Some other question, Intel Media SDK in SW mode is using DirectShow memory buffers, if means that SW option utilizes Microsoft DXVA optimization or used other kind of optimization ?

Thanks a lot for your support,
Ze'ev

Hi Ze'ev,

May I ask why H.264 lossless is important to you? Considering the very low compression, you will have to deal with huge amounts of data.

I will get back to you on Media SDK H.264 decode lossless support as soon as we have analyzed the issue completely.

Regarding your last question. I'm sorry, but I don not exactly understand what you ask for. For optimal performance the sample DirectShow codec filters will use D3D surface memory in case of HW acceleration and system memory surfaces in case of SW processing.

Regards,Petter

Hi Petter,

The lossless format is required for image processing. My question was if SW version of H264 decoding provided by Media SDK is using DirectShow. Accordimg to my tests, DXVA has issues with lossless format too ... at least Media Player (http://en.wikipedia.org/wiki/Media_Player_Classic) is stopping to use DXVA for video encoded in lossless format.

Regards,
Ze'ev

Hi Ze'ev,

I still do not fully understand your question. There is no relation between Intel Media SDK and DirectShow. However, there is a set of sample code that wraps Media SDK codecs in DirectShow filters.

Regards,Petter

Hi again Ze'ev,

I can confirm that we do not support H.264 loss-less decode in Media SDK, and we do not plan to add this feature anytime soon. The primary reason for this is that DXVA does not support loss-less H.264 decode profile.

I hope you still will find Intel Media SDK useful for your needs.

Regards,Petter

Leave a Comment

Please sign in to add a comment. Not a member? Join today