[Ffmpeg-devel] AVPaletteControl removal from libavf (was Re: [MPlayer-dev-eng] [PATCH] (bit hackish) palette support for libav*)
Tue Jan 30 14:54:40 CET 2007
On Tue, Jan 30, 2007 at 02:30:06PM +0100, Michael Niedermayer wrote:
> On Tue, Jan 30, 2007 at 01:56:00PM +0100, Reimar Doeffinger wrote:
> > > also i would pass the palette like a normal video frame into the decoder
> > > instead of using AVCodecContext
> > Sure, that would be preferable, but how to tell the decoder this is a
> > palette? Adding a flag parameter to the decode function? That would make
> > for quite a huge patch a (and a lot of work to make it)...
> > Advantage: that way could also be used for some other kinds of "extradata".
> my hope would be that the decoder could figure out that a packet contains a
> palette witout any additional info
Thus probably duplicating complexity from the demuxer in this case. And
I don't have any idea how this should be possible e.g. in the case of
raw video e.g. in AVI. If course, that has only one palette that could
be passed via extradata, but that does not seems like a clean solution
Another solution would be to do something currently reserved like
passing a NULL pointer as "int *data_size" parameter. Hackish with the
beautiful side effect of crashing most decoders on palette packets.
Would be also possible to somehow mark the palette specially in the
demuxer, but that kind of stuff IMO does not belong into the demuxer any
more than palette conversion.
More information about the ffmpeg-devel