Change check for primary sync (major Au in case of MAT-THD) to decode status sample...
authorFrank Livingston <frank-livingston@ti.com>
Thu, 26 Jan 2017 22:52:55 +0000 (16:52 -0600)
committerFrank Livingston <frank-livingston@ti.com>
Thu, 26 Jan 2017 22:52:55 +0000 (16:52 -0600)
pasdk/test_dsp/framework/audioStreamInpProc.c

index a5fcd45ea6f99612fe18b537b6f7256fd43a4123..ba47735055a0bfc5d0691ce8db9c10c0ed25feec 100644 (file)
@@ -2011,7 +2011,7 @@ PAF_ASIT_decodeProcessing(
     Int frame; // decoder input frame count
     Int block; // (***) FL: formerly  -- decoder output block count / input frame
 #ifdef NON_CACHE_STATUS
-    Int8 tempVar8;
+    Int8 tempVar8, temp2Var8;
 #endif
     
     pAstCfg = pC->pAstCfg; // get pointer to common (shared) configuration
@@ -2170,17 +2170,21 @@ PAF_ASIT_decodeProcessing(
                               &(pAstCfg->xDec[zMD].decodeStatus.sourceDecode),
                               sizeof(tempVar8),
                               GATEMP_INDEX_DEC);
+                statusOp_read(&temp2Var8,
+                              &(pAstCfg->xDec[zMD].decodeStatus.sampleRate),
+                              sizeof(tempVar8),
+                              GATEMP_INDEX_DEC);
                 // Don't start decode until major access unit is found.
                 if (((tempVar8 == PAF_SOURCE_THD)    ||
                      (tempVar8 == PAF_SOURCE_DXP)    ||
                      (tempVar8 == PAF_SOURCE_DTSHD)) &&
-                     (pAstCfg->xStr[zMS].pAudioFrame->sampleRate == PAF_SAMPLERATE_UNKNOWN)) 
+                     (temp2Var8 == PAF_SAMPLERATE_UNKNOWN)) 
 #else
                 // Don't start decode until major access unit is found.
                 if (((pAstCfg->xDec[zMD].decodeStatus.sourceDecode == PAF_SOURCE_THD)    ||
                      (pAstCfg->xDec[zMD].decodeStatus.sourceDecode == PAF_SOURCE_DXP)    ||
                      (pAstCfg->xDec[zMD].decodeStatus.sourceDecode == PAF_SOURCE_DTSHD)) &&
-                     (pAstCfg->xStr[zMS].pAudioFrame->sampleRate == PAF_SAMPLERATE_UNKNOWN))
+                     (pAstCfg->xDec[zMD].decodeStatus.sampleRate == PAF_SAMPLERATE_UNKNOWN))
 #endif
                 {
                     Int z;