convert to int before apply sign
convert to int before apply sign

avoids overflow of unsigned integer.

Change-Id: Ic92974b508bb0cd6fc680203ffa6cff14d644ff7

GrokImageCompression/aom,GrokImageCompression/aom,GrokImageCompression/aom,GrokImageCompression/aom,GrokImageCompression/aom,GrokImageCompression/aom