[FFmpeg-devel] [PATCH]Make the mov palette opaque

Michael Niedermayer michaelni at gmx.at
Sat Dec 24 02:39:43 CET 2011


On Sat, Dec 24, 2011 at 02:37:20AM +0100, Carl Eugen Hoyos wrote:
> Hi!
> 
> Attached patch makes the palette in mov files opaque.
> 
> Please comment, Carl Eugen

>  mov.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 6d2a7105b5ca97de37a5e6ee5fba36bb0cf6e366  patchmovpal.diff
> diff --git a/libavformat/mov.c b/libavformat/mov.c
> index dd8e92e..8566605 100644
> --- a/libavformat/mov.c
> +++ b/libavformat/mov.c
> @@ -1228,7 +1228,7 @@ int ff_mov_read_stsd_entries(MOVContext *c, AVIOContext *pb, int entries)
>                          }else
>                          r = g = b = color_index;
>                          sc->palette[j] =
> -                            (r << 16) | (g << 8) | (b);
> +                            (0xFF << 24) | (r << 16) | (g << 8) | (b);

0xFFU, not that it matters

and LGTM

[...]

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Incandescent light bulbs waste a lot of energy as heat so the EU forbids them.
Their replacement, compact fluorescent lamps, much more expensive, dont fit in
many old lamps, flicker, contain toxic mercury, produce a fraction of the light
that is claimed and in a unnatural spectrum rendering colors different than
in natural light. Ah and we now need to turn the heaters up more in winter to
compensate the lower wasted heat. Who wins? Not the environment, thats for sure
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20111224/2554510b/attachment.asc>


More information about the ffmpeg-devel mailing list