History

fix crash issue that temporal layer changs cause memory issue

ruil2 committed 8 years ago

Commit e0548341 parent 9edcf742 files · +65 −1Browse files

Showing the changes to codec/encoder/core/src/encoder_ext.cpp (1 of 2 files). Show all

Unified · Split

codec/encoder/core/src/encoder_ext.cpp+2−1
@@ -4179,7 +4179,8 @@ int32_t WelsEncoderParamAdjust (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pNewPa · 4178 unmodified lines
41794179 (pOldParam->bEnableBackgroundDetection != pNewParam->bEnableBackgroundDetection) ||
41804180 (pOldParam->bEnableAdaptiveQuant != pNewParam->bEnableAdaptiveQuant) ||
41814181 (pOldParam->eSpsPpsIdStrategy != pNewParam->eSpsPpsIdStrategy);
4182− if (pNewParam->iMaxNumRefFrame > pOldParam->iMaxNumRefFrame) {
4182+ if ((pNewParam->iMaxNumRefFrame > pOldParam->iMaxNumRefFrame) ||
4183+ ((pOldParam->iMaxNumRefFrame == 1) && (pOldParam->iTemporalLayerNum == 1) && (pNewParam->iTemporalLayerNum == 2))) {
41834184 bNeedReset = true;
41844185 }
41854186 if (bNeedReset) {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t