[FFmpeg-devel] [PATCH] Do not override pix_fmt in rawdec.c
Tomas Härdin
tomas.hardin
Mon Jun 7 14:30:34 CEST 2010
On Mon, 2010-06-07 at 12:54 +0200, Michael Niedermayer wrote:
> On Mon, Jun 07, 2010 at 11:01:23AM +0200, Tomas H?rdin wrote:
> > Hi
> >
> > The attached patch adds a check for pix_fmt == PIX_FMT_NONE before
> > attempting to guess it near rawdec.c:75. This enables demuxers to set it
> > directly if known in advance (for example mxfdec.c).
> >
> > Patch passes regtests.
>
> violates api
> /**
> * Pixel format, see PIX_FMT_xxx.
> * - encoding: Set by user.
> * - decoding: Set by libavcodec.
> ^^^^^^^^^^^^^^^^^^^^^
> this doesnt say set by "user" aka libavformat/app
> */
> enum PixelFormat pix_fmt;
What would be a reasonable way to deal with it? Have a user_pix_fmt or
something like that?
In general we can't rely on codec_tag (identical for all rawvideo in
mxf) or bits_per_coded sample (can't distinguish between rgb and bgr),
and adding hacks for every demuxer seems wrong.
/Tomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20100607/72f0568d/attachment.pgp>
More information about the ffmpeg-devel
mailing list