add_noise,vpx_setup_noise: correct 'char_dist' type

fixes SSE2/AddNoiseTest.CheckCvsAssembly/0 with -funsigned-char.
visibly broken since:
0dc69c7 postproc : fix function parameters for noise functions.
where the types diverged (char vs. int8)
but likely the return changed in:
2ca24b0 postproc - move filling of noise buffer to vpx_dsp.
when multiple implementations were merged.

Change-Id: I176ca1f170217f05ba7872b0c4de63e41949e999
This commit is contained in:
James Zern 2016-08-24 21:46:26 -07:00
parent ce634bbf4d
commit 3ddff4503a

View File

@ -43,7 +43,7 @@ static double gaussian(double sigma, double mu, double x) {
}
int vpx_setup_noise(double sigma, int8_t *noise, int size) {
char char_dist[256];
int8_t char_dist[256];
int next = 0, i, j;
// set up a 256 entry lookup that matches gaussian distribution
@ -51,7 +51,7 @@ int vpx_setup_noise(double sigma, int8_t *noise, int size) {
const int a_i = (int)(0.5 + 256 * gaussian(sigma, 0, i));
if (a_i) {
for (j = 0; j < a_i; ++j) {
char_dist[next + j] = (char)i;
char_dist[next + j] = (int8_t)i;
}
next = next + j;
}