From: Jingning Han Date: Thu, 28 Aug 2014 16:21:58 +0000 (-0700) Subject: Fix int64_t to unsigned int conversion warnings X-Git-Tag: v1.4.0~884^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6ddf1e152acbade83e166d0d7dffc5e3c07cbf05;p=libvpx Fix int64_t to unsigned int conversion warnings Use unsigned int type to store the sse in the pixel domain. The precision is sufficient to handle sse of block size up to 64x64. The transform domain version however needs int64_t, since there is a transfer gain applied in the forward transformation that might cause unsigned int overflow. Change-Id: Ifef97c38597e426262290f35341fbb093cf0a079 --- diff --git a/vp9/encoder/vp9_rdopt.c b/vp9/encoder/vp9_rdopt.c index d3a1db8bd..c55f1e4f7 100644 --- a/vp9/encoder/vp9_rdopt.c +++ b/vp9/encoder/vp9_rdopt.c @@ -172,7 +172,7 @@ static void model_rd_for_sb(VP9_COMP *cpi, BLOCK_SIZE bsize, const int ref = xd->mi[0]->mbmi.ref_frame[0]; unsigned int sse; unsigned int var = 0; - int64_t sum_sse = 0; + unsigned int sum_sse = 0; const int shift = 8; int rate; int64_t dist;