[Libav-user] get frame type
Robert Krüger
krueger at lesspain.de
Tue Mar 20 12:20:45 CET 2012
On Mon, Mar 19, 2012 at 11:54 AM, Carl Eugen Hoyos <cehoyos at ag.or.at> wrote:
> Zanelli Franco <fzanelli at ...> writes:
>
>> int got_picture;
>> int len = avcodec_decode_video2(codecCtx, avFrame, &got_picture, avPacket);
>>
>> at this point, is it possible to get the input frame type (intra, P or B
>> frame)?
>
> Did you try to read avFrame->pict_type ?
>
>
does this field have any meaning for h.264? I thought a frame could
consist of a mixture of B- P- and I-slices. What is the policy of the
h.264 decoder to set this field currently? I haven't checked recently
but I remember it to have weird values for the h.264 files I checked.
I can check again, if that helps.
More information about the Libav-user
mailing list