H.264 Codec for ESP32-S3
Loading...
Searching...
No Matches
Classes | Macros | Typedefs | Enumerations
codec_def.h File Reference
#include <stdint.h>
Include dependency graph for codec_def.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  SliceInformation
 Information of coded Slice(=NAL)(s) More...
 
struct  SRateThresholds
 thresholds of the initial, maximal and minimal rate More...
 
struct  TagSysMemBuffer
 Structure for decoder memery. More...
 
struct  TagBufferInfo
 Buffer info. More...
 

Macros

#define IS_PARAMETER_SET_NAL(eNalRefIdc, eNalType)   ( (eNalRefIdc == NAL_PRIORITY_HIGHEST) && (eNalType == (NAL_SPS|NAL_PPS) || eNalType == NAL_SPS) )
 
#define IS_IDR_NAL(eNalRefIdc, eNalType)   ( (eNalRefIdc == NAL_PRIORITY_HIGHEST) && (eNalType == NAL_SLICE_IDR) )
 
#define FRAME_NUM_PARAM_SET   (-1)
 
#define FRAME_NUM_IDR   0
 
#define DEBLOCKING_OFFSET   (6)
 
#define DEBLOCKING_OFFSET_MINUS   (-6)
 

Typedefs

typedef unsigned short ERR_TOOL
 
typedef struct SliceInformation SliceInfo
 Information of coded Slice(=NAL)(s)
 
typedef struct SliceInformationPSliceInfo
 
typedef struct SRateThresholdsPRateThresholds
 
typedef struct TagSysMemBuffer SSysMEMBuffer
 Structure for decoder memery.
 
typedef struct TagBufferInfo SBufferInfo
 Buffer info.
 

Enumerations

enum  EVideoFormatType {
  videoFormatRGB = 1 , videoFormatRGBA = 2 , videoFormatRGB555 = 3 , videoFormatRGB565 = 4 ,
  videoFormatBGR = 5 , videoFormatBGRA = 6 , videoFormatABGR = 7 , videoFormatARGB = 8 ,
  videoFormatYUY2 = 20 , videoFormatYVYU = 21 , videoFormatUYVY = 22 , videoFormatI420 = 23 ,
  videoFormatYV12 = 24 , videoFormatInternal = 25 , videoFormatNV12 = 26 , videoFormatVFlip = 0x80000000
}
 Enumerate the type of video format. More...
 
enum  EVideoFrameType {
  videoFrameTypeInvalid = -1 , videoFrameTypeIDR = 0 , videoFrameTypeI = 1 , videoFrameTypeP = 2 ,
  videoFrameTypeSKIP = 3 , videoFrameTypeIPMixed = 4
}
 Enumerate video frame type. More...
 
enum  CM_RETURN {
  cmResultSuccess , cmInitParaError , cmUnknownReason , cmMallocMemeError ,
  cmInitExpected , cmUnsupportedData
}
 Enumerate return type. More...
 
enum  ENalUnitType {
  NAL_UNKNOWN = 0 , NAL_SLICE = 1 , NAL_SLICE_DPA = 2 , NAL_SLICE_DPB = 3 ,
  NAL_SLICE_DPC = 4 , NAL_SLICE_IDR = 5 , NAL_SEI = 6 , NAL_SPS = 7 ,
  NAL_PPS = 8
}
 Enumulate the nal unit type. More...
 
enum  ENalPriority { NAL_PRIORITY_DISPOSABLE = 0 , NAL_PRIORITY_LOW = 1 , NAL_PRIORITY_HIGH = 2 , NAL_PRIORITY_HIGHEST = 3 }
 NRI: eNalRefIdc. More...
 
enum  { DEBLOCKING_IDC_0 = 0 , DEBLOCKING_IDC_1 = 1 , DEBLOCKING_IDC_2 = 2 }
 eDeblockingIdc More...
 
enum  {
  ET_NONE = 0x00 , ET_IP_SCALE = 0x01 , ET_FMO = 0x02 , ET_IR_R1 = 0x04 ,
  ET_IR_R2 = 0x08 , ET_IR_R3 = 0x10 , ET_FEC_HALF = 0x20 , ET_FEC_FULL = 0x40 ,
  ET_RFS = 0x80
}
 to do More...
 

Detailed Description

\copy Copyright (c) 2013, Cisco Systems All rights reserved.

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Macro Definition Documentation

◆ DEBLOCKING_OFFSET

