bool is one of the built in, standard types in C++, there's no need for a typedef for it.
Showing the changes to codec/decoder/core/src/decoder_core.cpp (1 of 82 files). Show all
Unified · Split
| @@ -105,7 +105,7 @@ static inline int32_t DecodeFrameConstruction (PWelsDecoderContext pCtx, uint8_t · 104 unmodified lines | ||
| 105 | 105 | return 0; |
| 106 | 106 | } |
| 107 | 107 | |
| 108 | −inline bool_t CheckSliceNeedReconstruct (int16_t iCurDid, int16_t iCurQid, bool_t bStoreRefBasePicFlag, | |
| 108 | +inline bool CheckSliceNeedReconstruct (int16_t iCurDid, int16_t iCurQid, bool bStoreRefBasePicFlag, | |
| 109 | 109 | uint8_t uiDidMax, uint8_t uiLayerDqId, uint8_t uiTargetDqId) { |
| 110 | 110 | return ((iCurDid == uiDidMax) && (iCurQid == BASE_QUALITY_ID) && (bStoreRefBasePicFlag)) // store base |
| 111 | 111 | || (uiLayerDqId == uiTargetDqId); // target layer |
| @@ -201,7 +201,7 @@ int32_t ParseRefPicListReordering (PBitStringAux pBs, PSliceHeader pSh) { · 89 unmodified lines | ||
| 201 | 201 | } |
| 202 | 202 | |
| 203 | 203 | int32_t ParseDecRefPicMarking (PWelsDecoderContext pCtx, PBitStringAux pBs, PSliceHeader pSh, PSps pSps, |
| 204 | − const bool_t kbIdrFlag) { | |
| 204 | + const bool kbIdrFlag) { | |
| 205 | 205 | PRefPicMarking const kpRefMarking = &pSh->sRefMarking; |
| 206 | 206 | |
| 207 | 207 | if (kbIdrFlag) { |
| @@ -238,7 +238,7 @@ int32_t ParseDecRefPicMarking (PWelsDecoderContext pCtx, PBitStringAux pBs, PSli · 30 unmodified lines | ||
| 238 | 238 | return ERR_NONE; |
| 239 | 239 | } |
| 240 | 240 | |
| 241 | −bool_t FillDefaultSliceHeaderExt (PSliceHeaderExt pShExt, PNalUnitHeaderExt pNalExt) { | |
| 241 | +bool FillDefaultSliceHeaderExt (PSliceHeaderExt pShExt, PNalUnitHeaderExt pNalExt) { | |
| 242 | 242 | if (pShExt == NULL || pNalExt == NULL) |
| 243 | 243 | return false; |
| 244 | 244 | |
| @@ -392,7 +392,7 @@ int32_t CheckPpsId (PWelsDecoderContext pCtx, PPps* ppPps, uint32_t uiPpsId) { · 147 unmodified lines | ||
| 392 | 392 | } |
| 393 | 393 | |
| 394 | 394 | int32_t CheckSpsId (PWelsDecoderContext pCtx, PSubsetSps* ppSubsetSps, PSps* ppSps, int32_t iSpsId, |
| 395 | − bool_t bExtensionFlag) { | |
| 395 | + bool bExtensionFlag) { | |
| 396 | 396 | PSps pSpsList = pCtx->sSpsBuffer; |
| 397 | 397 | PSubsetSps pSubspsList = pCtx->sSubsetSpsBuffer; |
| 398 | 398 | |
| @@ -455,7 +455,7 @@ int32_t CheckSpsId (PWelsDecoderContext pCtx, PSubsetSps* ppSubsetSps, PSps* ppS · 56 unmodified lines | ||
| 455 | 455 | * decode_slice_header_avc |
| 456 | 456 | * Parse slice header of bitstream in avc for storing data structure |
| 457 | 457 | */ |
| 458 | −int32_t ParseSliceHeaderSyntaxs (PWelsDecoderContext pCtx, PBitStringAux pBs, const bool_t kbExtensionFlag) { | |
| 458 | +int32_t ParseSliceHeaderSyntaxs (PWelsDecoderContext pCtx, PBitStringAux pBs, const bool kbExtensionFlag) { | |
| 459 | 459 | PNalUnit const kpCurNal = pCtx->pAccessUnitList->pNalUnitsList[pCtx->pAccessUnitList->uiAvailUnitsNum - 1]; |
| 460 | 460 | |
| 461 | 461 | PNalUnitHeaderExt pNalHeaderExt = NULL; |
| @@ -469,8 +469,8 @@ int32_t ParseSliceHeaderSyntaxs (PWelsDecoderContext pCtx, PBitStringAux pBs, co · 7 unmodified lines | ||
| 469 | 469 | int32_t iRet = ERR_NONE; |
| 470 | 470 | uint8_t uiSliceType = 0; |
| 471 | 471 | uint8_t uiQualityId = BASE_QUALITY_ID; |
| 472 | − bool_t bIdrFlag = false; | |
| 473 | − bool_t bSgChangeCycleInvolved = false; // involved slice group change cycle ? | |
| 472 | + bool bIdrFlag = false; | |
| 473 | + bool bSgChangeCycleInvolved = false; // involved slice group change cycle ? | |
| 474 | 474 | |
| 475 | 475 | if (kpCurNal == NULL) { |
| 476 | 476 | return ERR_INFO_OUT_OF_MEMORY; |
| @@ -484,7 +484,7 @@ int32_t ParseSliceHeaderSyntaxs (PWelsDecoderContext pCtx, PBitStringAux pBs, co · 7 unmodified lines | ||
| 484 | 484 | |
| 485 | 485 | if (pSliceHeadExt) { |
| 486 | 486 | SRefBasePicMarking sBaseMarking; |
| 487 | − const bool_t kbStoreRefBaseFlag = pSliceHeadExt->bStoreRefBasePicFlag; | |
| 487 | + const bool kbStoreRefBaseFlag = pSliceHeadExt->bStoreRefBasePicFlag; | |
| 488 | 488 | memcpy (&sBaseMarking, &pSliceHeadExt->sRefBasePicMarking, sizeof (SRefBasePicMarking)); //confirmed_safe_unsafe_usage |
| 489 | 489 | memset (pSliceHeadExt, 0, sizeof (SSliceHeaderExt)); |
| 490 | 490 | pSliceHeadExt->bStoreRefBasePicFlag = kbStoreRefBaseFlag; |
| @@ -619,7 +619,7 @@ int32_t ParseSliceHeaderSyntaxs (PWelsDecoderContext pCtx, PBitStringAux pBs, co · 128 unmodified lines | ||
| 619 | 619 | if (kbExtensionFlag) { |
| 620 | 620 | uiQualityId = pNalHeaderExt->uiQualityId; |
| 621 | 621 | } else if (uiSliceType == P_SLICE || uiSliceType == SP_SLICE || uiSliceType == B_SLICE) { |
| 622 | − const bool_t kbBipredFlag = (B_SLICE == uiSliceType); | |
| 622 | + const bool kbBipredFlag = (B_SLICE == uiSliceType); | |
| 623 | 623 | if (kbBipredFlag) { |
| 624 | 624 | WelsLog (pCtx, WELS_LOG_WARNING, "ParseSliceHeaderSyntaxs(): kbBipredFlag = 1 not supported.\n"); |
| 625 | 625 | return GENERATE_ERROR_NO (ERR_LEVEL_SLICE_HEADER, ERR_INFO_UNSUPPORTED_BIPRED); |
| @@ -820,7 +820,7 @@ int32_t ParseSliceHeaderSyntaxs (PWelsDecoderContext pCtx, PBitStringAux pBs, co · 194 unmodified lines | ||
| 820 | 820 | * pSrc: mark as decoded prefix NAL |
| 821 | 821 | * ppDst: succeeded VCL NAL based AVC (I/P Slice) |
| 822 | 822 | */ |
| 823 | −bool_t PrefetchNalHeaderExtSyntax (PWelsDecoderContext pCtx, PNalUnit const kppDst, PNalUnit const kpSrc) { | |
| 823 | +bool PrefetchNalHeaderExtSyntax (PWelsDecoderContext pCtx, PNalUnit const kppDst, PNalUnit const kpSrc) { | |
| 824 | 824 | PNalUnitHeaderExt pNalHdrExtD = NULL, pNalHdrExtS = NULL; |
| 825 | 825 | PSliceHeaderExt pShExtD = NULL; |
| 826 | 826 | PPrefixNalUnit pPrefixS = NULL; |
| @@ -1297,7 +1297,7 @@ void_t RefineIdxNoInterLayerPred (PAccessUnit pCurAu, int32_t* pIdxNoInterLayerP · 470 unmodified lines | ||
| 1297 | 1297 | int32_t iCurNalDependId, iCurNalQualityId, iCurNalTId, iCurNalFrameNum, iCurNalPoc, iCurNalFirstMb, iCurIdx, |
| 1298 | 1298 | iFinalIdxNoInterLayerPred; |
| 1299 | 1299 | |
| 1300 | − bool_t bMultiSliceFind = false; | |
| 1300 | + bool bMultiSliceFind = false; | |
| 1301 | 1301 | |
| 1302 | 1302 | iFinalIdxNoInterLayerPred = 0; |
| 1303 | 1303 | iCurIdx = *pIdxNoInterLayerPred - 1; |
| @@ -1332,7 +1332,7 @@ void_t RefineIdxNoInterLayerPred (PAccessUnit pCurAu, int32_t* pIdxNoInterLayerP · 28 unmodified lines | ||
| 1332 | 1332 | } |
| 1333 | 1333 | } |
| 1334 | 1334 | |
| 1335 | −bool_t CheckPocOfCurValidNalUnits (PAccessUnit pCurAu, int32_t pIdxNoInterLayerPred) { | |
| 1335 | +bool CheckPocOfCurValidNalUnits (PAccessUnit pCurAu, int32_t pIdxNoInterLayerPred) { | |
| 1336 | 1336 | int32_t iEndIdx = pCurAu->uiEndPos; |
| 1337 | 1337 | int32_t iCurAuPoc = |
| 1338 | 1338 | pCurAu->pNalUnitsList[pIdxNoInterLayerPred]->sNalData.sVclNal.sSliceHeaderExt.sSliceHeader.iPicOrderCntLsb; |
| @@ -1347,7 +1347,7 @@ bool_t CheckPocOfCurValidNalUnits (PAccessUnit pCurAu, int32_t pIdxNoInterLayerP · 8 unmodified lines | ||
| 1347 | 1347 | return true; |
| 1348 | 1348 | } |
| 1349 | 1349 | |
| 1350 | −bool_t CheckIntegrityNalUnitsList (PWelsDecoderContext pCtx) { | |
| 1350 | +bool CheckIntegrityNalUnitsList (PWelsDecoderContext pCtx) { | |
| 1351 | 1351 | PAccessUnit pCurAu = pCtx->pAccessUnitList; |
| 1352 | 1352 | const int32_t kiEndPos = pCurAu->uiEndPos; |
| 1353 | 1353 | int32_t iIdxNoInterLayerPred = 0; |
| @@ -1391,7 +1391,7 @@ bool_t CheckIntegrityNalUnitsList (PWelsDecoderContext pCtx) { · 37 unmodified lines | ||
| 1391 | 1391 | pCurAu->pNalUnitsList[pCurAu->uiEndPos]->sNalData.sVclNal.sSliceHeaderExt.sSliceHeader.iMbHeight << 4; |
| 1392 | 1392 | } else { //P_SLICE |
| 1393 | 1393 | //step 1: search uiDependencyId equal to pCtx->cur_seq_interval_target_dependency_id |
| 1394 | − bool_t bGetDependId = false; | |
| 1394 | + bool bGetDependId = false; | |
| 1395 | 1395 | int32_t iIdxDependId = 0; |
| 1396 | 1396 | |
| 1397 | 1397 | iIdxDependId = kiEndPos; |
| @@ -1406,7 +1406,7 @@ bool_t CheckIntegrityNalUnitsList (PWelsDecoderContext pCtx) { · 8 unmodified lines | ||
| 1406 | 1406 | |
| 1407 | 1407 | //step 2: switch according to whether or not find the index of pNalUnit whose uiDependencyId equal to iCurSeqIntervalTargetDependId |
| 1408 | 1408 | if (bGetDependId) { //get the index of pNalUnit whose uiDependencyId equal to iCurSeqIntervalTargetDependId |
| 1409 | − bool_t bGetNoInterPredFront = false; | |
| 1409 | + bool bGetNoInterPredFront = false; | |
| 1410 | 1410 | //step 2a: search iNoInterLayerPredFlag [0....iIdxDependId] |
| 1411 | 1411 | iIdxNoInterLayerPred = iIdxDependId; |
| 1412 | 1412 | while (iIdxNoInterLayerPred >= 0) { |
| @@ -1650,7 +1650,7 @@ void_t WelsDqLayerDecodeStart (PWelsDecoderContext pCtx, PNalUnit pCurNal, PSps · 237 unmodified lines | ||
| 1650 | 1650 | } |
| 1651 | 1651 | } |
| 1652 | 1652 | |
| 1653 | −int32_t InitRefPicList (PWelsDecoderContext pCtx, const uint8_t kuiNRi, const bool_t kbFirstSlice, int32_t iPoc) { | |
| 1653 | +int32_t InitRefPicList (PWelsDecoderContext pCtx, const uint8_t kuiNRi, const bool kbFirstSlice, int32_t iPoc) { | |
| 1654 | 1654 | int32_t iRet = ERR_NONE; |
| 1655 | 1655 | if (kbFirstSlice) |
| 1656 | 1656 | iRet = WelsInitRefList (pCtx, iPoc); |
| @@ -1718,7 +1718,7 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, int3 · 61 unmodified lines | ||
| 1718 | 1718 | int16_t iLastIdD = -1, iLastIdQ = -1; |
| 1719 | 1719 | int16_t iCurrIdD = 0, iCurrIdQ = 0; |
| 1720 | 1720 | uint8_t uiNalRefIdc = 0; |
| 1721 | − bool_t bFreshSliceAvailable = | |
| 1721 | + bool bFreshSliceAvailable = | |
| 1722 | 1722 | true; // Another fresh slice comingup for given dq layer, for multiple slices in case of header parts of slices sometimes loss over error-prone channels, 8/14/2008 |
| 1723 | 1723 | PPicture pStoreBasePic = NULL; |
| 1724 | 1724 | |
| @@ -1774,7 +1774,7 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, int3 · 49 unmodified lines | ||
| 1774 | 1774 | * Loop decoding for slices (even FMO and/ multiple slices) within a dq layer |
| 1775 | 1775 | */ |
| 1776 | 1776 | while (iIdx <= iEndIdx) { |
| 1777 | − bool_t bReconstructSlice; | |
| 1777 | + bool bReconstructSlice; | |
| 1778 | 1778 | iCurrIdQ = pNalCur->sNalHeaderExt.uiQualityId; |
| 1779 | 1779 | iCurrIdD = pNalCur->sNalHeaderExt.uiDependencyId; |
| 1780 | 1780 | pSh = &pNalCur->sNalData.sVclNal.sSliceHeaderExt.sSliceHeader; |
| @@ -1823,7 +1823,7 @@ int32_t DecodeCurrentAccessUnit (PWelsDecoderContext pCtx, uint8_t** ppDst, int3 · 42 unmodified lines | ||
| 1823 | 1823 | InitDqLayerInfo (dq_cur, &pLayerInfo, pNalCur, pCtx->pDec); |
| 1824 | 1824 | |
| 1825 | 1825 | if (!dq_cur->sLayerInfo.pSps->bGapsInFrameNumValueAllowedFlag) { |
| 1826 | − const bool_t kbIdrFlag = dq_cur->sLayerInfo.sNalHeaderExt.bIdrFlag | |
| 1826 | + const bool kbIdrFlag = dq_cur->sLayerInfo.sNalHeaderExt.bIdrFlag | |
| 1827 | 1827 | || (dq_cur->sLayerInfo.sNalHeaderExt.sNalUnitHeader.eNalUnitType == NAL_UNIT_CODED_SLICE_IDR); |
| 1828 | 1828 | // Subclause 8.2.5.2 Decoding process for gaps in frame_num |
| 1829 | 1829 | if (!kbIdrFlag && |