History

Use void instead of void_t

There's really no reason for adding a typedef for void.

Martin Storsjö committed 12 years ago

Commit 7b96c671 parent 2b77fe755 files · +400 −404Browse files

Showing the changes to codec/decoder/core/src/decoder.cpp (1 of 55 files). Show all

Unified · Split

codec/decoder/core/src/decoder.cpp+12−12
@@ -57,9 +57,9 @@ namespace WelsDec { · 56 unmodified lines
57 57
58extern PPicture AllocPicture (PWelsDecoderContext pCtx, const int32_t kiPicWidth, const int32_t kiPicHeight);58extern PPicture AllocPicture (PWelsDecoderContext pCtx, const int32_t kiPicWidth, const int32_t kiPicHeight);
59 59
60extern void_t FreePicture (PPicture pPic);60extern void FreePicture (PPicture pPic);
61 61
62inline void_t GetValueOf4Bytes (uint8_t* pDstNal, int32_t iDdstIdx) {62inline void GetValueOf4Bytes (uint8_t* pDstNal, int32_t iDdstIdx) {
63 ST32(pDstNal, iDdstIdx);63 ST32(pDstNal, iDdstIdx);
64}64}
65 65
@@ -98,7 +98,7 @@ static int32_t CreatePicBuff (PWelsDecoderContext pCtx, PPicBuff* ppPicBuf, cons · 32 unmodified lines
98 return 0;98 return 0;
99}99}
100 100
101static void_t DestroyPicBuff (PPicBuff* ppPicBuf) {101static void DestroyPicBuff (PPicBuff* ppPicBuf) {
102 PPicBuff pPicBuf = NULL;102 PPicBuff pPicBuf = NULL;
103 103
104 if (NULL == ppPicBuf || NULL == *ppPicBuf)104 if (NULL == ppPicBuf || NULL == *ppPicBuf)
@@ -131,7 +131,7 @@ static void_t DestroyPicBuff (PPicBuff* ppPicBuf) { · 26 unmodified lines
131/*131/*
132 * fill data fields in default for decoder context132 * fill data fields in default for decoder context
133 */133 */
134void_t WelsDecoderDefaults (PWelsDecoderContext pCtx) {134void WelsDecoderDefaults (PWelsDecoderContext pCtx) {
135 int32_t iCpuCores = 1;135 int32_t iCpuCores = 1;
136 memset (pCtx, 0, sizeof (SWelsDecoderContext)); // fill zero first136 memset (pCtx, 0, sizeof (SWelsDecoderContext)); // fill zero first
137 137
@@ -282,7 +282,7 @@ int32_t WelsRequestMem (PWelsDecoderContext pCtx, const int32_t kiMbWidth, const · 144 unmodified lines
282/*282/*
283 * free memory blocks in avc283 * free memory blocks in avc
284 */284 */
285void_t WelsFreeMem (PWelsDecoderContext pCtx) {285void WelsFreeMem (PWelsDecoderContext pCtx) {
286 int32_t iListIdx = 0;286 int32_t iListIdx = 0;
287 287
288 /* TODO: free memory blocks introduced in avc */288 /* TODO: free memory blocks introduced in avc */
@@ -308,7 +308,7 @@ void_t WelsFreeMem (PWelsDecoderContext pCtx) { · 19 unmodified lines
308/*!308/*!
309 * \brief Open decoder309 * \brief Open decoder
310 */310 */
311void_t WelsOpenDecoder (PWelsDecoderContext pCtx) {311void WelsOpenDecoder (PWelsDecoderContext pCtx) {
312 // function pointers312 // function pointers
313 //initial MC function pointer--313 //initial MC function pointer--
314 InitMcFunc (& (pCtx->sMcFunc), pCtx->uiCpuFlag);314 InitMcFunc (& (pCtx->sMcFunc), pCtx->uiCpuFlag);
@@ -333,7 +333,7 @@ void_t WelsOpenDecoder (PWelsDecoderContext pCtx) { · 18 unmodified lines
333/*!333/*!
334 * \brief Close decoder334 * \brief Close decoder
335 */335 */
336void_t WelsCloseDecoder (PWelsDecoderContext pCtx) {336void WelsCloseDecoder (PWelsDecoderContext pCtx) {
337 WelsFreeMem (pCtx);337 WelsFreeMem (pCtx);
338 338
339 WelsFreeMemory (pCtx);339 WelsFreeMemory (pCtx);
@@ -350,7 +350,7 @@ void_t WelsCloseDecoder (PWelsDecoderContext pCtx) { · 10 unmodified lines
350/*!350/*!
351 * \brief configure decoder parameters351 * \brief configure decoder parameters
352 */352 */
353int32_t DecoderConfigParam (PWelsDecoderContext pCtx, const void_t* kpParam) {353int32_t DecoderConfigParam (PWelsDecoderContext pCtx, const void* kpParam) {
354 if (NULL == pCtx || NULL == kpParam)354 if (NULL == pCtx || NULL == kpParam)
355 return 1;355 return 1;
356 356
@@ -387,7 +387,7 @@ int32_t DecoderConfigParam (PWelsDecoderContext pCtx, const void_t* kpParam) { · 30 unmodified lines
387 * \note N/A387 * \note N/A
388 *************************************************************************************388 *************************************************************************************
389 */389 */
390int32_t WelsInitDecoder (PWelsDecoderContext pCtx, void_t* pTraceHandle, PWelsLogCallbackFunc pLog) {390int32_t WelsInitDecoder (PWelsDecoderContext pCtx, void* pTraceHandle, PWelsLogCallbackFunc pLog) {
391 if (pCtx == NULL) {391 if (pCtx == NULL) {
392 return ERR_INFO_INVALID_PTR;392 return ERR_INFO_INVALID_PTR;
393 }393 }
@@ -423,12 +423,12 @@ int32_t WelsInitDecoder (PWelsDecoderContext pCtx, void_t* pTraceHandle, PWelsLo · 29 unmodified lines
423 * \note N/A423 * \note N/A
424 *************************************************************************************424 *************************************************************************************
425 */425 */
426void_t WelsEndDecoder (PWelsDecoderContext pCtx) {426void WelsEndDecoder (PWelsDecoderContext pCtx) {
427 // close decoder427 // close decoder
428 WelsCloseDecoder (pCtx);428 WelsCloseDecoder (pCtx);
429}429}
430 430
431void_t GetVclNalTemporalId (PWelsDecoderContext pCtx) {431void GetVclNalTemporalId (PWelsDecoderContext pCtx) {
432 PAccessUnit pAccessUnit = pCtx->pAccessUnitList;432 PAccessUnit pAccessUnit = pCtx->pAccessUnitList;
433 int32_t idx = pAccessUnit->uiStartPos;433 int32_t idx = pAccessUnit->uiStartPos;
434 434
@@ -661,7 +661,7 @@ int32_t SyncPictureResolutionExt (PWelsDecoderContext pCtx, const int32_t kiMbWi · 226 unmodified lines
661 return iErr;661 return iErr;
662}662}
663 663
664void_t AssignFuncPointerForRec (PWelsDecoderContext pCtx) {664void AssignFuncPointerForRec (PWelsDecoderContext pCtx) {
665 pCtx->pGetI16x16LumaPredFunc[I16_PRED_V ] = WelsI16x16LumaPredV_c;665 pCtx->pGetI16x16LumaPredFunc[I16_PRED_V ] = WelsI16x16LumaPredV_c;
666 pCtx->pGetI16x16LumaPredFunc[I16_PRED_H ] = WelsI16x16LumaPredH_c;666 pCtx->pGetI16x16LumaPredFunc[I16_PRED_H ] = WelsI16x16LumaPredH_c;
667 pCtx->pGetI16x16LumaPredFunc[I16_PRED_DC ] = WelsI16x16LumaPredDc_c;667 pCtx->pGetI16x16LumaPredFunc[I16_PRED_DC ] = WelsI16x16LumaPredDc_c;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t