Increase the minimum frame size in a test with multiple spatial layers

Make sure the input frame size is large enough that the downsampled
layers also have a nonzero resolution.
This commit is contained in:
Martin Storsjö 2014-12-16 11:10:56 +02:00
parent 59fefbe7c7
commit f4b3724976

View File

@ -2057,11 +2057,11 @@ TEST_F (EncodeDecodeTestAPI, Engine_SVC_Switch_P) {
}
TEST_F (EncodeDecodeTestAPI, SetOptionEncParamExt) {
int iWidth = WelsClip3 ((((rand() % MAX_WIDTH) >> 1) + 1) << 1, 2, MAX_WIDTH);
int iHeight = WelsClip3 ((((rand() % MAX_HEIGHT) >> 1) + 1) << 1, 2, MAX_HEIGHT);
int iSpatialLayerNum = 4;
int iWidth = WelsClip3 ((((rand() % MAX_WIDTH) >> 1) + 1) << 1, 1 << iSpatialLayerNum, MAX_WIDTH);
int iHeight = WelsClip3 ((((rand() % MAX_HEIGHT) >> 1) + 1) << 1, 1 << iSpatialLayerNum, MAX_HEIGHT);
float fFrameRate = rand() + 0.5f;
int iEncFrameNum = WelsClip3 ((rand() % ENCODE_FRAME_NUM) + 1, 1, ENCODE_FRAME_NUM);
int iSpatialLayerNum = 4;
int iSliceNum = 1;
encoder_->GetDefaultParams (&param_);
prepareParam (iSpatialLayerNum, iSliceNum, iWidth, iHeight, fFrameRate);