#define DEBLOCKING_OFFSET   (6)

◆ DEBLOCKING_OFFSET_MINUS

#define DEBLOCKING_OFFSET_MINUS   (-6)

◆ FRAME_NUM_IDR

#define FRAME_NUM_IDR   0

◆ FRAME_NUM_PARAM_SET

#define FRAME_NUM_PARAM_SET   (-1)

◆ IS_IDR_NAL

#define IS_IDR_NAL (   eNalRefIdc,
  eNalType 
)    ( (eNalRefIdc == NAL_PRIORITY_HIGHEST) && (eNalType == NAL_SLICE_IDR) )

◆ IS_PARAMETER_SET_NAL

#define IS_PARAMETER_SET_NAL (   eNalRefIdc,
  eNalType 
)    ( (eNalRefIdc == NAL_PRIORITY_HIGHEST) && (eNalType == (NAL_SPS|NAL_PPS) || eNalType == NAL_SPS) )

Typedef Documentation

◆ ERR_TOOL

typedef unsigned short ERR_TOOL

◆ PRateThresholds

typedef struct SRateThresholds * PRateThresholds

◆ PSliceInfo

typedef struct SliceInformation * PSliceInfo

◆ SBufferInfo

typedef struct TagBufferInfo SBufferInfo

Buffer info.

◆ SliceInfo

typedef struct SliceInformation SliceInfo

Information of coded Slice(=NAL)(s)

◆ SSysMEMBuffer

Structure for decoder memery.

Enumeration Type Documentation

◆ anonymous enum

anonymous enum

eDeblockingIdc

Enumerator
DEBLOCKING_IDC_0 
DEBLOCKING_IDC_1 
DEBLOCKING_IDC_2 

◆ anonymous enum

anonymous enum

to do

Enumerator
ET_NONE 

NONE Error Tools.

ET_IP_SCALE 

IP Scalable.

ET_FMO 

Flexible Macroblock Ordering.

ET_IR_R1 

Intra Refresh in predifined 2% MB.

ET_IR_R2 

Intra Refresh in predifined 5% MB.

ET_IR_R3 

Intra Refresh in predifined 10% MB.

ET_FEC_HALF 

Forward Error Correction in 50% redundency mode.

ET_FEC_FULL 

Forward Error Correction in 100% redundency mode.

ET_RFS 

Reference Frame Selection.

◆ CM_RETURN

enum CM_RETURN

Enumerate return type.

Enumerator
cmResultSuccess 

successful

cmInitParaError 

parameters are invalid

cmUnknownReason 
cmMallocMemeError 

malloc a memory error

cmInitExpected 

initial action is expected

cmUnsupportedData 

◆ ENalPriority

NRI: eNalRefIdc.

Enumerator
NAL_PRIORITY_DISPOSABLE 
NAL_PRIORITY_LOW 
NAL_PRIORITY_HIGH 
NAL_PRIORITY_HIGHEST 

◆ ENalUnitType

Enumulate the nal unit type.

Enumerator
NAL_UNKNOWN 
NAL_SLICE 
NAL_SLICE_DPA 
NAL_SLICE_DPB 
NAL_SLICE_DPC 
NAL_SLICE_IDR 

ref_idc != 0

NAL_SEI 

ref_idc == 0

NAL_SPS 
NAL_PPS 

ref_idc == 0 for 6,9,10,11,12

◆ EVideoFormatType

Enumerate the type of video format.

Enumerator
videoFormatRGB 

rgb color formats

videoFormatRGBA 
videoFormatRGB555 
videoFormatRGB565 
videoFormatBGR 
videoFormatBGRA 
videoFormatABGR 
videoFormatARGB 
videoFormatYUY2 

yuv color formats

videoFormatYVYU 
videoFormatUYVY 
videoFormatI420 

the same as IYUV

videoFormatYV12 
videoFormatInternal 

only used in SVC decoder testbed

videoFormatNV12 

new format for output by DXVA decoding

videoFormatVFlip 

◆ EVideoFrameType

Enumerate video frame type.

Enumerator
videoFrameTypeInvalid 

encoder not ready or parameters are invalidate

videoFrameTypeIDR 

IDR frame in H.264.

videoFrameTypeI 

I frame type.

videoFrameTypeP 

P frame type.

videoFrameTypeSKIP 

skip the frame based encoder kernel

videoFrameTypeIPMixed 

a frame where I and P slices are mixing, not supported yet