Update SILK code using the CELT range coder
[opus.git] / src_FIX / SKP_Silk_LTP_scale_ctrl_FIX.c
similarity index 96%
rename from src/SKP_Silk_LTP_scale_ctrl_FIX.c
rename to src_FIX/SKP_Silk_LTP_scale_ctrl_FIX.c
index 4d69a8a..9470e37 100644 (file)
@@ -63,7 +63,7 @@ void SKP_Silk_LTP_scale_ctrl_FIX(
     /* Only scale if first frame in packet 0% */\r
     if( psEnc->sCmn.nFramesInPayloadBuf == 0 ) {\r
         \r
-        frames_per_packet = SKP_DIV32_16( psEnc->sCmn.PacketSize_ms, FRAME_LENGTH_MS );\r
+        frames_per_packet = SKP_DIV32_16( psEnc->sCmn.PacketSize_ms, SKP_SMULBB( SUB_FRAME_LENGTH_MS, psEnc->sCmn.nb_subfr ) );\r
 \r
         round_loss += frames_per_packet - 1;\r
         thrld1_Q15 = LTPScaleThresholds_Q15[ SKP_min_int( round_loss,     NB_THRESHOLDS - 1 ) ];\r