[FFmpeg-devel] [PATCH] lavc/rawdec: Only use AV_PIX_FMT_PAL8 for 1 bpp video
Mats Peterson
matsp888 at yahoo.com
Sun Jan 31 15:16:46 CET 2016
On 01/31/2016 03:07 PM, Michael Niedermayer wrote:
> indeed, i should have clearly stated that i applied the pal8
> patches with the plan to use pal8 only when neccessary.
> I had asked you to implement exactly that but it seemed you didnt
> know how to do that cleanly and simply so i thought "no problem,
> i know how to do that, ill do it"
> i had not expected this to be controversal
>
Well, it would have been nice to know that you did it at least. I had no
idea until you mentioned it.
> basically 100% of avis with monowhite are black&white, we do not have
> a single (no craftet) sample that contains paletted monochrome data
> in avi.
> IMHO its bizare to convert black and white 1 bpp data in the decoder
> to 8bit paletted data
> we reject colorspace/pixel format converting in the decoder normally
> unless its somehow a mess otherwise.
>
> and its a problem to for using the output because an encoder has to
> deal and encode 8bit paletted data from such avis even though they
> really are just black and white if pal8 is used
>
It's not bizarre at all. Black & white is just a variant of palettized
data in this context, it's not monochrome. And just because you don't
have a non-b/w sample, it doesn't mean you should use monow. A 1 bpp AVI
is not monochrome once again, it's palettized, even if it's only with
black & white. The same semantics as with 1 bpp depth in QuickTime.
And since you don't have a "pal2" or "pal4" format, it suddenly seems
perfectly OK to convert this to pal8? THere's no logic in this.
Mats
More information about the ffmpeg-devel
mailing list