summaryrefslogtreecommitdiffstats
path: root/sub/spudec.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2012-10-25 19:37:47 +0200
committerwm4 <wm4@nowhere>2012-10-28 15:31:32 +0100
commit65b313a8b0b1a97f7d51f1fec4517adaa9334aa3 (patch)
treecd2bdff738502c6603675b44ee7ac7322a1aa99d /sub/spudec.c
parent18d4eebedb7f80493da87f8506ff0b2db796510a (diff)
downloadmpv-65b313a8b0b1a97f7d51f1fec4517adaa9334aa3.tar.bz2
mpv-65b313a8b0b1a97f7d51f1fec4517adaa9334aa3.tar.xz
draw_bmp, csputils: use function instead of macro
Diffstat (limited to 'sub/spudec.c')
-rw-r--r--sub/spudec.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sub/spudec.c b/sub/spudec.c
index 84b4113251..3f9e5d701a 100644
--- a/sub/spudec.c
+++ b/sub/spudec.c
@@ -198,10 +198,10 @@ static void setup_palette(spudec_handle_t *spu, uint32_t palette[256])
alpha = 0;
int color = spu->custom ? spu->cuspal[i] :
spu->global_palette[spu->palette[i]];
- uint8_t c[3] = {(color >> 16) & 0xff, (color >> 8) & 0xff, color & 0xff};
- mp_map_color(cmatrix, c);
+ int c[3] = {(color >> 16) & 0xff, (color >> 8) & 0xff, color & 0xff};
+ mp_map_color(cmatrix, 8, c);
// R and G swapped, possibly due to vobsub_palette_to_yuv()
- palette[i] = (alpha << 24) | (c[2] << 16) | (c[1] << 8) | c[0];
+ palette[i] = (alpha << 24u) | (c[2] << 16) | (c[1] << 8) | c[0];
}
}