History

add buffer based rc

ruil2 committed 12 years ago

Commit 36cfb3b1 parent 4cdee3b9 files · +56 −24Browse files

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

Unified · Split

codec/encoder/core/src/encoder_ext.cpp+14−12
@@ -2042,7 +2042,7 @@ int32_t WelsInitEncoderExt (sWelsEncCtx** ppCtx, SWelsSvcCodingParam* pCodingPar · 2041 unmodified lines
2042 if (pCodingParam->iMultipleThreadIdc > 1)2042 if (pCodingParam->iMultipleThreadIdc > 1)
2043 iRet = CreateSliceThreads (pCtx);2043 iRet = CreateSliceThreads (pCtx);
2044 2044
2045 WelsRcInitModule (pCtx, pCtx->pSvcParam->iRCMode != RC_OFF_MODE ? WELS_RC_GOM : WELS_RC_DISABLE);2045 WelsRcInitModule (pCtx, pCtx->pSvcParam->iRCMode);
2046 2046
2047 pCtx->pVpp = new CWelsPreProcess (pCtx);2047 pCtx->pVpp = new CWelsPreProcess (pCtx);
2048 if (pCtx->pVpp == NULL) {2048 if (pCtx->pVpp == NULL) {
@@ -2948,17 +2948,19 @@ int32_t GetSubSequenceId (sWelsEncCtx* pCtx, EVideoFrameType eFrameType) { · 899 unmodified lines
2948bool CheckFrameSkipBasedMaxbr (sWelsEncCtx* pCtx, int32_t iSpatialNum) {2948bool CheckFrameSkipBasedMaxbr (sWelsEncCtx* pCtx, int32_t iSpatialNum) {
2949 SSpatialPicIndex* pSpatialIndexMap = &pCtx->sSpatialIndexMap[0];2949 SSpatialPicIndex* pSpatialIndexMap = &pCtx->sSpatialIndexMap[0];
2950 bool bSkipMustFlag = false;2950 bool bSkipMustFlag = false;
2951 2951 if (pCtx->pSvcParam->bEnableFrameSkip) {
2952 if (RC_OFF_MODE != pCtx->pSvcParam->iRCMode && true == pCtx->pSvcParam->bEnableFrameSkip) {2952 if ((RC_QUALITY_MODE == pCtx->pSvcParam->iRCMode) || (RC_BITRATE_MODE == pCtx->pSvcParam->iRCMode)
2953 for (int32_t i = 0; i < iSpatialNum; i++) {2953 || (RC_LOW_BW_MODE == pCtx->pSvcParam->iRCMode)) {
2954 if (0 == pCtx->pSvcParam->sSpatialLayers[i].iMaxSpatialBitrate) {2954 for (int32_t i = 0; i < iSpatialNum; i++) {
2955 break;2955 if (0 == pCtx->pSvcParam->sSpatialLayers[i].iMaxSpatialBitrate) {
2956 }2956 break;
2957 pCtx->uiDependencyId = (uint8_t) (pSpatialIndexMap + i)->iDid;2957 }
2958 pCtx->pFuncList->pfRc.pfWelsRcPicDelayJudge (pCtx);2958 pCtx->uiDependencyId = (uint8_t) (pSpatialIndexMap + i)->iDid;
2959 if (true == pCtx->pWelsSvcRc[pCtx->uiDependencyId].bSkipFlag) {2959 pCtx->pFuncList->pfRc.pfWelsRcPicDelayJudge (pCtx);
2960 bSkipMustFlag = true;2960 if (true == pCtx->pWelsSvcRc[pCtx->uiDependencyId].bSkipFlag) {
2961 break;2961 bSkipMustFlag = true;
2962 break;
2963 }
2962 }2964 }
2963 }2965 }
2964 }2966 }

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