diff --git a/codec/api/svc/codec_api.h b/codec/api/svc/codec_api.h index 47582dfe..9f8bfd2d 100644 --- a/codec/api/svc/codec_api.h +++ b/codec/api/svc/codec_api.h @@ -94,7 +94,7 @@ class ISVCEncoder { class ISVCDecoder { public: - virtual long EXTAPI Initialize (void* pParam, const INIT_TYPE iInitType) = 0; + virtual long EXTAPI Initialize (void* pParam) = 0; virtual long EXTAPI Uninitialize() = 0; virtual DECODING_STATE EXTAPI DecodeFrame (const unsigned char* pSrc, @@ -162,7 +162,7 @@ struct ISVCEncoderVtbl { typedef struct ISVCDecoderVtbl ISVCDecoderVtbl; typedef const ISVCDecoderVtbl* ISVCDecoder; struct ISVCDecoderVtbl { - long (*Initialize) (ISVCDecoder*, void* pParam, const INIT_TYPE iInitType); + long (*Initialize) (ISVCDecoder*, void* pParam); long (*Uninitialize) (ISVCDecoder*); DECODING_STATE (*DecodeFrame) (ISVCDecoder*, const unsigned char* pSrc, diff --git a/codec/console/dec/src/h264dec.cpp b/codec/console/dec/src/h264dec.cpp index fbcaf546..ccfbd964 100644 --- a/codec/console/dec/src/h264dec.cpp +++ b/codec/console/dec/src/h264dec.cpp @@ -408,7 +408,7 @@ int32_t main (int32_t iArgC, char* pArgV[]) { return 1; } - if (pDecoder->Initialize (&sDecParam, INIT_TYPE_PARAMETER_BASED)) { + if (pDecoder->Initialize (&sDecParam)) { printf ("Decoder initialization failed.\n"); return 1; } diff --git a/codec/decoder/plus/inc/welsDecoderExt.h b/codec/decoder/plus/inc/welsDecoderExt.h index 908d0793..8ffc7c33 100644 --- a/codec/decoder/plus/inc/welsDecoderExt.h +++ b/codec/decoder/plus/inc/welsDecoderExt.h @@ -59,7 +59,7 @@ class CWelsDecoder : public ISVCDecoder { CWelsDecoder (void); virtual ~CWelsDecoder(); -virtual long EXTAPI Initialize (void* pParam, const INIT_TYPE keInitType); +virtual long EXTAPI Initialize (void* pParam); virtual long EXTAPI Uninitialize(); /*************************************************************************** diff --git a/codec/decoder/plus/src/welsDecoderExt.cpp b/codec/decoder/plus/src/welsDecoderExt.cpp index 1f7f015d..e09cd9f1 100644 --- a/codec/decoder/plus/src/welsDecoderExt.cpp +++ b/codec/decoder/plus/src/welsDecoderExt.cpp @@ -186,8 +186,8 @@ CWelsDecoder::~CWelsDecoder() { } } -long CWelsDecoder::Initialize (void* pParam, const INIT_TYPE keInitType) { - if (pParam == NULL || keInitType != INIT_TYPE_PARAMETER_BASED) { +long CWelsDecoder::Initialize (void* pParam) { + if (pParam == NULL) { IWelsTrace::WelsVTrace (m_pTrace, IWelsTrace::WELS_LOG_INFO, "CWelsDecoder::Initialize(), invalid input argument."); return cmInitParaError; } diff --git a/test/BaseDecoderTest.cpp b/test/BaseDecoderTest.cpp index bb2c63ea..b5993e93 100644 --- a/test/BaseDecoderTest.cpp +++ b/test/BaseDecoderTest.cpp @@ -58,7 +58,7 @@ void BaseDecoderTest::SetUp() { decParam.uiEcActiveFlag = 1; decParam.sVideoProperty.eVideoBsType = VIDEO_BITSTREAM_DEFAULT; - rv = decoder_->Initialize(&decParam, INIT_TYPE_PARAMETER_BASED); + rv = decoder_->Initialize(&decParam); ASSERT_EQ(0, rv); } diff --git a/test/cpp_interface_test.cpp b/test/cpp_interface_test.cpp index 22c00b4e..e89dd7b1 100644 --- a/test/cpp_interface_test.cpp +++ b/test/cpp_interface_test.cpp @@ -70,7 +70,7 @@ struct SVCEncoderImpl : public ISVCEncoder { struct SVCDecoderImpl : public ISVCDecoder { virtual ~SVCDecoderImpl() {} - virtual long EXTAPI Initialize(void* pParam, const INIT_TYPE iInitType) { + virtual long EXTAPI Initialize(void* pParam) { EXPECT_TRUE(gThis == this); return 1; }