Commit f4758c07 authored by fotopoulou's avatar fotopoulou
Browse files

fix crest initializations

parent 1e351aee
Loading
Loading
Loading
Loading
Loading
+9 −4
Original line number Diff line number Diff line
@@ -405,14 +405,14 @@ Word16 IGF_getCrest_fx(
    move32();
    x_max = 0;
    move16();
    crest = 16384 /*.5f Q15*/;
    move16();
    *crest_exp = 1;
    move16();

    IF( logSpec == NULL )
    {
        /* Raw path: compute from powerSpectrum */
        crest = 16384 /*.5f Q15*/;
        move16();
        *crest_exp = 1;
        move16();
        powSpec_exp = powerSpectrum_exp[0];
        move16();

@@ -438,6 +438,11 @@ Word16 IGF_getCrest_fx(
    ELSE
    {
        /* Optimized path: use pre-calculated logSpec */
        crest = 32767 /*1.0f Q15*/;
        move16();
        *crest_exp = 0;
        move16();

        FOR( i = start; i < stop; i++ )
        {
            x = logSpec[i];