History

Use bool instead of bool_t

bool is one of the built in, standard types in C++, there's no need for a typedef for it.

Martin Storsjö committed 12 years ago

Commit 2b77fe71 parent 17d7b5d82 files · +468 −471Browse files

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

Unified · Split

codec/encoder/core/src/wels_preprocess.cpp+13−13
@@ -60,7 +60,7 @@ typedef EResult (WELSAPI* pfnCreateVpInterface) (void**, int); · 59 unmodified lines
6060 typedef EResult (WELSAPI* pfnDestroyVpInterface) (void*, int);
6161
6262 int32_t WelsInitScaledPic (SWelsSvcCodingParam* pParam, Scaled_Picture* pScaledPic, CMemoryAlign* pMemoryAlign);
63−bool_t JudgeNeedOfScaling (SWelsSvcCodingParam* pParam, Scaled_Picture* pScaledPic);
63+bool JudgeNeedOfScaling (SWelsSvcCodingParam* pParam, Scaled_Picture* pScaledPic);
6464 void FreeScaledPic (Scaled_Picture* pScaledPic, CMemoryAlign* pMemoryAlign);
6565
6666 //******* table definition ***********************************************************************//
@@ -313,8 +313,8 @@ int32_t CWelsPreProcess::WelsPreprocessStep1 (void* pCtx, const SSourcePicture** · 246 unmodified lines
313313 int32_t CWelsPreProcess::WelsPreprocessStep3 (void* pCtx, const int32_t kiDidx) {
314314 sWelsEncCtx* pEncCtx = (sWelsEncCtx*)pCtx;
315315 SWelsSvcCodingParam* pSvcParam = pEncCtx->pSvcParam;
316− bool_t bNeededMbAq = (pSvcParam->bEnableAdaptiveQuant && (pEncCtx->eSliceType == P_SLICE));
317− bool_t bCalculateBGD = (pEncCtx->eSliceType == P_SLICE && pSvcParam->bEnableBackgroundDetection);
316+ bool bNeededMbAq = (pSvcParam->bEnableAdaptiveQuant && (pEncCtx->eSliceType == P_SLICE));
317+ bool bCalculateBGD = (pEncCtx->eSliceType == P_SLICE && pSvcParam->bEnableBackgroundDetection);
318318
319319 int32_t iCurTemporalIdx = pEncCtx->uiSpatialLayersInTemporal[kiDidx] - 1;
320320
@@ -327,8 +327,8 @@ int32_t CWelsPreProcess::WelsPreprocessStep3 (void* pCtx, const int32_t kiDidx) · 6 unmodified lines
327327 SPicture* pRefPic = pEncCtx->pSpatialPic[kiDidx][iRefTemporalIdx];
328328 {
329329 SPicture* pLastPic = m_pLastSpatialPicture[kiDidx][0];
330− bool_t bCalculateSQDiff = ((pLastPic->pData[0] == pRefPic->pData[0]) && bNeededMbAq);
331− bool_t bCalculateVar = (pSvcParam->iRCMode == RC_MODE1 && pEncCtx->eSliceType == I_SLICE);
330+ bool bCalculateSQDiff = ((pLastPic->pData[0] == pRefPic->pData[0]) && bNeededMbAq);
331+ bool bCalculateVar = (pSvcParam->iRCMode == RC_MODE1 && pEncCtx->eSliceType == I_SLICE);
332332
333333 VaaCalculation (pEncCtx->pVaa, pCurPic, pRefPic, bCalculateSQDiff, bCalculateVar, bCalculateBGD);
334334 }
@@ -517,12 +517,12 @@ int32_t CWelsPreProcess::MultiLayerPreprocess (void* pCtx, const SSourcePicture* · 182 unmodified lines
517517 /*!
518518 * \brief Whether input picture need be scaled?
519519 */
520−bool_t JudgeNeedOfScaling (SWelsSvcCodingParam* pParam, Scaled_Picture* pScaledPicture) {
520+bool JudgeNeedOfScaling (SWelsSvcCodingParam* pParam, Scaled_Picture* pScaledPicture) {
521521 const int32_t kiInputPicWidth = pParam->SUsedPicRect.iWidth;
522522 const int32_t kiInputPicHeight = pParam->SUsedPicRect.iHeight;
523523 const int32_t kiDstPicWidth = pParam->sDependencyLayers[pParam->iNumDependencyLayer - 1].iActualWidth;
524524 const int32_t kiDstPicHeight = pParam->sDependencyLayers[pParam->iNumDependencyLayer - 1].iActualHeight;
525− bool_t bNeedDownsampling = true;
525+ bool bNeedDownsampling = true;
526526
527527 int32_t iSpatialIdx = pParam->iNumDependencyLayer - 1;
528528
@@ -551,7 +551,7 @@ bool_t JudgeNeedOfScaling (SWelsSvcCodingParam* pParam, Scaled_Picture* pScaledP · 22 unmodified lines
551551 }
552552
553553 int32_t WelsInitScaledPic (SWelsSvcCodingParam* pParam, Scaled_Picture* pScaledPicture, CMemoryAlign* pMemoryAlign) {
554− bool_t bInputPicNeedScaling = JudgeNeedOfScaling (pParam, pScaledPicture);
554+ bool bInputPicNeedScaling = JudgeNeedOfScaling (pParam, pScaledPicture);
555555 if (bInputPicNeedScaling) {
556556 pScaledPicture->pScaledInputPicture = AllocPicture (pMemoryAlign, pParam->SUsedPicRect.iWidth,
557557 pParam->SUsedPicRect.iHeight, false);
@@ -611,8 +611,8 @@ void CWelsPreProcess::BilateralDenoising (SPicture* pSrc, const int32_t kiWidth, · 53 unmodified lines
611611 m_pInterfaceVp->Process (iMethodIdx, &sSrcPixMap, NULL);
612612 }
613613
614−bool_t CWelsPreProcess::DetectSceneChange (SPicture* pCurPicture, SPicture* pRefPicture) {
615− bool_t bSceneChangeFlag = false;
614+bool CWelsPreProcess::DetectSceneChange (SPicture* pCurPicture, SPicture* pRefPicture) {
615+ bool bSceneChangeFlag = false;
616616 int32_t iMethodIdx = METHOD_SCENE_CHANGE_DETECTION;
617617 SSceneChangeResult sSceneChangeDetectResult = {0};
618618 SPixMap sSrcPixMap = {0};
@@ -688,7 +688,7 @@ int32_t CWelsPreProcess::DownsamplePadding (SPicture* pSrc, SPicture* pDstPic, · 69 unmodified lines
688688
689689 //*********************************************************************************************************/
690690 void CWelsPreProcess::VaaCalculation (SVAAFrameInfo* pVaaInfo, SPicture* pCurPicture, SPicture* pRefPicture,
691− bool_t bCalculateSQDiff, bool_t bCalculateVar, bool_t bCalculateBGD) {
691+ bool bCalculateSQDiff, bool bCalculateVar, bool bCalculateBGD) {
692692 pVaaInfo->sVaaCalcInfo.pCurY = pCurPicture->pData[0];
693693 pVaaInfo->sVaaCalcInfo.pRefY = pRefPicture->pData[0];
694694 {
@@ -722,7 +722,7 @@ void CWelsPreProcess::VaaCalculation (SVAAFrameInfo* pVaaInfo, SPicture* pCurPic · 27 unmodified lines
722722 }
723723
724724 void CWelsPreProcess::BackgroundDetection (SVAAFrameInfo* pVaaInfo, SPicture* pCurPicture, SPicture* pRefPicture,
725− bool_t bDetectFlag) {
725+ bool bDetectFlag) {
726726 if (bDetectFlag) {
727727 pVaaInfo->iPicWidth = pCurPicture->iWidthInPixel;
728728 pVaaInfo->iPicHeight = pCurPicture->iHeightInPixel;
@@ -834,7 +834,7 @@ void CWelsPreProcess::SetRefMbType (void* pCtx, uint32_t** pRefMbTypeArray, int3 · 105 unmodified lines
834834
835835
836836 void CWelsPreProcess::AnalyzePictureComplexity (void* pCtx, SPicture* pCurPicture, SPicture* pRefPicture,
837− const int32_t kiDependencyId, const bool_t bCalculateBGD) {
837+ const int32_t kiDependencyId, const bool bCalculateBGD) {
838838 sWelsEncCtx* pEncCtx = (sWelsEncCtx*)pCtx;
839839 SWelsSvcCodingParam* pSvcParam = pEncCtx->pSvcParam;
840840 SVAAFrameInfo* pVaaInfo = pEncCtx->pVaa;

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