Commit 549c8bba authored by vaclav's avatar vaclav
Browse files

editorial improvements

parent eb36e65a
Loading
Loading
Loading
Loading
Loading
+18 −7
Original line number Diff line number Diff line
@@ -8,7 +8,6 @@
#include "rom_com.h" /* Static table prototypes                */
#include "prot_fx.h" /* Function prototypes                    */
#include "assert.h"  /* Debug prototypes                       */
#include "stl.h"
#include "ivas_prot_fx.h"


@@ -375,9 +374,10 @@ void bands_and_bit_alloc_fx(
            nb_bands_max = s_min( nb_bands_max, MBANDS_GN_BITALLOC16k );

            /*------------------------------------------------------------------------
             * Ajustement of the maximum number of bands in function of the
             * Adjustement of the maximum number of bands in function of the
             * dynamics of the spectrum (more or less speech like)
             *-----------------------------------------------------------------------*/

            test();
            test();
            test();
@@ -444,6 +444,7 @@ void bands_and_bit_alloc_fx(
            /*------------------------------------------------------------------------
             * Find extra number of band to code according to bit rate availables
             *-----------------------------------------------------------------------*/

            test();
            WHILE( GE_16( bit_tmp, bit_new_bands ) && LE_16( nb_bands, sub( nb_bands_max, 1 ) ) )
            {
@@ -470,6 +471,7 @@ void bands_and_bit_alloc_fx(
            /*------------------------------------------------------------------------
             * Complete the bit allocation per frequency band
             *-----------------------------------------------------------------------*/

            imax = 5;
            move16();

@@ -587,6 +589,7 @@ void bands_and_bit_alloc_fx(
             * For the first x bands to be included in th final sorted vector
             * Sort the remaining bands in decrease energy order
             *--------------------------------------------------------------------------*/

            FOR( j = 0; j < nb_tot_bands; j++ )
            {
                max_ener_band[j] = -10;
@@ -669,6 +672,7 @@ void bands_and_bit_alloc_fx(
         * The maximum number of bits per band of length 16 is 112
         * Redistribute the overage bits if needed
         *--------------------------------------------------------------------------*/

        sum_bit = 0;
        move16();
        j = 0;
@@ -736,6 +740,7 @@ void bands_and_bit_alloc_fx(
        /*--------------------------------------------------------------------------
         * Recompute the real number/length of frequency bands to encode
         *--------------------------------------------------------------------------*/

        *nb_subbands = nb_bands;
        move16();
        *pvq_len = shl( *nb_subbands, 4 );
@@ -744,6 +749,7 @@ void bands_and_bit_alloc_fx(
        /*--------------------------------------------------------------------------
         * Concatenate bands (encoder only)
         *--------------------------------------------------------------------------*/

        IF( exc_diff != NULL )
        {
            FOR( j = 0; j < nb_bands; j++ )
@@ -834,6 +840,7 @@ static void reajust_bits_fx(
    return;
}


/*-------------------------------------------------------------------*
 * Find_bit_frac()
 *
@@ -886,6 +893,12 @@ static Word32 Find_bit_frac_fx(
}


/*-------------------------------------------------------------------*
 * Find_bit_alloc_IVAS()
 *
 *
 *-------------------------------------------------------------------*/

/* o  : Number of band to encode */
static Word16 Find_bit_alloc_IVAS_fx(
    const Word32 core_brate,      /* i  : core bit rate                                         */
@@ -907,12 +920,10 @@ static Word16 Find_bit_alloc_IVAS_fx(
    Word16 d_tmp, e_div, tmp16;
    Word32 Ltmp, etmp_32fx;

    SWB_bit_budgetQ18 = L_shl( *bit, 18 ); /* Q0 -> Q18 */
    SWB_bit_budgetQ5 = L_shl( *bit, 5 );   /* Q0 -> Q5 */
    SWB_bit_budgetQ18 = L_shl( *bit, Q18 ); /* Q0 -> Q18 */
    SWB_bit_budgetQ5 = L_shl( *bit, Q5 );   /* Q0 -> Q5 */
    st_band = 5;
    nb_bands_max = nb_tot_bands_in;

    move16();
    move16();
    move16();

+0 −1
Original line number Diff line number Diff line
@@ -137,7 +137,6 @@
#define NONBE_FIX_2575                                  /* Fhg: Fix issue 2575, precision loss in FD CNG */

#define FIX_2556_ALIGN_CONDITIONS                       /* VA: Fix different conditions that were not exact between float and fix, BE on self-test */

#define FIX_2585_BIT_ALLOCATION_DIFF                    /* VA : issue 2585, bit allocation different behaviors between float and fixed-point for corner cases */

/* ##################### End NON-BE switches ########################### */