[FFmpeg-soc] [soc]: r5136 - in amr: amrnbdata.h amrnbdec.c
cmcq
subversion at mplayerhq.hu
Sat Aug 15 21:45:04 CEST 2009
Author: cmcq
Date: Sat Aug 15 21:45:04 2009
New Revision: 5136
Log:
Remove TRACKS macros - they aren't very useful
Modified:
amr/amrnbdata.h
amr/amrnbdec.c
Modified: amr/amrnbdata.h
==============================================================================
--- amr/amrnbdata.h Sat Aug 15 21:41:46 2009 (r5135)
+++ amr/amrnbdata.h Sat Aug 15 21:45:04 2009 (r5136)
@@ -1549,11 +1549,6 @@ static const float b60[61] = {
// fixed tables
-/** In 12.2kbit/s mode, positions are divided into TRACKS classes. */
-#define TRACKS 5
-/** In 10.2kbit/s mode, positions are divided into TRACKS_MODE_102 classes. */
-#define TRACKS_MODE_102 4
-
/**
* number of pulses per mode
*/
Modified: amr/amrnbdec.c
==============================================================================
--- amr/amrnbdec.c Sat Aug 15 21:41:46 2009 (r5135)
+++ amr/amrnbdec.c Sat Aug 15 21:45:04 2009 (r5136)
@@ -539,7 +539,7 @@ static void decode_8_pulses_31bits(const
pulse_position[7] = (pulse_position[7] << 1) + ((fixed_index[6] >> 1) & 1);
fixed_sparse->n = 8;
- for (i = 0; i < TRACKS_MODE_102; i++) {
+ for (i = 0; i < 4; i++) {
const int pos1 = (pulse_position[i] << 2) + i;
const int pos2 = (pulse_position[i + 4] << 2) + i;
const float sign = fixed_index[i] ? -1.0 : 1.0;
@@ -565,9 +565,9 @@ static void decode_10_pulses_35bits(cons
int i;
fixed_sparse->n = 10;
- for (i = 0; i < TRACKS; i++) {
- const int pos1 = gray_decode[fixed_index[i ] & 7] * TRACKS + i;
- const int pos2 = gray_decode[fixed_index[i + 5] & 7] * TRACKS + i;
+ for (i = 0; i < 5; i++) {
+ const int pos1 = gray_decode[fixed_index[i ] & 7] * 5 + i;
+ const int pos2 = gray_decode[fixed_index[i + 5] & 7] * 5 + i;
const float sign = (fixed_index[i] & 8) ? -1.0 : 1.0;
fixed_sparse->x[i ] = pos1;
fixed_sparse->x[i + 5] = pos2;
More information about the FFmpeg-soc
mailing list