Showing the changes to test/api/BaseEncoderTest.cpp (1 of 3 files). Show all
Unified · Split
| @@ -20,7 +20,6 @@ static int InitWithParam (ISVCEncoder* encoder, SEncParamExt* pEncParamExt) { · 19 unmodified lines | ||
| 20 | 20 | param.iPicWidth = pEncParamExt->iPicWidth; |
| 21 | 21 | param.iPicHeight = pEncParamExt->iPicHeight; |
| 22 | 22 | param.iTargetBitrate = 5000000; |
| 23 | − | |
| 24 | 23 | return encoder->Initialize (¶m); |
| 25 | 24 | } else { |
| 26 | 25 | SEncParamExt param; |
| @@ -36,7 +35,8 @@ static int InitWithParam (ISVCEncoder* encoder, SEncParamExt* pEncParamExt) { · 9 unmodified lines | ||
| 36 | 35 | param.bIsLosslessLink = pEncParamExt->bIsLosslessLink; |
| 37 | 36 | param.bEnableLongTermReference = pEncParamExt->bEnableLongTermReference; |
| 38 | 37 | param.iEntropyCodingModeFlag = pEncParamExt->iEntropyCodingModeFlag ? 1 : 0; |
| 39 | − if (eSliceMode != SM_SINGLE_SLICE && eSliceMode != SM_SIZELIMITED_SLICE) //SM_SIZELIMITED_SLICE don't support multi-thread now | |
| 38 | + if (eSliceMode != SM_SINGLE_SLICE | |
| 39 | + && eSliceMode != SM_SIZELIMITED_SLICE) //SM_SIZELIMITED_SLICE don't support multi-thread now | |
| 40 | 40 | param.iMultipleThreadIdc = 2; |
| 41 | 41 | |
| 42 | 42 | for (int i = 0; i < param.iSpatialLayerNum; i++) { |
| @@ -57,9 +57,11 @@ static int InitWithParam (ISVCEncoder* encoder, SEncParamExt* pEncParamExt) { · 14 unmodified lines | ||
| 57 | 57 | param.iMultipleThreadIdc = 4; |
| 58 | 58 | param.bUseLoadBalancing = false; |
| 59 | 59 | } |
| 60 | + if (param.iEntropyCodingModeFlag) { | |
| 61 | + param.sSpatialLayers[i].uiProfileIdc = PRO_MAIN; | |
| 62 | + } | |
| 60 | 63 | } |
| 61 | 64 | param.iTargetBitrate *= param.iSpatialLayerNum; |
| 62 | − | |
| 63 | 65 | return encoder->InitializeExt (¶m); |
| 64 | 66 | } |
| 65 | 67 | } |