[FFmpeg-devel] [PATCH] Only using st->parser->pos when doing repacking in the parser.

Reimar Döffinger Reimar.Doeffinger at gmx.de
Mon May 9 00:05:09 CEST 2011

On Sun, May 08, 2011 at 11:41:48PM +0200, Michael Niedermayer wrote:
> On Sun, May 08, 2011 at 07:12:36AM +0200, Reimar Döffinger wrote:
> > That is why this approach, please don't take it as offence, feels like hacking around to try to avoid fixing parser output to have some sensible values.
> Iam not offended by that but i think our disagreement comes from this:
> I feel that frame_offset is a parser internal variable and its already
> a hack to use it like is done. And now modifying this parser internal
> variable to make this use work feels risky to me. Maybe it would work
> out but maybe it would break some parser in some corner case.

I do understand that, which is why I came up with my latest patch,
and I am not convinced which is really better.
The idea there was to actually _not_ use that offset from the parser,
but just use the packet positions.
The only intentional difference to your approach is to pass it through
the buffering so it will compensate for any delay caused by the parser.
I guess there is an unintentional one that the data the parser sees
changes, I didn't look at that, but I'd expect that that should be

More information about the ffmpeg-devel mailing list