1 /* 2 * Copyright (C) 2024 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 #ifndef __HEVC_DEC_TYPE_DEF_H__ /* Macro sentry to avoid redundant including */ 17 #define __HEVC_DEC_TYPE_DEF_H__ 18 19 typedef void *HEVC_DEC_HANDLE; 20 21 typedef signed char INT8; 22 typedef signed int INT32; 23 typedef unsigned char UINT8; 24 typedef unsigned int UINT32; 25 typedef unsigned long long UINT64; 26 27 // Log level 28 typedef enum { 29 IHW265VIDEO_ALG_LOG_ERROR = 0, // log for error 30 IHW265VIDEO_ALG_LOG_WARNING, // log for waring 31 IHW265VIDEO_ALG_LOG_INFO, // log for help 32 IHW265VIDEO_ALG_LOG_DEBUG // print debug info, used for developer debug 33 } IHW265VIDEO_ALG_LOG_LEVEL; 34 35 typedef void (*IHW265D_VIDEO_ALG_LOG_FXN)(UINT32 uiChannelID, IHW265VIDEO_ALG_LOG_LEVEL eLevel, INT8 *pszMsg, ...); 36 37 typedef struct TagHevcDecInitParam { 38 UINT32 uiChannelID; // [in] channel ID, used for channel info 39 IHW265D_VIDEO_ALG_LOG_FXN logFxn; // log output callback function 40 } HEVC_DEC_INIT_PARAM; 41 42 typedef struct TagHevcDecInArgs { 43 UINT8 *pStream; 44 UINT32 uiStreamLen; 45 UINT64 uiTimeStamp; 46 } HEVC_DEC_INARGS; 47 48 typedef struct TagHevcDecOutArgs { 49 UINT32 uiDecWidth; 50 UINT32 uiDecHeight; 51 UINT32 uiDecStride; 52 UINT32 uiDecBitDepth; 53 UINT64 uiTimeStamp; 54 55 UINT8 *pucOutYUV[3]; // YUV address, store YUV in order 56 } HEVC_DEC_OUTARGS; 57 58 #endif // __HEVC_DEC_TYPE_DEF_H__ 59