Showing the changes to codec/encoder/plus/src/welsEncoderExt.cpp (1 of 64 files). Show all
Unified · Split
| @@ -124,8 +124,8 @@ CWelsH264SVCEncoder::CWelsH264SVCEncoder() · 123 unmodified lines | ||
| 124 | 124 | m_pFileBs = WelsFopen (strStreamFileName, "wb"); |
| 125 | 125 | m_pFileBsSize = WelsFopen (strLenFileName, "wb"); |
| 126 | 126 | |
| 127 | − m_bSwitch = false; | |
| 128 | − m_iSwitchTimes = 0; | |
| 127 | + m_bSwitch = false; | |
| 128 | + m_iSwitchTimes = 0; | |
| 129 | 129 | #endif//OUTPUT_BIT_STREAM |
| 130 | 130 | |
| 131 | 131 | InitEncoder(); |
| @@ -149,8 +149,8 @@ CWelsH264SVCEncoder::~CWelsH264SVCEncoder() { · 17 unmodified lines | ||
| 149 | 149 | WelsFclose (m_pFileBsSize); |
| 150 | 150 | m_pFileBsSize = NULL; |
| 151 | 151 | } |
| 152 | − m_bSwitch = false; | |
| 153 | − m_iSwitchTimes = 0; | |
| 152 | + m_bSwitch = false; | |
| 153 | + m_iSwitchTimes = 0; | |
| 154 | 154 | #endif//OUTPUT_BIT_STREAM |
| 155 | 155 | |
| 156 | 156 | Uninitialize(); |
| @@ -323,13 +323,13 @@ int CWelsH264SVCEncoder::InitializeInternal (SWelsSvcCodingParam* pCfg) { · 166 unmodified lines | ||
| 323 | 323 | } |
| 324 | 324 | |
| 325 | 325 | const int32_t kiDecStages = WELS_LOG2 (pCfg->uiGopSize); |
| 326 | − pCfg->iTemporalLayerNum = (int8_t) (1 + kiDecStages); | |
| 327 | − pCfg->iLoopFilterAlphaC0Offset = WELS_CLIP3 (pCfg->iLoopFilterAlphaC0Offset, -6, 6); | |
| 328 | − pCfg->iLoopFilterBetaOffset = WELS_CLIP3 (pCfg->iLoopFilterBetaOffset, -6, 6); | |
| 326 | + pCfg->iTemporalLayerNum = (int8_t) (1 + kiDecStages); | |
| 327 | + pCfg->iLoopFilterAlphaC0Offset = WELS_CLIP3 (pCfg->iLoopFilterAlphaC0Offset, -6, 6); | |
| 328 | + pCfg->iLoopFilterBetaOffset = WELS_CLIP3 (pCfg->iLoopFilterBetaOffset, -6, 6); | |
| 329 | 329 | |
| 330 | 330 | // decide property list size between INIT_TYPE_PARAMETER_BASED/INIT_TYPE_CONFIG_BASED |
| 331 | − m_iMaxPicWidth = pCfg->iPicWidth; | |
| 332 | − m_iMaxPicHeight = pCfg->iPicHeight; | |
| 331 | + m_iMaxPicWidth = pCfg->iPicWidth; | |
| 332 | + m_iMaxPicHeight = pCfg->iPicHeight; | |
| 333 | 333 | |
| 334 | 334 | TraceParamInfo (pCfg); |
| 335 | 335 | if (WelsInitEncoderExt (&m_pEncContext, pCfg, &m_pWelsTrace->m_sLogCtx, NULL)) { |
| @@ -683,9 +683,9 @@ int CWelsH264SVCEncoder::SetOption (ENCODER_OPTION eOptionId, void* pOption) { · 347 unmodified lines | ||
| 683 | 683 | m_pEncContext->pSvcParam->uiIntraPeriod = (uint32_t)iValue; |
| 684 | 684 | } |
| 685 | 685 | break; |
| 686 | − case ENCODER_OPTION_SVC_ENCODE_PARAM_BASE: { // SVC Encoding Parameter | |
| 687 | − SEncParamBase sEncodingParam; | |
| 688 | − SWelsSvcCodingParam sConfig; | |
| 686 | + case ENCODER_OPTION_SVC_ENCODE_PARAM_BASE: { // SVC Encoding Parameter | |
| 687 | + SEncParamBase sEncodingParam; | |
| 688 | + SWelsSvcCodingParam sConfig; | |
| 689 | 689 | int32_t iTargetWidth = 0; |
| 690 | 690 | int32_t iTargetHeight = 0; |
| 691 | 691 | |
| @@ -694,12 +694,12 @@ int CWelsH264SVCEncoder::SetOption (ENCODER_OPTION eOptionId, void* pOption) { · 2 unmodified lines | ||
| 694 | 694 | return cmInitParaError; |
| 695 | 695 | } |
| 696 | 696 | /* New configuration available here */ |
| 697 | − iTargetWidth = sConfig.iPicWidth; | |
| 698 | − iTargetHeight = sConfig.iPicHeight; | |
| 697 | + iTargetWidth = sConfig.iPicWidth; | |
| 698 | + iTargetHeight = sConfig.iPicHeight; | |
| 699 | 699 | if (m_iMaxPicWidth != iTargetWidth |
| 700 | 700 | || m_iMaxPicHeight != iTargetHeight) { |
| 701 | − m_iMaxPicWidth = iTargetWidth; | |
| 702 | − m_iMaxPicHeight = iTargetHeight; | |
| 701 | + m_iMaxPicWidth = iTargetWidth; | |
| 702 | + m_iMaxPicHeight = iTargetHeight; | |
| 703 | 703 | } |
| 704 | 704 | WelsLog (&m_pWelsTrace->m_sLogCtx, WELS_LOG_INFO, |
| 705 | 705 | "CWelsH264SVCEncoder::SetOption():ENCODER_OPTION_SVC_ENCODE_PARAM_BASE iUsageType = %d,iPicWidth= %d;iPicHeight= %d;iTargetBitrate= %d;fMaxFrameRate= %.6ff;iRCMode= %d", |
| @@ -715,9 +715,9 @@ int CWelsH264SVCEncoder::SetOption (ENCODER_OPTION eOptionId, void* pOption) { · 9 unmodified lines | ||
| 715 | 715 | } |
| 716 | 716 | break; |
| 717 | 717 | |
| 718 | − case ENCODER_OPTION_SVC_ENCODE_PARAM_EXT: { // SVC Encoding Parameter | |
| 719 | − SEncParamExt sEncodingParam; | |
| 720 | − SWelsSvcCodingParam sConfig; | |
| 718 | + case ENCODER_OPTION_SVC_ENCODE_PARAM_EXT: { // SVC Encoding Parameter | |
| 719 | + SEncParamExt sEncodingParam; | |
| 720 | + SWelsSvcCodingParam sConfig; | |
| 721 | 721 | int32_t iTargetWidth = 0; |
| 722 | 722 | int32_t iTargetHeight = 0; |
| 723 | 723 | |
| @@ -756,12 +756,12 @@ int CWelsH264SVCEncoder::SetOption (ENCODER_OPTION eOptionId, void* pOption) { · 32 unmodified lines | ||
| 756 | 756 | } |
| 757 | 757 | |
| 758 | 758 | /* New configuration available here */ |
| 759 | − iTargetWidth = sConfig.iPicWidth; | |
| 760 | − iTargetHeight = sConfig.iPicHeight; | |
| 759 | + iTargetWidth = sConfig.iPicWidth; | |
| 760 | + iTargetHeight = sConfig.iPicHeight; | |
| 761 | 761 | if (m_iMaxPicWidth != iTargetWidth |
| 762 | 762 | || m_iMaxPicHeight != iTargetHeight) { |
| 763 | − m_iMaxPicWidth = iTargetWidth; | |
| 764 | − m_iMaxPicHeight = iTargetHeight; | |
| 763 | + m_iMaxPicWidth = iTargetWidth; | |
| 764 | + m_iMaxPicHeight = iTargetHeight; | |
| 765 | 765 | } |
| 766 | 766 | /* Check every field whether there is new request for memory block changed or else, Oct. 24, 2008 */ |
| 767 | 767 | if (WelsEncoderParamAdjust (&m_pEncContext, &sConfig)) { |