History

remove duplipate eErrorConMethod in decContext compared with pParam"

huili2 committed 9 years ago

Commit d5e304f1 parent 61b9ddc10 files · +69 −66Browse files

Showing the changes to codec/decoder/core/src/decoder_core.cpp (1 of 10 files). Show all

Unified · Split

codec/decoder/core/src/decoder_core.cpp+10−10
@@ -199,11 +199,11 @@ static inline int32_t DecodeFrameConstruction (PWelsDecoderContext pCtx, uint8_t · 198 unmodified lines
199199 || (pCtx->iLastImgHeightInPixel != pDstInfo->UsrData.sSystemBuffer.iHeight);
200200 pCtx->iLastImgWidthInPixel = pDstInfo->UsrData.sSystemBuffer.iWidth;
201201 pCtx->iLastImgHeightInPixel = pDstInfo->UsrData.sSystemBuffer.iHeight;
202− if (pCtx->eErrorConMethod == ERROR_CON_DISABLE) //no buffer output if EC is disabled and frame incomplete
202+ if (pCtx->pParam->eEcActiveIdc == ERROR_CON_DISABLE) //no buffer output if EC is disabled and frame incomplete
203203 pDstInfo->iBufferStatus = (int32_t) (bFrameCompleteFlag
204204 && pPic->bIsComplete); // When EC disable, ECed picture not output
205− else if ((pCtx->eErrorConMethod == ERROR_CON_SLICE_COPY_CROSS_IDR_FREEZE_RES_CHANGE
206− || pCtx->eErrorConMethod == ERROR_CON_SLICE_MV_COPY_CROSS_IDR_FREEZE_RES_CHANGE)
205+ else if ((pCtx->pParam->eEcActiveIdc == ERROR_CON_SLICE_COPY_CROSS_IDR_FREEZE_RES_CHANGE
206+ || pCtx->pParam->eEcActiveIdc == ERROR_CON_SLICE_MV_COPY_CROSS_IDR_FREEZE_RES_CHANGE)
207207 && pCtx->iErrorCode && bOutResChange)
208208 pCtx->bFreezeOutput = true;
209209
@@ -1247,7 +1247,7 @@ int32_t UpdateAccessUnit (PWelsDecoderContext pCtx) { · 1037 unmodified lines
12471247 WelsLog (& (pCtx->sLogCtx), WELS_LOG_WARNING,
12481248 "UpdateAccessUnit():::::Key frame lost.....CAN NOT find IDR from current AU.");
12491249 pCtx->iErrorCode |= dsRefLost;
1250− if (pCtx->eErrorConMethod == ERROR_CON_DISABLE) {
1250+ if (pCtx->pParam->eEcActiveIdc == ERROR_CON_DISABLE) {
12511251 #ifdef LONG_TERM_REF
12521252 pCtx->iErrorCode |= dsNoParamSets;
12531253 return dsNoParamSets;
@@ -2283,7 +2283,7 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, SBuf · 1029 unmodified lines
22832283
22842284 bAllRefComplete = false;
22852285 pCtx->iErrorCode |= dsRefLost;
2286− if (pCtx->eErrorConMethod == ERROR_CON_DISABLE) {
2286+ if (pCtx->pParam->eEcActiveIdc == ERROR_CON_DISABLE) {
22872287 #ifdef LONG_TERM_REF
22882288 pCtx->bParamSetsLostFlag = true;
22892289 #else
@@ -2303,7 +2303,7 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, SBuf · 13 unmodified lines
23032303 WelsLog (& (pCtx->sLogCtx), WELS_LOG_DEBUG,
23042304 "reference picture introduced by this frame is lost during transmission! uiTId: %d",
23052305 pNalCur->sNalHeaderExt.uiTemporalId);
2306− if (pCtx->eErrorConMethod == ERROR_CON_DISABLE) {
2306+ if (pCtx->pParam->eEcActiveIdc == ERROR_CON_DISABLE) {
23072307 if (pCtx->iTotalNumMbRec == 0)
23082308 pCtx->pDec = NULL;
23092309 return iRet;
@@ -2320,7 +2320,7 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, SBuf · 10 unmodified lines
23202320 iRet, pSh->iFrameNum, iCurrIdD, iCurrIdQ);
23212321 bAllRefComplete = false;
23222322 HandleReferenceLostL0 (pCtx, pNalCur);
2323− if (pCtx->eErrorConMethod == ERROR_CON_DISABLE) {
2323+ if (pCtx->pParam->eEcActiveIdc == ERROR_CON_DISABLE) {
23242324 if (pCtx->iTotalNumMbRec == 0)
23252325 pCtx->pDec = NULL;
23262326 return iRet;
@@ -2380,7 +2380,7 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, SBuf · 53 unmodified lines
23802380 if (!pCtx->bInstantDecFlag) {
23812381 if (!pCtx->pParam->bParseOnly) {
23822382 //Do error concealment here
2383− if ((NeedErrorCon (pCtx)) && (pCtx->eErrorConMethod != ERROR_CON_DISABLE)) {
2383+ if ((NeedErrorCon (pCtx)) && (pCtx->pParam->eEcActiveIdc != ERROR_CON_DISABLE)) {
23842384 ImplementErrorCon (pCtx);
23852385 pCtx->iTotalNumMbRec = pCtx->pSps->iMbWidth * pCtx->pSps->iMbHeight;
23862386 pCtx->pDec->iSpsId = pCtx->pSps->iSpsId;
@@ -2399,7 +2399,7 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, SBuf · 12 unmodified lines
23992399 if (iRet != ERR_NONE) {
24002400 if (iRet == ERR_INFO_DUPLICATE_FRAME_NUM)
24012401 pCtx->iErrorCode |= dsBitstreamError;
2402− if (pCtx->eErrorConMethod == ERROR_CON_DISABLE) {
2402+ if (pCtx->pParam->eEcActiveIdc == ERROR_CON_DISABLE) {
24032403 pCtx->pDec = NULL;
24042404 return iRet;
24052405 }
@@ -2449,7 +2449,7 @@ bool CheckAndFinishLastPic (PWelsDecoderContext pCtx, uint8_t** ppDst, SBufferIn · 43 unmodified lines
24492449
24502450 //Do Error Concealment here
24512451 if (bAuBoundaryFlag && (pCtx->iTotalNumMbRec != 0) && NeedErrorCon (pCtx)) { //AU ready but frame not completely reconed
2452− if (pCtx->eErrorConMethod != ERROR_CON_DISABLE) {
2452+ if (pCtx->pParam->eEcActiveIdc != ERROR_CON_DISABLE) {
24532453 ImplementErrorCon (pCtx);
24542454 pCtx->iTotalNumMbRec = pCtx->pSps->iMbWidth * pCtx->pSps->iMbHeight;
24552455 pCtx->pDec->iSpsId = pCtx->pSps->iSpsId;

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