Validate that iLoopFilterDisableIdc is set to a sensible value in ParamValidationExt
In WelsEncoderParamAdjust it is already clipped in the same way, but here we should probably rather error out than to silently clip it to the right range.
This commit is contained in:
parent
24cd934ba9
commit
0bae0f869a
@ -261,6 +261,12 @@ int32_t ParamValidationExt (SLogContext* pLogCtx, SWelsSvcCodingParam* pCodingPa
|
||||
pCodingParam->uiIntraPeriod, pCodingParam->uiGopSize);
|
||||
return ENC_RETURN_UNSUPPORTED_PARA;
|
||||
}
|
||||
if (pCodingParam->iLoopFilterDisableIdc < 0 || pCodingParam->iLoopFilterDisableIdc > 6) {
|
||||
WelsLog (pLogCtx, WELS_LOG_ERROR,
|
||||
"ParamValidationExt(), iLoopFilterDisableIdc(%d) must be between 0 and 6",
|
||||
pCodingParam->iLoopFilterDisableIdc);
|
||||
return ENC_RETURN_UNSUPPORTED_PARA;
|
||||
}
|
||||
|
||||
|
||||
//about iMultipleThreadIdc, bDeblockingParallelFlag, iLoopFilterDisableIdc, & uiSliceMode
|
||||
|
Loading…
x
Reference in New Issue
Block a user