some tuning, replaced conditional constants with QCONST16.
authorjm <jm@0101bb08-14d6-0310-b084-bc0e0c8e3800>
Tue, 25 Apr 2006 12:26:31 +0000 (12:26 +0000)
committerjm <jm@0101bb08-14d6-0310-b084-bc0e0c8e3800>
Tue, 25 Apr 2006 12:26:31 +0000 (12:26 +0000)
git-svn-id: http://svn.xiph.org/trunk/speex@11275 0101bb08-14d6-0310-b084-bc0e0c8e3800

libspeex/modes.c

index aa15729..7b4fbd4 100644 (file)
@@ -190,11 +190,7 @@ static const SpeexSubmode nb_submode1 = {
    noise_codebook_quant,
    noise_codebook_unquant,
    NULL,
-#ifdef FIXED_POINT
-   22938, 22938, 0, -1,
-#else
-   .7, .7, 0, -1,
-#endif
+   QCONST16(0.7,15), QCONST16(0.7,15), 0, -1,
    43
 };
 
@@ -215,11 +211,7 @@ static const SpeexSubmode nb_submode8 = {
    split_cb_search_shape_sign,
    split_cb_shape_sign_unquant,
    &split_cb_nb_ulbr,
-#ifdef FIXED_POINT
-   22938, 16384, 11796, 21299,
-#else
-   0.7, 0.5, .36, .65,
-#endif
+   QCONST16(0.7,15), QCONST16(0.5,15), QCONST16(.36,15), QCONST16(.65,15),
    79
 };
 
@@ -240,11 +232,7 @@ static const SpeexSubmode nb_submode2 = {
    split_cb_search_shape_sign,
    split_cb_shape_sign_unquant,
    &split_cb_nb_vlbr,
-#ifdef FIXED_POINT
-   22938, 16384, 11796, 18022,
-#else
-   0.7, 0.5, .36, .55,
-#endif
+   QCONST16(0.7,15), QCONST16(0.55,15), QCONST16(.22,15), QCONST16(.55,15),
    119
 };
 
@@ -265,11 +253,7 @@ static const SpeexSubmode nb_submode3 = {
    split_cb_search_shape_sign,
    split_cb_shape_sign_unquant,
    &split_cb_nb_lbr,
-#ifdef FIXED_POINT
-   22938, 18022, 9830, 14746,
-#else
-   0.7, 0.55, .30, .45,
-#endif
+   QCONST16(0.7,15), QCONST16(0.6,15), QCONST16(.15,15), QCONST16(.45,15),
    160
 };
 
@@ -290,11 +274,7 @@ static const SpeexSubmode nb_submode4 = {
    split_cb_search_shape_sign,
    split_cb_shape_sign_unquant,
    &split_cb_nb_med,
-#ifdef FIXED_POINT
-   22938, 20644, 5243, 11469,
-#else
-   0.7, 0.63, .16, .35,
-#endif
+   QCONST16(0.7,15), QCONST16(0.63,15), QCONST16(.1,15), QCONST16(.35,15),
    220
 };
 
@@ -315,11 +295,7 @@ static const SpeexSubmode nb_submode5 = {
    split_cb_search_shape_sign,
    split_cb_shape_sign_unquant,
    &split_cb_nb,
-#ifdef FIXED_POINT
-   22938, 21299, 3932, 8192,
-#else
-   0.7, 0.65, .12, .25,
-#endif
+   QCONST16(0.7,15), QCONST16(0.65,15), QCONST16(.08,15), QCONST16(.2,15),
    300
 };
 
@@ -340,11 +316,7 @@ static const SpeexSubmode nb_submode6 = {
    split_cb_search_shape_sign,
    split_cb_shape_sign_unquant,
    &split_cb_sb,
-#ifdef FIXED_POINT
-   22282, 21299, 2294, 3277,
-#else
-   0.68, 0.65, .07, .1,
-#endif
+   QCONST16(0.68,15), QCONST16(0.65,15), QCONST16(.03,15), QCONST16(.1,15),
    364
 };
 
@@ -365,11 +337,7 @@ static const SpeexSubmode nb_submode7 = {
    split_cb_search_shape_sign,
    split_cb_shape_sign_unquant,
    &split_cb_nb,
-#ifdef FIXED_POINT
-   21299, 21299, 0, -1,
-#else
-   0.65, 0.65, .0, -1,
-#endif
+   QCONST16(0.65,15), QCONST16(0.65,15), 0, -1,
    492
 };