Showing the changes to codec/decoder/core/src/decoder.cpp (1 of 57 files). Show all
Unified · Split
| @@ -272,7 +272,7 @@ void DestroyPicBuff (PPicBuff* ppPicBuf) { · 271 unmodified lines | ||
| 272 | 272 | */ |
| 273 | 273 | void WelsDecoderDefaults (PWelsDecoderContext pCtx, SLogContext* pLogCtx) { |
| 274 | 274 | int32_t iCpuCores = 1; |
| 275 | − memset (pCtx, 0, sizeof (SWelsDecoderContext)); // fill zero first | |
| 275 | + memset (pCtx, 0, sizeof (SWelsDecoderContext)); // fill zero first | |
| 276 | 276 | pCtx->sLogCtx = *pLogCtx; |
| 277 | 277 | |
| 278 | 278 | pCtx->pArgDec = NULL; |
| @@ -369,14 +369,14 @@ int32_t WelsRequestMem (PWelsDecoderContext pCtx, const int32_t kiMbWidth, const · 90 unmodified lines | ||
| 369 | 369 | pCtx->iPicQueueNumber = iPicQueueSize; |
| 370 | 370 | if (pCtx->pPicBuff[LIST_0] != NULL |
| 371 | 371 | && pCtx->pPicBuff[LIST_0]->iCapacity == |
| 372 | − iPicQueueSize) // comparing current picture queue size requested and previous allocation picture queue | |
| 373 | − bNeedChangePicQueue = false; | |
| 372 | + iPicQueueSize) // comparing current picture queue size requested and previous allocation picture queue | |
| 373 | + bNeedChangePicQueue = false; | |
| 374 | 374 | // HD based pic buffer need consider memory size consumed when switch from 720p to other lower size |
| 375 | 375 | WELS_VERIFY_RETURN_IF (ERR_NONE, pCtx->bHaveGotMemory && (kiPicWidth == pCtx->iImgWidthInPixel |
| 376 | − && kiPicHeight == pCtx->iImgHeightInPixel) && (!bNeedChangePicQueue)) // have same scaled buffer | |
| 376 | + && kiPicHeight == pCtx->iImgHeightInPixel) && (!bNeedChangePicQueue)) // have same scaled buffer | |
| 377 | 377 | |
| 378 | 378 | // sync update pRefList |
| 379 | − WelsResetRefPic (pCtx); // added to sync update ref list due to pictures are free | |
| 379 | + WelsResetRefPic (pCtx); // added to sync update ref list due to pictures are free | |
| 380 | 380 | |
| 381 | 381 | if (pCtx->bHaveGotMemory && (kiPicWidth == pCtx->iImgWidthInPixel && kiPicHeight == pCtx->iImgHeightInPixel) |
| 382 | 382 | && pCtx->pPicBuff[LIST_0] != NULL && pCtx->pPicBuff[LIST_0]->iCapacity != iPicQueueSize) { |
| @@ -621,7 +621,7 @@ int32_t WelsDecodeBs (PWelsDecoderContext pCtx, const uint8_t* kpBsBuf, const in · 238 unmodified lines | ||
| 621 | 621 | int32_t iSrcIdx = 0; //the index of source bit-stream till now after parsing one or more NALs |
| 622 | 622 | int32_t iSrcConsumed = 0; // consumed bit count of source bs |
| 623 | 623 | int32_t iDstIdx = 0; //the size of current NAL after 0x03 removal and 00 00 01 removal |
| 624 | − int32_t iSrcLength = 0; //the total size of current AU or NAL | |
| 624 | + int32_t iSrcLength = 0; //the total size of current AU or NAL | |
| 625 | 625 | int32_t iRet = 0; |
| 626 | 626 | int32_t iConsumedBytes = 0; |
| 627 | 627 | int32_t iOffset = 0; |
| @@ -820,7 +820,7 @@ int32_t SyncPictureResolutionExt (PWelsDecoderContext pCtx, const int32_t kiMbWi · 192 unmodified lines | ||
| 820 | 820 | const int32_t kiPicWidth = kiMbWidth << 4; |
| 821 | 821 | const int32_t kiPicHeight = kiMbHeight << 4; |
| 822 | 822 | |
| 823 | − iErr = WelsRequestMem (pCtx, kiMbWidth, kiMbHeight); // common memory used | |
| 823 | + iErr = WelsRequestMem (pCtx, kiMbWidth, kiMbHeight); // common memory used | |
| 824 | 824 | if (ERR_NONE != iErr) { |
| 825 | 825 | WelsLog (& (pCtx->sLogCtx), WELS_LOG_WARNING, |
| 826 | 826 | "SyncPictureResolutionExt()::WelsRequestMem--buffer allocated failure."); |