You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-15 14:13:16 +02:00
Set some Pictor/PC Paint palettes opaque.
This commit is contained in:
@@ -175,13 +175,15 @@ static int decode_frame(AVCodecContext *avctx,
|
|||||||
palette[i] = ff_ega_palette[ FFMIN(buf[i], 63)];
|
palette[i] = ff_ega_palette[ FFMIN(buf[i], 63)];
|
||||||
} else if (etype == 4 || etype == 5) {
|
} else if (etype == 4 || etype == 5) {
|
||||||
npal = FFMIN(esize / 3, 256);
|
npal = FFMIN(esize / 3, 256);
|
||||||
for (i = 0; i < npal; i++)
|
for (i = 0; i < npal; i++) {
|
||||||
palette[i] = AV_RB24(buf + i*3) << 2;
|
palette[i] = AV_RB24(buf + i*3) << 2;
|
||||||
|
palette[i] |= 0xFF << 24;
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
if (bpp == 1) {
|
if (bpp == 1) {
|
||||||
npal = 2;
|
npal = 2;
|
||||||
palette[0] = 0x000000;
|
palette[0] = 0xFF000000;
|
||||||
palette[1] = 0xFFFFFF;
|
palette[1] = 0xFFFFFFFF;
|
||||||
} else if (bpp == 2) {
|
} else if (bpp == 2) {
|
||||||
npal = 4;
|
npal = 4;
|
||||||
for (i = 0; i < npal; i++)
|
for (i = 0; i < npal; i++)
|
||||||
|
Reference in New Issue
Block a user