There's really no reason for adding a typedef for void.
Showing the changes to codec/decoder/plus/src/welsDecoderExt.cpp (1 of 55 files). Show all
Unified · Split
| @@ -83,7 +83,7 @@ namespace WelsDec { · 82 unmodified lines | |||
| 83 | * | 83 | * |
| 84 | * return: none | 84 | * return: none |
| 85 | ***************************************************************************/ | 85 | ***************************************************************************/ |
| 86 | CWelsDecoder::CWelsDecoder (void_t) | 86 | CWelsDecoder::CWelsDecoder (void) |
| 87 | : m_pDecContext (NULL), | 87 | : m_pDecContext (NULL), |
| 88 | m_pTrace (NULL) { | 88 | m_pTrace (NULL) { |
| 89 | #ifdef OUTPUT_BIT_STREAM | 89 | #ifdef OUTPUT_BIT_STREAM |
| @@ -108,8 +108,8 @@ CWelsDecoder::CWelsDecoder (void_t) · 18 unmodified lines | |||
| 108 | 108 | ||
| 109 | WelsGetTimeOfDay (&sCurTime); | 109 | WelsGetTimeOfDay (&sCurTime); |
| 110 | 110 | ||
| 111 | iCurUsed = WelsSnprintf (chFileName, iBufLeft, "bs_0x%p_", (void_t*)this); | 111 | iCurUsed = WelsSnprintf (chFileName, iBufLeft, "bs_0x%p_", (void*)this); |
| 112 | iCurUsedSize = WelsSnprintf (chFileNameSize, iBufLeftSize, "size_0x%p_", (void_t*)this); | 112 | iCurUsedSize = WelsSnprintf (chFileNameSize, iBufLeftSize, "size_0x%p_", (void*)this); |
| 113 | 113 | ||
| 114 | if (iCurUsed > 0) { | 114 | if (iCurUsed > 0) { |
| 115 | iBufUsed += iCurUsed; | 115 | iBufUsed += iCurUsed; |
| @@ -186,7 +186,7 @@ CWelsDecoder::~CWelsDecoder() { · 70 unmodified lines | |||
| 186 | } | 186 | } |
| 187 | } | 187 | } |
| 188 | 188 | ||
| 189 | long CWelsDecoder::Initialize (void_t* pParam, const INIT_TYPE keInitType) { | 189 | long CWelsDecoder::Initialize (void* pParam, const INIT_TYPE keInitType) { |
| 190 | if (pParam == NULL || keInitType != INIT_TYPE_PARAMETER_BASED) { | 190 | if (pParam == NULL || keInitType != INIT_TYPE_PARAMETER_BASED) { |
| 191 | IWelsTrace::WelsVTrace (m_pTrace, IWelsTrace::WELS_LOG_INFO, "CWelsDecoder::Initialize(), invalid input argument."); | 191 | IWelsTrace::WelsVTrace (m_pTrace, IWelsTrace::WELS_LOG_INFO, "CWelsDecoder::Initialize(), invalid input argument."); |
| 192 | return cmInitParaError; | 192 | return cmInitParaError; |
| @@ -206,7 +206,7 @@ long CWelsDecoder::Uninitialize() { · 13 unmodified lines | |||
| 206 | return ERR_NONE; | 206 | return ERR_NONE; |
| 207 | } | 207 | } |
| 208 | 208 | ||
| 209 | void_t CWelsDecoder::UninitDecoder (void_t) { | 209 | void CWelsDecoder::UninitDecoder (void) { |
| 210 | if (NULL == m_pDecContext) | 210 | if (NULL == m_pDecContext) |
| 211 | return; | 211 | return; |
| 212 | 212 | ||
| @@ -224,7 +224,7 @@ void_t CWelsDecoder::UninitDecoder (void_t) { · 11 unmodified lines | |||
| 224 | } | 224 | } |
| 225 | 225 | ||
| 226 | // the return value of this function is not suitable, it need report failure info to upper layer. | 226 | // the return value of this function is not suitable, it need report failure info to upper layer. |
| 227 | void_t CWelsDecoder::InitDecoder (void_t) { | 227 | void CWelsDecoder::InitDecoder (void) { |
| 228 | IWelsTrace::WelsVTrace (m_pTrace, IWelsTrace::WELS_LOG_INFO, "CWelsDecoder::init_decoder().."); | 228 | IWelsTrace::WelsVTrace (m_pTrace, IWelsTrace::WELS_LOG_INFO, "CWelsDecoder::init_decoder().."); |
| 229 | 229 | ||
| 230 | m_pDecContext = (PWelsDecoderContext)WelsMalloc (sizeof (SWelsDecoderContext), "m_pDecContext"); | 230 | m_pDecContext = (PWelsDecoderContext)WelsMalloc (sizeof (SWelsDecoderContext), "m_pDecContext"); |
| @@ -237,7 +237,7 @@ void_t CWelsDecoder::InitDecoder (void_t) { · 6 unmodified lines | |||
| 237 | /* | 237 | /* |
| 238 | * Set Option | 238 | * Set Option |
| 239 | */ | 239 | */ |
| 240 | long CWelsDecoder::SetOption (DECODER_OPTION eOptID, void_t* pOption) { | 240 | long CWelsDecoder::SetOption (DECODER_OPTION eOptID, void* pOption) { |
| 241 | int iVal = 0; | 241 | int iVal = 0; |
| 242 | 242 | ||
| 243 | if (m_pDecContext == NULL) | 243 | if (m_pDecContext == NULL) |
| @@ -294,7 +294,7 @@ long CWelsDecoder::SetOption (DECODER_OPTION eOptID, void_t* pOption) { · 50 unmodified lines | |||
| 294 | /* | 294 | /* |
| 295 | * Get Option | 295 | * Get Option |
| 296 | */ | 296 | */ |
| 297 | long CWelsDecoder::GetOption (DECODER_OPTION eOptID, void_t* pOption) { | 297 | long CWelsDecoder::GetOption (DECODER_OPTION eOptID, void* pOption) { |
| 298 | int iVal = 0; | 298 | int iVal = 0; |
| 299 | 299 | ||
| 300 | if (m_pDecContext == NULL) | 300 | if (m_pDecContext == NULL) |
| @@ -359,7 +359,7 @@ long CWelsDecoder::GetOption (DECODER_OPTION eOptID, void_t* pOption) { · 58 unmodified lines | |||
| 359 | 359 | ||
| 360 | DECODING_STATE CWelsDecoder::DecodeFrame2 (const unsigned char* kpSrc, | 360 | DECODING_STATE CWelsDecoder::DecodeFrame2 (const unsigned char* kpSrc, |
| 361 | const int kiSrcLen, | 361 | const int kiSrcLen, |
| 362 | void_t** ppDst, | 362 | void** ppDst, |
| 363 | SBufferInfo* pDstInfo) { | 363 | SBufferInfo* pDstInfo) { |
| 364 | if (kiSrcLen > MAX_ACCESS_UNIT_CAPACITY) { | 364 | if (kiSrcLen > MAX_ACCESS_UNIT_CAPACITY) { |
| 365 | m_pDecContext->iErrorCode |= dsOutOfMemory; | 365 | m_pDecContext->iErrorCode |= dsOutOfMemory; |
| @@ -449,7 +449,7 @@ DECODING_STATE CWelsDecoder::DecodeFrame (const unsigned char* kpSrc, · 83 unmodified lines | |||
| 449 | DstInfo.UsrData.sSystemBuffer.iHeight = iHeight; | 449 | DstInfo.UsrData.sSystemBuffer.iHeight = iHeight; |
| 450 | DstInfo.eBufferProperty = BUFFER_HOST; | 450 | DstInfo.eBufferProperty = BUFFER_HOST; |
| 451 | 451 | ||
| 452 | eDecState = DecodeFrame2 (kpSrc, kiSrcLen, (void_t**)ppDst, &DstInfo); | 452 | eDecState = DecodeFrame2 (kpSrc, kiSrcLen, (void**)ppDst, &DstInfo); |
| 453 | if (eDecState == dsErrorFree) { | 453 | if (eDecState == dsErrorFree) { |
| 454 | pStride[0] = DstInfo.UsrData.sSystemBuffer.iStride[0]; | 454 | pStride[0] = DstInfo.UsrData.sSystemBuffer.iStride[0]; |
| 455 | pStride[1] = DstInfo.UsrData.sSystemBuffer.iStride[1]; | 455 | pStride[1] = DstInfo.UsrData.sSystemBuffer.iStride[1]; |
| @@ -503,7 +503,7 @@ long CreateDecoder (ISVCDecoder** ppDecoder) { · 47 unmodified lines | |||
| 503 | /* | 503 | /* |
| 504 | * DestroyDecoder | 504 | * DestroyDecoder |
| 505 | */ | 505 | */ |
| 506 | void_t DestroyDecoder (ISVCDecoder* pDecoder) { | 506 | void DestroyDecoder (ISVCDecoder* pDecoder) { |
| 507 | if (NULL != pDecoder) { | 507 | if (NULL != pDecoder) { |
| 508 | delete (CWelsDecoder*)pDecoder; | 508 | delete (CWelsDecoder*)pDecoder; |
| 509 | } | 509 | } |