Showing the changes to codec/encoder/core/src/encoder_ext.cpp (1 of 9 files). Show all
Unified · Split
| @@ -323,10 +323,10 @@ int32_t ParamValidationExt (SLogContext* pLogCtx, SWelsSvcCodingParam* pCodingPa · 322 unmodified lines | ||
| 323 | 323 | pCodingParam->bDeblockingParallelFlag = true; |
| 324 | 324 | } |
| 325 | 325 | |
| 326 | − if (pCodingParam->iSpatialLayerNum > 1 && (SPS_LISTING & pCodingParam->iSpsPpsIdStrategy)) { | |
| 326 | + if (pCodingParam->iSpatialLayerNum > 1 && (SPS_LISTING & pCodingParam->eSpsPpsIdStrategy)) { | |
| 327 | 327 | WelsLog (pLogCtx, WELS_LOG_INFO, |
| 328 | − "ParamValidationExt(), iSpsPpsIdStrategy adjusted to CONSTANT_ID"); | |
| 329 | − pCodingParam->iSpsPpsIdStrategy = CONSTANT_ID; | |
| 328 | + "ParamValidationExt(), eSpsPpsIdStrategy adjusted to CONSTANT_ID"); | |
| 329 | + pCodingParam->eSpsPpsIdStrategy = CONSTANT_ID; | |
| 330 | 330 | } |
| 331 | 331 | |
| 332 | 332 | for (i = 0; i < pCodingParam->iSpatialLayerNum; ++ i) { |
| @@ -674,9 +674,9 @@ static inline int32_t AcquireLayersNals (sWelsEncCtx** ppCtx, SWelsSvcCodingPara · 341 unmodified lines | ||
| 674 | 674 | // count parasets |
| 675 | 675 | iCountNumNals += 1 + iNumDependencyLayers + (iCountNumLayers << 1) + |
| 676 | 676 | iCountNumLayers // plus iCountNumLayers for reserved application |
| 677 | − + ((SPS_LISTING & pParam->iSpsPpsIdStrategy) ? MAX_SPS_COUNT : 0) //for Sps | |
| 678 | − + (((SPS_LISTING & pParam->iSpsPpsIdStrategy) && (iNumDependencyLayers > 1)) ? MAX_SPS_COUNT : 0) //for SubsetSps | |
| 679 | − + ((SPS_PPS_LISTING == pParam->iSpsPpsIdStrategy) ? MAX_PPS_COUNT : 0); | |
| 677 | + + ((SPS_LISTING & pParam->eSpsPpsIdStrategy) ? MAX_SPS_COUNT : 0) //for Sps | |
| 678 | + + (((SPS_LISTING & pParam->eSpsPpsIdStrategy) && (iNumDependencyLayers > 1)) ? MAX_SPS_COUNT : 0) //for SubsetSps | |
| 679 | + + ((SPS_PPS_LISTING == pParam->eSpsPpsIdStrategy) ? MAX_PPS_COUNT : 0); | |
| 680 | 680 | |
| 681 | 681 | // to check number of layers / nals / slices dependencies, 12/8/2010 |
| 682 | 682 | if (iCountNumLayers > MAX_LAYER_NUM_OF_FRAME) { |
| @@ -1172,7 +1172,7 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 489 unmodified lines | ||
| 1172 | 1172 | |
| 1173 | 1173 | // for dynamically malloc for parameter sets memory instead of maximal items for standard to reduce size, 3/18/2010 |
| 1174 | 1174 | // SPS |
| 1175 | − if (! (SPS_LISTING & pParam->iSpsPpsIdStrategy)) { | |
| 1175 | + if (! (SPS_LISTING & pParam->eSpsPpsIdStrategy)) { | |
| 1176 | 1176 | (*ppCtx)->pSpsArray = (SWelsSPS*)pMa->WelsMalloc (sizeof (SWelsSPS), "pSpsArray"); |
| 1177 | 1177 | WELS_VERIFY_RETURN_PROC_IF (1, (NULL == (*ppCtx)->pSpsArray), FreeMemorySvc (ppCtx)) |
| 1178 | 1178 | if (iDlayerCount > 1) { |
| @@ -1180,7 +1180,7 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 1 unmodified line | ||
| 1180 | 1180 | WELS_VERIFY_RETURN_PROC_IF (1, (NULL == (*ppCtx)->pSubsetArray), FreeMemorySvc (ppCtx)) |
| 1181 | 1181 | } |
| 1182 | 1182 | } else { |
| 1183 | − // pParam->iSpsPpsIdStrategy == SPS_LISTING_AND_PPS_INCREASING | |
| 1183 | + // pParam->eSpsPpsIdStrategy == SPS_LISTING_AND_PPS_INCREASING | |
| 1184 | 1184 | // new memory |
| 1185 | 1185 | (*ppCtx)->pSpsArray = (SWelsSPS*)pMa->WelsMalloc (MAX_SPS_COUNT * sizeof (SWelsSPS), "pSpsArray"); |
| 1186 | 1186 | WELS_VERIFY_RETURN_PROC_IF (1, (NULL == (*ppCtx)->pSpsArray), FreeMemorySvc (ppCtx)) |
| @@ -1197,7 +1197,7 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 10 unmodified lines | ||
| 1197 | 1197 | } |
| 1198 | 1198 | } |
| 1199 | 1199 | // PPS |
| 1200 | − if (! (SPS_PPS_LISTING == pParam->iSpsPpsIdStrategy)) { | |
| 1200 | + if (! (SPS_PPS_LISTING == pParam->eSpsPpsIdStrategy)) { | |
| 1201 | 1201 | (*ppCtx)->pPPSArray = (SWelsPPS*)pMa->WelsMalloc (iDlayerCount * sizeof (SWelsPPS), "pPPSArray"); |
| 1202 | 1202 | WELS_VERIFY_RETURN_PROC_IF (1, (NULL == (*ppCtx)->pPPSArray), FreeMemorySvc (ppCtx)) |
| 1203 | 1203 | } else { |
| @@ -1212,7 +1212,7 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 8 unmodified lines | ||
| 1212 | 1212 | } |
| 1213 | 1213 | } |
| 1214 | 1214 | |
| 1215 | − if (INCREASING_ID & pParam->iSpsPpsIdStrategy) { | |
| 1215 | + if (INCREASING_ID & pParam->eSpsPpsIdStrategy) { | |
| 1216 | 1216 | (*ppCtx)->pPSOVector = & ((*ppCtx)->sPSOVector); |
| 1217 | 1217 | } else { |
| 1218 | 1218 | (*ppCtx)->pPSOVector = NULL; |
| @@ -1229,11 +1229,11 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 10 unmodified lines | ||
| 1229 | 1229 | |
| 1230 | 1230 | pDqIdc->uiSpatialId = iDlayerIndex; |
| 1231 | 1231 | |
| 1232 | − if (! (SPS_LISTING & pParam->iSpsPpsIdStrategy)) { | |
| 1232 | + if (! (SPS_LISTING & pParam->eSpsPpsIdStrategy)) { | |
| 1233 | 1233 | WelsGenerateNewSps (*ppCtx, bUseSubsetSps, iDlayerIndex, |
| 1234 | 1234 | iDlayerCount, iSpsId, pSps, pSubsetSps); |
| 1235 | 1235 | } else { |
| 1236 | − //SPS_LISTING_AND_PPS_INCREASING == pParam->iSpsPpsIdStrategy | |
| 1236 | + //SPS_LISTING_AND_PPS_INCREASING == pParam->eSpsPpsIdStrategy | |
| 1237 | 1237 | //check if the current param can fit in an existing SPS |
| 1238 | 1238 | const int32_t kiFoundSpsId = FindExistingSps ((*ppCtx)->pSvcParam, bUseSubsetSps, iDlayerIndex, iDlayerCount, |
| 1239 | 1239 | bUseSubsetSps ? ((*ppCtx)->sPSOVector.uiInUseSubsetSpsNum) : ((*ppCtx)->sPSOVector.uiInUseSpsNum), |
| @@ -1251,7 +1251,7 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 11 unmodified lines | ||
| 1251 | 1251 | } |
| 1252 | 1252 | } else { |
| 1253 | 1253 | //if no, generate a new SPS as usual |
| 1254 | − if ((SPS_PPS_LISTING == pParam->iSpsPpsIdStrategy) && (MAX_PPS_COUNT <= (*ppCtx)->sPSOVector.uiInUsePpsNum)) { | |
| 1254 | + if ((SPS_PPS_LISTING == pParam->eSpsPpsIdStrategy) && (MAX_PPS_COUNT <= (*ppCtx)->sPSOVector.uiInUsePpsNum)) { | |
| 1255 | 1255 | //check if we can generate new SPS or not |
| 1256 | 1256 | WelsLog (& (*ppCtx)->sLogCtx, WELS_LOG_ERROR, |
| 1257 | 1257 | "InitDqLayers(), cannot generate new SPS under the SPS_PPS_LISTING mode!"); |
| @@ -1260,7 +1260,7 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 2 unmodified lines | ||
| 1260 | 1260 | |
| 1261 | 1261 | iSpsId = (!bUseSubsetSps) ? ((*ppCtx)->sPSOVector.uiInUseSpsNum++) : ((*ppCtx)->sPSOVector.uiInUseSubsetSpsNum++); |
| 1262 | 1262 | if (iSpsId >= MAX_SPS_COUNT) { |
| 1263 | − if (SPS_PPS_LISTING == pParam->iSpsPpsIdStrategy) { | |
| 1263 | + if (SPS_PPS_LISTING == pParam->eSpsPpsIdStrategy) { | |
| 1264 | 1264 | WelsLog (& (*ppCtx)->sLogCtx, WELS_LOG_ERROR, |
| 1265 | 1265 | "InitDqLayers(), cannot generate new SPS under the SPS_PPS_LISTING mode!"); |
| 1266 | 1266 | return ENC_RETURN_UNSUPPORTED_PARA; |
| @@ -1281,7 +1281,7 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 14 unmodified lines | ||
| 1281 | 1281 | } |
| 1282 | 1282 | } |
| 1283 | 1283 | |
| 1284 | − if (! (SPS_PPS_LISTING == pParam->iSpsPpsIdStrategy)) { | |
| 1284 | + if (! (SPS_PPS_LISTING == pParam->eSpsPpsIdStrategy)) { | |
| 1285 | 1285 | pPps = & (*ppCtx)->pPPSArray[iPpsId]; |
| 1286 | 1286 | // initialize pPps |
| 1287 | 1287 | WelsInitPps (pPps, pSps, pSubsetSps, iPpsId, true, bUseSubsetSps, pParam->iEntropyCodingModeFlag != 0); |
| @@ -1336,11 +1336,11 @@ static inline int32_t InitDqLayers (sWelsEncCtx** ppCtx, SExistingParasetList* p · 48 unmodified lines | ||
| 1336 | 1336 | |
| 1337 | 1337 | ++ iDlayerIndex; |
| 1338 | 1338 | } |
| 1339 | − if (SPS_LISTING & pParam->iSpsPpsIdStrategy) { | |
| 1339 | + if (SPS_LISTING & pParam->eSpsPpsIdStrategy) { | |
| 1340 | 1340 | (*ppCtx)->iSpsNum = (*ppCtx)->sPSOVector.uiInUseSpsNum; |
| 1341 | 1341 | (*ppCtx)->iSubsetSpsNum = (*ppCtx)->sPSOVector.uiInUseSubsetSpsNum; |
| 1342 | 1342 | } |
| 1343 | − if (SPS_PPS_LISTING == pParam->iSpsPpsIdStrategy) { | |
| 1343 | + if (SPS_PPS_LISTING == pParam->eSpsPpsIdStrategy) { | |
| 1344 | 1344 | (*ppCtx)->iPpsNum = (*ppCtx)->sPSOVector.uiInUsePpsNum; |
| 1345 | 1345 | } |
| 1346 | 1346 | return ENC_RETURN_SUCCESS; |
| @@ -2798,7 +2798,7 @@ void WelsInitCurrentLayer (sWelsEncCtx* pCtx, · 1451 unmodified lines | ||
| 2798 | 2798 | int32_t iCurPpsId = pDqIdc->iPpsId; |
| 2799 | 2799 | int32_t iCurSpsId = pDqIdc->iSpsId; |
| 2800 | 2800 | |
| 2801 | − if (SPS_PPS_LISTING == pParam->iSpsPpsIdStrategy) { | |
| 2801 | + if (SPS_PPS_LISTING == pParam->eSpsPpsIdStrategy) { | |
| 2802 | 2802 | iCurPpsId = pCtx->sPSOVector.iPpsIdList[pDqIdc->iPpsId][WELS_ABS (pCtx->uiIdrPicId - 1) % MAX_PPS_COUNT]; |
| 2803 | 2803 | } |
| 2804 | 2804 | |
| @@ -3117,21 +3117,21 @@ int32_t WelsWriteParameterSets (sWelsEncCtx* pCtx, int32_t* pNalLen, int32_t* pN · 312 unmodified lines | ||
| 3117 | 3117 | while (iIdx < pCtx->iSpsNum) { |
| 3118 | 3118 | iNal = pCtx->pOut->iNalIndex; |
| 3119 | 3119 | |
| 3120 | − if (INCREASING_ID == pCtx->pSvcParam->iSpsPpsIdStrategy) { | |
| 3120 | + if (INCREASING_ID == pCtx->pSvcParam->eSpsPpsIdStrategy) { | |
| 3121 | 3121 | #if _DEBUG |
| 3122 | − pCtx->sPSOVector.iSpsPpsIdStrategy = INCREASING_ID; | |
| 3122 | + pCtx->sPSOVector.eSpsPpsIdStrategy = INCREASING_ID; | |
| 3123 | 3123 | assert (iIdx < MAX_DQ_LAYER_NUM); |
| 3124 | 3124 | #endif |
| 3125 | 3125 | |
| 3126 | 3126 | ParasetIdAdditionIdAdjust (& (pCtx->sPSOVector.sParaSetOffsetVariable[PARA_SET_TYPE_AVCSPS]), |
| 3127 | 3127 | pCtx->pSpsArray[0].uiSpsId, |
| 3128 | 3128 | MAX_SPS_COUNT); |
| 3129 | − } else if (CONSTANT_ID == pCtx->pSvcParam->iSpsPpsIdStrategy) { | |
| 3129 | + } else if (CONSTANT_ID == pCtx->pSvcParam->eSpsPpsIdStrategy) { | |
| 3130 | 3130 | memset (& (pCtx->sPSOVector), 0, sizeof (pCtx->sPSOVector)); |
| 3131 | 3131 | } |
| 3132 | 3132 | |
| 3133 | 3133 | /* generate sequence parameters set */ |
| 3134 | − iId = (SPS_LISTING & pCtx->pSvcParam->iSpsPpsIdStrategy) ? iIdx : 0; | |
| 3134 | + iId = (SPS_LISTING & pCtx->pSvcParam->eSpsPpsIdStrategy) ? iIdx : 0; | |
| 3135 | 3135 | |
| 3136 | 3136 | WelsLoadNal (pCtx->pOut, NAL_UNIT_SPS, NRI_PRI_HIGHEST); |
| 3137 | 3137 | WelsWriteSpsNal (&pCtx->pSpsArray[iId], &pCtx->pOut->sBsWrite, |
| @@ -3157,9 +3157,9 @@ int32_t WelsWriteParameterSets (sWelsEncCtx* pCtx, int32_t* pNalLen, int32_t* pN · 19 unmodified lines | ||
| 3157 | 3157 | while (iIdx < pCtx->iSubsetSpsNum) { |
| 3158 | 3158 | iNal = pCtx->pOut->iNalIndex; |
| 3159 | 3159 | |
| 3160 | − if (INCREASING_ID == pCtx->pSvcParam->iSpsPpsIdStrategy) { | |
| 3160 | + if (INCREASING_ID == pCtx->pSvcParam->eSpsPpsIdStrategy) { | |
| 3161 | 3161 | #if _DEBUG |
| 3162 | − pCtx->sPSOVector.iSpsPpsIdStrategy = INCREASING_ID; | |
| 3162 | + pCtx->sPSOVector.eSpsPpsIdStrategy = INCREASING_ID; | |
| 3163 | 3163 | assert (iIdx < MAX_DQ_LAYER_NUM); |
| 3164 | 3164 | #endif |
| 3165 | 3165 | |
| @@ -3193,7 +3193,7 @@ int32_t WelsWriteParameterSets (sWelsEncCtx* pCtx, int32_t* pNalLen, int32_t* pN · 27 unmodified lines | ||
| 3193 | 3193 | |
| 3194 | 3194 | /* write all PPS */ |
| 3195 | 3195 | iIdx = 0; |
| 3196 | − if ((SPS_PPS_LISTING == pCtx->pSvcParam->iSpsPpsIdStrategy) && (pCtx->iPpsNum < MAX_PPS_COUNT)) { | |
| 3196 | + if ((SPS_PPS_LISTING == pCtx->pSvcParam->eSpsPpsIdStrategy) && (pCtx->iPpsNum < MAX_PPS_COUNT)) { | |
| 3197 | 3197 | assert (pCtx->iPpsNum <= MAX_DQ_LAYER_NUM); |
| 3198 | 3198 | |
| 3199 | 3199 | //Generate PPS LIST |
| @@ -3216,7 +3216,7 @@ int32_t WelsWriteParameterSets (sWelsEncCtx* pCtx, int32_t* pNalLen, int32_t* pN · 16 unmodified lines | ||
| 3216 | 3216 | } |
| 3217 | 3217 | |
| 3218 | 3218 | while (iIdx < pCtx->iPpsNum) { |
| 3219 | − if ((INCREASING_ID & pCtx->pSvcParam->iSpsPpsIdStrategy)) { | |
| 3219 | + if ((INCREASING_ID & pCtx->pSvcParam->eSpsPpsIdStrategy)) { | |
| 3220 | 3220 | //para_set_type = 2: PPS, use MAX_PPS_COUNT |
| 3221 | 3221 | ParasetIdAdditionIdAdjust (&pCtx->sPSOVector.sParaSetOffsetVariable[PARA_SET_TYPE_PPS], pCtx->pPPSArray[iIdx].iPpsId, |
| 3222 | 3222 | MAX_PPS_COUNT); |
| @@ -3226,7 +3226,7 @@ int32_t WelsWriteParameterSets (sWelsEncCtx* pCtx, int32_t* pNalLen, int32_t* pN · 3 unmodified lines | ||
| 3226 | 3226 | /* generate picture parameter set */ |
| 3227 | 3227 | WelsLoadNal (pCtx->pOut, NAL_UNIT_PPS, NRI_PRI_HIGHEST); |
| 3228 | 3228 | WelsWritePpsSyntax (&pCtx->pPPSArray[iIdx], &pCtx->pOut->sBsWrite, |
| 3229 | − ((SPS_PPS_LISTING != pCtx->pSvcParam->iSpsPpsIdStrategy)) ? (& (pCtx->sPSOVector)) : NULL); | |
| 3229 | + ((SPS_PPS_LISTING != pCtx->pSvcParam->eSpsPpsIdStrategy)) ? (& (pCtx->sPSOVector)) : NULL); | |
| 3230 | 3230 | WelsUnloadNal (pCtx->pOut); |
| 3231 | 3231 | |
| 3232 | 3232 | iReturn = WelsEncodeNal (&pCtx->pOut->sNalList[iNal], NULL, |
| @@ -4124,7 +4124,7 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 891 unmodified lines | ||
| 4124 | 4124 | (pOldParam->iMultipleThreadIdc != pNewParam->iMultipleThreadIdc) || |
| 4125 | 4125 | (pOldParam->bEnableBackgroundDetection != pNewParam->bEnableBackgroundDetection) || |
| 4126 | 4126 | (pOldParam->bEnableAdaptiveQuant != pNewParam->bEnableAdaptiveQuant) || |
| 4127 | − (pOldParam->iSpsPpsIdStrategy != pNewParam->iSpsPpsIdStrategy); | |
| 4127 | + (pOldParam->eSpsPpsIdStrategy != pNewParam->eSpsPpsIdStrategy); | |
| 4128 | 4128 | if (pNewParam->iMaxNumRefFrame > pOldParam->iMaxNumRefFrame) { |
| 4129 | 4129 | bNeedReset = true; |
| 4130 | 4130 | } |
| @@ -4173,7 +4173,7 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 42 unmodified lines | ||
| 4173 | 4173 | if (bNeedReset) { |
| 4174 | 4174 | SLogContext sLogCtx = (*ppCtx)->sLogCtx; |
| 4175 | 4175 | |
| 4176 | − int32_t iOldSpsPpsIdStrategy = pOldParam->iSpsPpsIdStrategy; | |
| 4176 | + int32_t iOldSpsPpsIdStrategy = pOldParam->eSpsPpsIdStrategy; | |
| 4177 | 4177 | SParaSetOffsetVariable sTmpPsoVariable[PARA_SET_TYPE]; |
| 4178 | 4178 | int32_t iTmpPpsIdList[MAX_DQ_LAYER_NUM * MAX_PPS_COUNT]; |
| 4179 | 4179 | uint16_t uiTmpIdrPicId = (*ppCtx)->uiIdrPicId;//this is for LTR! |
| @@ -4183,7 +4183,7 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 3 unmodified lines | ||
| 4183 | 4183 | SExistingParasetList sExistingParasetList; |
| 4184 | 4184 | SExistingParasetList* pExistingParasetList = NULL; |
| 4185 | 4185 | |
| 4186 | − if ((CONSTANT_ID != iOldSpsPpsIdStrategy) && (CONSTANT_ID != pNewParam->iSpsPpsIdStrategy)) { | |
| 4186 | + if ((CONSTANT_ID != iOldSpsPpsIdStrategy) && (CONSTANT_ID != pNewParam->eSpsPpsIdStrategy)) { | |
| 4187 | 4187 | for (int32_t k = 0; k < PARA_SET_TYPE; k++) { |
| 4188 | 4188 | memset (((*ppCtx)->sPSOVector.sParaSetOffsetVariable[k].bUsedParaSetIdInBs), 0, MAX_PPS_COUNT * sizeof (bool)); |
| 4189 | 4189 | } |
| @@ -4191,7 +4191,7 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 1 unmodified line | ||
| 4191 | 4191 | (PARA_SET_TYPE)*sizeof (SParaSetOffsetVariable)); // confirmed_safe_unsafe_usage |
| 4192 | 4192 | |
| 4193 | 4193 | if ((SPS_LISTING & iOldSpsPpsIdStrategy) |
| 4194 | − && (SPS_LISTING & pNewParam->iSpsPpsIdStrategy)) { | |
| 4194 | + && (SPS_LISTING & pNewParam->eSpsPpsIdStrategy)) { | |
| 4195 | 4195 | pExistingParasetList = &sExistingParasetList; |
| 4196 | 4196 | sExistingParasetList.uiInUseSpsNum = (*ppCtx)->sPSOVector.uiInUseSpsNum; |
| 4197 | 4197 | sExistingParasetList.uiInUseSubsetSpsNum = (*ppCtx)->sPSOVector.uiInUseSubsetSpsNum; |
| @@ -4200,7 +4200,7 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 2 unmodified lines | ||
| 4200 | 4200 | } |
| 4201 | 4201 | |
| 4202 | 4202 | if ((SPS_PPS_LISTING == iOldSpsPpsIdStrategy) |
| 4203 | − && (SPS_PPS_LISTING == pNewParam->iSpsPpsIdStrategy)) { | |
| 4203 | + && (SPS_PPS_LISTING == pNewParam->eSpsPpsIdStrategy)) { | |
| 4204 | 4204 | pExistingParasetList = &sExistingParasetList; |
| 4205 | 4205 | sExistingParasetList.uiInUseSpsNum = (*ppCtx)->sPSOVector.uiInUseSpsNum; |
| 4206 | 4206 | sExistingParasetList.uiInUseSubsetSpsNum = (*ppCtx)->sPSOVector.uiInUseSubsetSpsNum; |
| @@ -4230,14 +4230,14 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 23 unmodified lines | ||
| 4230 | 4230 | //for sEncoderStatistics |
| 4231 | 4231 | (*ppCtx)->sEncoderStatistics = sTempEncoderStatistics; |
| 4232 | 4232 | |
| 4233 | − //load back the needed structure for iSpsPpsIdStrategy | |
| 4234 | − if ((CONSTANT_ID != iOldSpsPpsIdStrategy) && (CONSTANT_ID != pNewParam->iSpsPpsIdStrategy)) { | |
| 4233 | + //load back the needed structure for eSpsPpsIdStrategy | |
| 4234 | + if ((CONSTANT_ID != iOldSpsPpsIdStrategy) && (CONSTANT_ID != pNewParam->eSpsPpsIdStrategy)) { | |
| 4235 | 4235 | memcpy ((*ppCtx)->sPSOVector.sParaSetOffsetVariable, sTmpPsoVariable, |
| 4236 | 4236 | (PARA_SET_TYPE)*sizeof (SParaSetOffsetVariable)); // confirmed_safe_unsafe_usage |
| 4237 | 4237 | } |
| 4238 | 4238 | |
| 4239 | 4239 | if ((SPS_PPS_LISTING == iOldSpsPpsIdStrategy) |
| 4240 | − && (SPS_PPS_LISTING == pNewParam->iSpsPpsIdStrategy)) { | |
| 4240 | + && (SPS_PPS_LISTING == pNewParam->eSpsPpsIdStrategy)) { | |
| 4241 | 4241 | memcpy (((*ppCtx)->sPSOVector.iPpsIdList), iTmpPpsIdList, MAX_DQ_LAYER_NUM * MAX_PPS_COUNT * sizeof (int32_t)); |
| 4242 | 4242 | } |
| 4243 | 4243 | } else { |
| @@ -4254,7 +4254,7 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 10 unmodified lines | ||
| 4254 | 4254 | pOldParam->fMaxFrameRate = pNewParam->fMaxFrameRate; // maximal frame rate [Hz / fps] |
| 4255 | 4255 | pOldParam->iComplexityMode = pNewParam->iComplexityMode; // color space of input sequence |
| 4256 | 4256 | pOldParam->uiIntraPeriod = pNewParam->uiIntraPeriod; // intra period (multiple of GOP size as desired) |
| 4257 | − pOldParam->iSpsPpsIdStrategy = pNewParam->iSpsPpsIdStrategy; | |
| 4257 | + pOldParam->eSpsPpsIdStrategy = pNewParam->eSpsPpsIdStrategy; | |
| 4258 | 4258 | pOldParam->bPrefixNalAddingCtrl = pNewParam->bPrefixNalAddingCtrl; |
| 4259 | 4259 | pOldParam->iNumRefFrame = pNewParam->iNumRefFrame; // number of reference frame used |
| 4260 | 4260 | pOldParam->uiGopSize = pNewParam->uiGopSize; |