[Ffmpeg-devel] [Ffmpeg-devel-old] Questionaboutinterlaced_frame and top_field_first

Diego Biurrun diego
Thu Feb 2 15:17:34 CET 2006


On Mon, Jan 30, 2006 at 12:32:59PM +0100, Michael Niedermayer wrote:
> 
> On Mon, Jan 30, 2006 at 12:10:18PM +0100, Luca Abeni wrote:
> > 
> > On Mon, 2006-01-30 at 10:17 +0100, Luca Abeni wrote:
> > [...]
> > > So, I think raw_decode() should be fixed to copy the fields form
> > > coded_frame to the decoded frame... Or am I misunderstanding how things
> > > work?
> > > 
> > > BTW, I see that raw_decode() does this:
> > > static int raw_decode(AVCodecContext *avctx,
> > >                             void *data, int *data_size,
> > >                             uint8_t *buf, int buf_size)
> > > {
> > >     RawVideoContext *context = avctx->priv_data;
> > >     int bytesNeeded;
> > > 
> > >     AVPicture * picture = (AVPicture *) data;
> > > [...]
> > > 
> > > I think this "AVPicture * picture" should be changed in "AVFrame *",
> > > right?
> > > I'll try to patch raw.c in such way, to see if this idea works.
> > Ok, I did this, and it works. I attach the patch for libavcodec/raw.c
> > 
> > If the patch is accepted and applied, I think libavformat/yuv4mpeg.c
> > (and maybe other) can be patched to take advantage of it and correctly
> > set interlaced_frame and top_field_first.
> 
> patch looks ok, can be applied

Patch applied.  Luca, we're waiting for your patches to yuv4mpeg.c and
the other files now :)

Diego





More information about the ffmpeg-devel mailing list