Respect the bEnableRc field in SEncParamExt
This commit is contained in:
parent
f432ddeea8
commit
b6502a5406
@ -275,7 +275,7 @@ int32_t ParamBaseTranscode (const SEncParamBase& pCodingParam, const bool kbEnab
|
||||
|
||||
return 0;
|
||||
}
|
||||
int32_t ParamTranscode (const SEncParamExt& pCodingParam, const bool kbEnableRc = true) {
|
||||
int32_t ParamTranscode (const SEncParamExt& pCodingParam) {
|
||||
float fParamMaxFrameRate = WELS_CLIP3 (pCodingParam.fMaxFrameRate, MIN_FRAME_RATE, MAX_FRAME_RATE);
|
||||
|
||||
iInputCsp = pCodingParam.iInputCsp; // color space of input sequence
|
||||
@ -305,7 +305,7 @@ int32_t ParamTranscode (const SEncParamExt& pCodingParam, const bool kbEnableRc
|
||||
bEnableFrameCroppingFlag = true;
|
||||
|
||||
/* Rate Control */
|
||||
bEnableRc = kbEnableRc;
|
||||
bEnableRc = pCodingParam.bEnableRc;
|
||||
if (pCodingParam.iRCMode != RC_MODE0 && pCodingParam.iRCMode != RC_MODE1)
|
||||
iRCMode = RC_MODE1;
|
||||
else
|
||||
|
@ -222,7 +222,7 @@ int CWelsH264SVCEncoder::Initialize (const SEncParamBase* argv, const INIT_TYPE
|
||||
else if(iInitType == INIT_TYPE_PARAMETER_EXT)
|
||||
{
|
||||
// Convert SEncParamExt into WelsSVCParamConfig here..
|
||||
if (sConfig.ParamTranscode (*(const SEncParamExt*)argv, true)) {
|
||||
if (sConfig.ParamTranscode (*(const SEncParamExt*)argv)) {
|
||||
WelsLog (m_pEncContext, WELS_LOG_ERROR, "CWelsH264SVCEncoder::Initialize(), parameter_translation failed.\n");
|
||||
Uninitialize();
|
||||
return cmInitParaError;
|
||||
@ -785,7 +785,7 @@ int CWelsH264SVCEncoder::SetOption (ENCODER_OPTION eOptionId, void* pOption) {
|
||||
}
|
||||
|
||||
iInputColorspace = sEncodingParam.iInputCsp;
|
||||
if (sConfig.ParamTranscode (sEncodingParam, true)) {
|
||||
if (sConfig.ParamTranscode (sEncodingParam)) {
|
||||
return cmInitParaError;
|
||||
}
|
||||
if (sConfig.iSpatialLayerNum < 1) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user