[Libav-user] Extracted I-Frames seems not correct, Why?

Alex Cohn alexcohn at netvision.net.il
Thu May 17 08:43:07 CEST 2012


On Thu, May 17, 2012 at 6:32 AM,  <amir.rouhi at rmit.edu.au> wrote:
> OMG, when i check the I-Frames by JM software, that software shows only 3
> I-Frames. how this is possible? please help me to understand where is my
> problem?

You can use ffmpeg debugging to learn more about your video stream.

ffmpeg -i C:\1adapt.264 -dump -debug pict -vcodec copy -y NUL

Enjoy,
Alex Cohn

> On 17 May 2012 12:05, <amir.rouhi at rmit.edu.au> wrote:
>>
>> I am confusing guys, i encountered a new problem in regard with adaptive
>> and fixed rate I-Frames by ffmpeg under windows. it is as below:
>> first i convert the original video (mpeg1) to the pure h.264 format by
>> below command for adaptive I-Frame rate:
>>
>> ffmpeg -i C:\1.mpg -r 25 -an -vcodec libx264 -threads 0  -f h264 -r 25 -g
>> 0 C:\1adapt.264  (-g 0 for adaptive I-frame rate)
>> ffmpeg -i C:\1.mpg -r 25 -an -vcodec libx264 -threads 0  -f h264 -r 25 -g
>> 25 C:\1fixed.264  (-g 25 for fixed I-frame rate every 25 frame one i-frame)
>>
>> I dont involve you about my first problem which was related to the twice
>> tbr value in the h264 transformed videos and their shorter time length (with
>> twice faster speed)
>>
>> my current problem is that when i want to use select filter to extract the
>> i-frames from the above 264 videos, it is natural that i expect different
>> results and for a 50sec video with -g 25 and 25fps, i expected 50 i-frames
>> but the result was exactly same and just 5 frames for both videos. the
>> select filter which i used can be seen at below:
>>
>> ffmpeg -i C:\1adapt.264 -vsync 0 -vf select="eq(pict_type\, PICT_TYPE_I)"
>> C:\I-Frm1adapt-%03d.jpeg
>> ffmpeg -i C:\1fixed.264 -vsync 0 -vf select="eq(pict_type\, PICT_TYPE_I)"
>> C:\I-Frm1fixed-%03d.jpeg
>>
>> both produce 5 image for a originally 50 sec video with 25fps tbr 25 which
>> after transformed reduced to 25 sec with 25fps but tbr 50. Its strange ,
>> isnt it?
>>
>> On 16 May 2012 18:48, Carl Eugen Hoyos <cehoyos at ag.or.at> wrote:
>>>
>>> Alex Cohn <alexcohn at ...> writes:
>>>
>>> > If I understand correctly, Amir complains about the
>>> > encoder, not the decoder.
>>>
>>> Then your answer was clearly more helpful than mine!
>>>
>>> Carl Eugen
>> --
>> Amir H. Rouhi
>> PhD Student/ CSIT RMIT University
>> Room: 14-09-04
>> http://raws.adc.rmit.edu.au/~s3288736/blog2/


More information about the Libav-user mailing list