Showing the changes to codec/encoder/core/src/encoder_ext.cpp (1 of 2 files). Show all
Unified · Split
| @@ -80,7 +80,7 @@ int32_t ParamValidation (SWelsSvcCodingParam* pCfg) { · 79 unmodified lines | ||
| 80 | 80 | assert (pCfg != NULL); |
| 81 | 81 | |
| 82 | 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 | 84 | return ENC_RETURN_UNSUPPORTED_PARA; |
| 85 | 85 | } |
| 86 | 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 | 115 | //bitrate setting validation |
| 116 | − if (pCfg->iRCMode != RC_OFF_MODE){ | |
| 116 | + if (pCfg->iRCMode != RC_OFF_MODE) { | |
| 117 | 117 | int32_t iTotalBitrate = 0; |
| 118 | 118 | for (i = 0; i < pCfg->iSpatialLayerNum; ++ i) { |
| 119 | 119 | SDLayerParam* fDlp = &pCfg->sDependencyLayers[i]; |
| 120 | 120 | iTotalBitrate += fDlp->iSpatialBitrate; |
| 121 | 121 | } |
| 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", | |
| 124 | − iTotalBitrate,pCfg->iTargetBitrate); | |
| 122 | + if (iTotalBitrate > pCfg->iTargetBitrate) { | |
| 123 | + WelsLog (NULL, WELS_LOG_ERROR, | |
| 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 | |