ref: 124d1cdde5c4f6862aa70fada983d0b4e8fd9e2f
parent: bf9040b4759c6cf930132ee1ec18f45108e60704
author: Jean-Marc Valin <[email protected]>
date: Thu Mar 27 20:33:04 EDT 2008
Making the pulsesAtOnce code 16-bit safe.
--- a/libcelt/vq.c
+++ b/libcelt/vq.c
@@ -111,7 +111,7 @@
ALLOC(y, N, celt_norm_t);
ALLOC(iy, N, int);
ALLOC(signx, N, int);
- N_1 = 16384/N;
+ N_1 = 512/N;
for (j=0;j<N;j++)
{
@@ -148,7 +148,7 @@
int best_id;
/* Decide on how many pulses to find at once */
- pulsesAtOnce = (pulsesLeft*N_1)>>14; /* pulsesLeft/N */
+ pulsesAtOnce = (pulsesLeft*N_1)>>9; /* pulsesLeft/N */
if (pulsesAtOnce<1)
pulsesAtOnce = 1;