Commit 40f34aaa authored by multrus's avatar multrus
Browse files

alternative patch

parent f2d37a5e
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1646,7 +1646,7 @@ int main(

    ObjectPositionBuffer mtdBuffer;
    outBuffer.pq_fact = &outBuffer.q_factor;
#ifdef FIX_2257_INCR_GUARD_BITS
#ifdef DISABLED__FIX_2257_INCR_GUARD_BITS
    Word16 gd_bits = find_guard_bits( frameSize_smpls );
#else
    Word16 subframe_len = (Word16) ( args.sampleRate / ( FRAMES_PER_SEC * MAX_PARAM_SPATIAL_SUBFRAMES ) );
+2 −14
Original line number Diff line number Diff line
@@ -596,19 +596,8 @@ void cldfbAnalysis_ts_fx_var_q(
    {
        Word16 norm_st = L_norm_arr( timeBuffer_fx, offset );
#ifdef FIX_2257_INCR_GUARD_BITS
        Word16 q_min;

        norm_st = sub( norm_st, find_guarded_bits_fx( frameSize ) );
        q_min = s_min( add( norm_st, h_cldfb->Q_cldfb_state ), *q_cldfb );

        scale_sig32( timeBuffer_fx, offset, sub( q_min, h_cldfb->Q_cldfb_state ) );
        scale_sig32( &timeBuffer_fx[offset], frameSize, sub( q_min, *q_cldfb ) );

        *q_cldfb = q_min;
        move16();
        h_cldfb->Q_cldfb_state = q_min;
        move16();
#else
        norm_st = sub( norm_st, find_guarded_bits_fx( shr( h_cldfb->no_channels, 2 ) ) );
#endif
        IF( GE_16( norm_st, sub( *q_cldfb, h_cldfb->Q_cldfb_state ) ) )
        {
            scale_sig32( timeBuffer_fx, offset, sub( *q_cldfb, h_cldfb->Q_cldfb_state ) );
@@ -624,7 +613,6 @@ void cldfbAnalysis_ts_fx_var_q(
            *q_cldfb = h_cldfb->Q_cldfb_state;
            move16();
        }
#endif
    }

    /* only process needed cols */