Commit f2a67a35 authored by Dominik Weckbecker's avatar Dominik Weckbecker 💬
Browse files

delete define NONBE_FIX_SBA_SIGNALING_BITS_A

parent e6cfec58
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -345,7 +345,7 @@ void ivas_get_dirac_sba_max_md_bits(
        /* OSBA needs an additional 5-bits safety margin to avoid acelp crashes */
        if ( ivas_format == SBA_ISM_FORMAT )
        {
#if defined( NONBE_FIX_SBA_SIGNALING_BITS_A ) || defined( NONBE_FIX_SBA_SIGNALING_BITS_B )
#if defined( NONBE_FIX_SBA_SIGNALING_BITS_B )
            ( *metadata_max_bits ) -= 5;
#else
            ( *metadata_max_bits ) -= 3;
+0 −1
Original line number Diff line number Diff line
@@ -177,7 +177,6 @@
#define NONBE_FIX_1054_NEGATIVE_LVQ_INDEX               /* Nokia: issue 1054: Input to decode_comb in deindex_lvq_SHB should be positive */
#define NONBE_FIX_1063_DIV_BY_ZERO_SUMNRG               /* VoiceAge: issue 1063: division by zero for angle_rot feature in the UNCLR classifier */

/*#define NONBE_FIX_SBA_SIGNALING_BITS_A*/              /* FhG: issue 1061: option A: clean up OSBA and ISM signaling using 4 bits all the time */
#define NONBE_FIX_SBA_SIGNALING_BITS_B                  /* FhG: issue 1061: option B: signal sba order additionally in OSBA */

/* ##################### End NON-BE switches ########################### */
+2 −17
Original line number Diff line number Diff line
@@ -467,7 +467,7 @@ ivas_error ivas_dec_setup(
        {
            /* the number of objects is written at the end of the bitstream, in the SBA metadata */
            st_ivas->nchan_ism = 2 * st_ivas->bit_stream[ivas_total_brate / FRAMES_PER_SEC - 1] + st_ivas->bit_stream[ivas_total_brate / FRAMES_PER_SEC - 2] + 1;
#if !defined( NONBE_FIX_SBA_SIGNALING_BITS_A ) && !defined( NONBE_FIX_SBA_SIGNALING_BITS_B )
#if !defined( NONBE_FIX_SBA_SIGNALING_BITS_B )
            if ( ivas_total_brate < IVAS_24k4 || ivas_total_brate >= IVAS_256k )
#endif
            {
@@ -481,12 +481,7 @@ ivas_error ivas_dec_setup(
            num_bits_read += SBA_ORDER_BITS;

            /* read Ambisonic (SBA) order */
#ifndef NONBE_FIX_SBA_SIGNALING_BITS_A
            if ( ivas_total_brate < IVAS_256k )
            {
                st_ivas->sba_order = 3;
            }
#endif

#ifdef NONBE_FIX_SBA_SIGNALING_BITS_B
            if ( ivas_total_brate < IVAS_24k4 )
            {
@@ -797,9 +792,7 @@ static ivas_error ivas_read_format(
                break;
            case 2:
                st_ivas->ivas_format = ISM_FORMAT;
#ifndef NONBE_FIX_SBA_SIGNALING_BITS_A
                if ( ivas_total_brate >= IVAS_24k4 )
#endif
                {
                    if ( st_ivas->bit_stream[*num_bits_read] )
                    {
@@ -813,12 +806,6 @@ static ivas_error ivas_read_format(
                            st_ivas->ivas_format = MASA_ISM_FORMAT;
                        }
                    }
#ifdef NONBE_FIX_SBA_SIGNALING_BITS_A
                    else
                    {
                        ( *num_bits_read )++;
                    }
#endif
                    ( *num_bits_read )++;
                }
                break;
@@ -836,12 +823,10 @@ static ivas_error ivas_read_format(
                    /* read Ambisonic (SBA) order */
                    st_ivas->sba_order = st_ivas->bit_stream[( *num_bits_read ) + 2 + SBA_PLANAR_BITS];
                    st_ivas->sba_order += 2 * st_ivas->bit_stream[( *num_bits_read ) + 1 + SBA_PLANAR_BITS];
#ifndef NONBE_FIX_SBA_SIGNALING_BITS_A
                    if ( st_ivas->sba_order == 0 )
                    {
                        st_ivas->ivas_format = SBA_ISM_FORMAT;
                    }
#endif
                }
                ( *num_bits_read )++;

+0 −10
Original line number Diff line number Diff line
@@ -67,18 +67,10 @@ void ivas_write_format(
            break;
        case ISM_FORMAT:
            ind = 2;
#ifndef NONBE_FIX_SBA_SIGNALING_BITS_A
            if ( st_ivas->hEncoderConfig->ivas_total_brate >= IVAS_24k4 )
#endif
            {
#ifndef NONBE_FIX_SBA_SIGNALING_BITS_A
                ind = 4;
                nBits += extra_bits;
#else
                ind = 8;
                nBits += extra_bits;
                nBits += IVAS_COMBINED_FORMAT_SIGNALLING_BITS;
#endif
            }
            break;
        case MC_FORMAT:
@@ -111,14 +103,12 @@ void ivas_write_format(
            }
            break;
        case SBA_ISM_FORMAT:
#ifndef NONBE_FIX_SBA_SIGNALING_BITS_A
            if ( st_ivas->hEncoderConfig->ivas_total_brate < IVAS_24k4 )
            {
                ind = 6; /* send SBA format */
                nBits += extra_bits;
            }
            else
#endif
            {
                ind = 11; /* 1011 */
                nBits += extra_bits + IVAS_COMBINED_FORMAT_SIGNALLING_BITS;
+0 −6
Original line number Diff line number Diff line
@@ -253,17 +253,11 @@ int16_t ivas_ism_dtx_enc(
            /* replicate ivas_write_format() */
            int16_t ind = 2;
            nBits = IVAS_FORMAT_SIGNALING_NBITS;
#ifdef NONBE_FIX_SBA_SIGNALING_BITS_A
            ind = 8;
            nBits = IVAS_FORMAT_SIGNALING_NBITS_EXTENDED + IVAS_COMBINED_FORMAT_SIGNALLING_BITS;
#else
            if ( ivas_total_brate >= IVAS_24k4 )
            {
                ind = 4;
                nBits = IVAS_FORMAT_SIGNALING_NBITS_EXTENDED;
            }
#endif

            push_indice( hSCE[0]->hCoreCoder[0]->hBstr, IND_IVAS_FORMAT, ind, nBits );
        }
    }
Loading