History

reformat

sijchen committed 12 years ago

Commit be172611 parent e15742b2 files · +6 −11Browse files

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

Unified · Split

codec/encoder/core/src/encoder_ext.cpp+6−5
@@ -80,7 +80,7 @@ int32_t ParamValidation (SWelsSvcCodingParam* pCfg) { · 79 unmodified lines
80 assert (pCfg != NULL);80 assert (pCfg != NULL);
81 81
82 if ((pCfg->iUsageType != CAMERA_VIDEO_REAL_TIME) && (pCfg->iUsageType != SCREEN_CONTENT_REAL_TIME)) {82 if ((pCfg->iUsageType != CAMERA_VIDEO_REAL_TIME) && (pCfg->iUsageType != SCREEN_CONTENT_REAL_TIME)) {
83 WelsLog (NULL, WELS_LOG_ERROR, "ParamValidation(),Invalid usage type = %d", pCfg->iUsageType);83 WelsLog (NULL, WELS_LOG_ERROR, "ParamValidation(),Invalid usage type = %d\n", pCfg->iUsageType);
84 return ENC_RETURN_UNSUPPORTED_PARA;84 return ENC_RETURN_UNSUPPORTED_PARA;
85 }85 }
86 for (i = 0; i < pCfg->iSpatialLayerNum; ++ i) {86 for (i = 0; i < pCfg->iSpatialLayerNum; ++ i) {
@@ -113,15 +113,16 @@ int32_t ParamValidation (SWelsSvcCodingParam* pCfg) { · 26 unmodified lines
113 }113 }
114 114
115 //bitrate setting validation115 //bitrate setting validation
116 if (pCfg->iRCMode != RC_OFF_MODE){116 if (pCfg->iRCMode != RC_OFF_MODE) {
117 int32_t iTotalBitrate = 0;117 int32_t iTotalBitrate = 0;
118 for (i = 0; i < pCfg->iSpatialLayerNum; ++ i) {118 for (i = 0; i < pCfg->iSpatialLayerNum; ++ i) {
119 SDLayerParam* fDlp = &pCfg->sDependencyLayers[i];119 SDLayerParam* fDlp = &pCfg->sDependencyLayers[i];
120 iTotalBitrate += fDlp->iSpatialBitrate;120 iTotalBitrate += fDlp->iSpatialBitrate;
121 }121 }
122 if(iTotalBitrate > pCfg->iTargetBitrate){122 if (iTotalBitrate > pCfg->iTargetBitrate) {
123 WelsLog(NULL, WELS_LOG_ERROR,"Invalid setttings in bitrate. the sum of each layer bitrate(%d) is larger than total bitrate setting(%d)\n",123 WelsLog (NULL, WELS_LOG_ERROR,
124 iTotalBitrate,pCfg->iTargetBitrate);124 "Invalid setttings in bitrate. the sum of each layer bitrate(%d) is larger than total bitrate setting(%d)\n",
125 iTotalBitrate, pCfg->iTargetBitrate);
125 }126 }
126 }127 }
127 128

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