Showing the changes to codec/encoder/core/src/encoder_ext.cpp (1 of 1 file). Show all
Unified · Split
| @@ -3718,7 +3718,10 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 3717 unmodified lines | ||
| 3718 | 3718 | pOldParam->bPrefixNalAddingCtrl = pNewParam->bPrefixNalAddingCtrl; |
| 3719 | 3719 | pOldParam->iNumRefFrame = pNewParam->iNumRefFrame; // number of reference frame used |
| 3720 | 3720 | pOldParam->uiGopSize = pNewParam->uiGopSize; |
| 3721 | − pOldParam->iTemporalLayerNum = pNewParam->iTemporalLayerNum; | |
| 3721 | + if (pOldParam->iTemporalLayerNum != pNewParam->iTemporalLayerNum) { | |
| 3722 | + pOldParam->iTemporalLayerNum = pNewParam->iTemporalLayerNum; | |
| 3723 | + (*ppCtx)->iCodingIndex = 0; | |
| 3724 | + } | |
| 3722 | 3725 | pOldParam->iDecompStages = pNewParam->iDecompStages; |
| 3723 | 3726 | /* denoise control */ |
| 3724 | 3727 | pOldParam->bEnableDenoise = pNewParam->bEnableDenoise; |