[FFmpeg-devel] [PATCH 5/7] CrystalHD: Bring in h.264 parser to establish picture type.
Reimar Döffinger
Reimar.Doeffinger at gmx.de
Sun Mar 27 19:00:46 CEST 2011
On Sun, Mar 27, 2011 at 09:33:59AM -0700, Philip Langdale wrote:
> On Sun, 27 Mar 2011 10:43:40 +0200, Michael Niedermayer
> <michaelni at gmx.at> wrote:
> >On Sun, Mar 27, 2011 at 07:22:45AM +0200, Reimar Döffinger wrote:
> >>
> >>
> >>On 26 Mar 2011, at 18:50, Philip Langdale <philipl at overt.org> wrote:
> >>
> >>> As the hardware is unreliable, we will have to use the h.264
> >>parser
> >>> to identify whether an input picture is a field or a frame. This
> >>> change loads the parser and extracts the picture type.
> >>
> >>I think there is a way to tell the parser not to do any parsing
> >>(in particular, not search for start codes) but only parse.
> >>Libavcodec/avidec.c uses it like that.
> >
> >see AVSTREAM_PARSE_HEADERS and PARSER_FLAG_COMPLETE_FRAMES
>
> But I don't see how this would work. The decoding of the picture
> structure is done by parse_nal_units() in the
> !PARSER_FLAG_COMPLETE_FRAMES
> path.
Hm, that is suspicious, avidec.c has specifically:
st->need_parsing = AVSTREAM_PARSE_HEADERS; // This is needed to get the pict type which is necessary for generating correct pts.
If that does not actually parse headers I guess somethings are going wrong.
More information about the ffmpeg-devel
mailing list