swscale: fix an implementation-defined unsigned-to-signed conversion

pull/64/merge
Justin Ruggles 11 years ago
parent d4a8a86c68
commit 60c4660ba0
  1. 4
      libswscale/swscale_unscaled.c

@ -1187,9 +1187,9 @@ int attribute_align_arg sws_scale(struct SwsContext *c,
if (usePal(c->srcFormat)) {
for (i = 0; i < 256; i++) {
int p, r, g, b, y, u, v;
int r, g, b, y, u, v;
if (c->srcFormat == AV_PIX_FMT_PAL8) {
p = ((const uint32_t *)(srcSlice[1]))[i];
uint32_t p = ((const uint32_t *)(srcSlice[1]))[i];
r = (p >> 16) & 0xFF;
g = (p >> 8) & 0xFF;
b = p & 0xFF;

Loading…
Cancel
Save