Lines Matching refs:rice
152 APERice riceX; ///< rice code parameters for the second channel
153 APERice riceY; ///< rice code parameters for the first channel
379 static inline void update_rice(APERice *rice, int x)
381 int lim = rice->k ? (1 << (rice->k + 4)) : 0;
382 rice->ksum += ((x + 1) / 2) - ((rice->ksum + 16) >> 5);
384 if (rice->ksum < lim)
385 rice->k--;
386 else if (rice->ksum >= (1 << (rice->k + 5)))
387 rice->k++;
390 static inline int ape_decode_value(APEContext *ctx, APERice *rice)
403 tmpk = (rice->k < 1) ? 0 : rice->k - 1;
418 pivot = rice->ksum >> 5;
451 update_rice(rice, x);
495 /* Initialize the rice structs */