Commit 1fc992d5 authored by Yaowu Xu's avatar Yaowu Xu

Change to use correct type

This commit changes to use int instead of unsigned for a variable used in
inverse quantization.

Ported from libvpx/master: d3fe3b2a

Change-Id: I8f0ff5f80c9e68d52425265ef177357c65ead1e2
parent b101b1f4
......@@ -296,12 +296,12 @@ void av1_regular_quantize_b_4x4(MACROBLOCK *x, int plane, int block,
}
static void invert_quant(int16_t *quant, int16_t *shift, int d) {
unsigned t;
int l;
uint32_t t;
int l, m;
t = d;
for (l = 0; t > 1; l++) t >>= 1;
t = 1 + (1 << (16 + l)) / d;
*quant = (int16_t)(t - (1 << 16));
m = 1 + (1 << (16 + l)) / d;
*quant = (int16_t)(m - (1 << 16));
*shift = 1 << (16 - l);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment