1 Star 0 Fork 4.9K

famoustang / docs

forked from OpenHarmony / docs 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
codec_type-h.md 38.33 KB
一键复制 编辑 原始数据 按行查看 历史
wenjun 提交于 2020-09-08 10:08 . add OpenHarmony 1.0 baseline

codec_type.h

Overview

Related Modules:

Codec

Description:

Declares custom data types used in API declarations for the Codec module, including the codec types, audio and video parameters, input and output data, and callbacks.

Since:

1.0

Version:

1.0

Summary

Data Structures

Data Structure Name

Description

Param

Describes the dynamic parameter structure, which is mainly used by CodecCreate and CodecSetParameter.

BufferHandle

Defines the buffer handle type. The virtual address of a handle maps to its physical address.

CodecBufferInfo

Describes buffer information.

InputInfo

Describes input information.

OutputInfo

Describes output information.

ResizableArray

Defines a variable-length queue.

Alginment

Defines the alignment.

Rect

Defines a rectangle.

Capbility

Defines the codec capability.

CodecCallback

Defines callbacks and their parameters.

Macros

Macro Name and Value

Description

ELEMENT_MAX_LEN 50

Indicates the maximum number of reserved parameters in the array.

Typedefs

Typedef Name

Description

CODEC_HANDLETYPE

typedef void *

Defines the pointer to the codec handle, which is the context information for function calls.

ValueType

typedef void *

Defines the pointer to the type of the dynamic parameter value.

BufferHandle

typedef struct BufferHandle

Defines the buffer handle type. The virtual address of a handle maps to its physical address.

BufferType

typedef enum BufferType

Enumerates buffer types.

OutputInfo

typedef struct OutputInfo

Describes output information.

AllocateBufferMode

typedef enum AllocateBufferMode

Enumerates allocation modes of input and output buffers.

CapsMask

typedef enum CapsMask

Enumerates playback capabilities.

CodecCapbility

typedef struct Capbility

Defines the codec capability.

UINTPTR

typedef uintptr_t

Redefines the unsigned pointer type, which is used for pointer conversion.

Enumerations

Enumeration Name

Description

CodecType { VIDEO_DECODER, VIDEO_ENCODER, AUDIO_DECODER, AUDIO_ENCODER, INVALID_TYPE }

Enumerates codec types.

ParamKey { KEY_MIMETYPE = 0x01, KEY_BUFFERSIZE, KEY_LEFT_STREAM_FRAMES, KEY_CODEC_TYPE, KEY_DIRECTION_TYPE, KEY_BITRATE = 0x500, KEY_WIDTH = 0x1000, KEY_HEIGHT, KEY_STRIDE, KEY_VIDEO_FIELD, KEY_PIXEL_FORMAT, KEY_VIDEO_RC_MODE, KEY_VIDEO_GOP_MODE, KEY_VIDEO_PIC_SIZE, KEY_VIDEO_PROFILE, KEY_VIDEO_FRAME_RATE, KEY_SAMPLE_RATE = 0x1500, KEY_AUDIO_PROFILE, KEY_CHANNEL_COUNT, KEY_BITWITH, KEY_SOUND_MODE, KEY_POINT_NUM_PER_FRAME, KEY_DEVICE_ID }

Enumerates indexes of parameter types.

VenCodeRcMode { VENCOD_RC_CBR = 0, VENCOD_RC_VBR, VENCOD_RC_AVBR, VENCOD_RC_QVBR, VENCOD_RC_CVBR, VENCOD_RC_QPMAP, VENCOD_RC_FIXQP }

Enumerates control modes of the channel encoding rate.

PicSize { Resolution_CIF, Resolution_360P, Resolution_D1_PAL, Resolution_D1_NTSC, Resolution_720P, Resolution_1080P, Resolution_INVALID }

Enumerates resolutions.

VenCodeGopMode { VENCOD_GOPMODE_NORMALP = 0, VENCOD_GOPMODE_DUALP = 1, VENCOD_GOPMODE_SMARTP = 2, VENCOD_GOPMODE_ADVSMARTP = 3, VENCOD_GOPMODE_BIPREDB = 4, VENCOD_GOPMODE_LOWDELAYB = 5, VENCOD_GOPMODE_INVALID }

Enumerates types of group of pictures (GOP).

VideoField { VID_FIELD_TOP = 0x1, VID_FIELD_BOTTOM = 0x2, VID_FIELD_INTERLACED = 0x3, VID_FIELD_FRAME = 0x4, VID_FIELD_INVALID }

Enumerates video frame fields.

PixelFormat { YVU_SEMIPLANAR_420 = 0, YVU_SEMIPLANAR_420_TILE, PIX_FORMAT_INVALID }

Enumerates pixel formats.

AudioSoundMode { AUD_SOUND_MODE_MONO = 0, AUD_SOUND_MODE_STEREO = 1, AUD_SOUND_MODE_INVALID }

Enumerates audio channel modes.

AudioSampleRate { AUD_SAMPLE_RATE_8000 = 8000, AUD_SAMPLE_RATE_12000 = 12000, AUD_SAMPLE_RATE_11025 = 11025, AUD_SAMPLE_RATE_16000 = 16000, AUD_SAMPLE_RATE_22050 = 22050, AUD_SAMPLE_RATE_24000 = 24000, AUD_SAMPLE_RATE_32000 = 32000, AUD_SAMPLE_RATE_44100 = 44100, AUD_SAMPLE_RATE_48000 = 48000, AUD_SAMPLE_RATE_64000 = 64000, AUD_SAMPLE_RATE_96000 = 96000, AUD_SAMPLE_RATE_INVALID }

Enumerates audio sampling rates.

AudioBitRate { AUD_AAC_BPS_8K = 8000, AUD_AAC_BPS_16K = 16000, AUD_AAC_BPS_22K = 22000, AUD_AAC_BPS_24K = 24000, AUD_AAC_BPS_32K = 32000, AUD_AAC_BPS_48K = 48000, AUD_AAC_BPS_64K = 64000, AUD_AAC_BPS_96K = 96000, AUD_AAC_BPS_128K = 128000, AUD_AAC_BPS_256K = 256000, AUD_AAC_BPS_320K = 320000 }

Enumerates audio bit rates.

StreamFlagType { STREAM_FLAG_KEYFRAME = 1, STREAM_FLAG_CODEC_SPECIFIC_INF = 2, STREAM_FLAG_EOS = 4, STREAM_FLAG_PART_OF_FRAME = 8, STREAM_FLAG_END_OF_FRAME = 16 }

Enumerates stream flags.

BufferType { BUFFER_TYPE_VIRTUAL = 0, BUFFER_TYPE_FD, BUFFER_TYPE_HANDLE }

Enumerates buffer types.

AvCodecMime { MEDIA_MIMETYPE_IMAGE_JPEG = 0, MEDIA_MIMETYPE_VIDEO_AVC, MEDIA_MIMETYPE_VIDEO_HEVC, MEDIA_MIMETYPE_AUDIO_AAC, MEDIA_MIMETYPE_INVALID }

Enumerates MIME types.

Profile { INVALID_PROFILE = 0, AAC_LC_PROFILE = 0x1000, AAC_MAIN_PROFILE, AAC_HE_V1_PROFILE, AAC_HE_V2_PROFILE, AAC_LD_PROFILE, AAC_ELD_PROFILE, AVC_BASELINE_PROFILE = 0x2000, AVC_MAIN_PROFILE, AVC_HIGH_PROFILE, HEVC_MAIN_PROFILE = 0x3000, HEVC_MAIN_10_PROFILE }

Enumerates codec profiles.

Level { INVALID_LEVEL = 0, AVC_LEVEL_1 = 0x1000, HEVC_LEVEL_MAIN_1 = 0x2000, HEVC_LEVEL_MAIN_2 }

Enumerates codec levels.

AllocateBufferMode { ALLOCATE_INPUT_BUFFER_CODEC = 0x1, ALLOCATE_INPUT_BUFFER_USER = 0x2, ALLOCATE_OUTPUT_BUFFER_CODEC = 0x4, ALLOCATE_OUTPUT_BUFFER_USER = 0x8 }

Enumerates allocation modes of input and output buffers.

CapsMask { ADAPTIVE_PLAYBACK = 0x1, SECURE_PLAYBACK = 0x2 }

Enumerates playback capabilities.

EventType { EventError, EventFlushCompelte, EventStopCompelte, EventOutFormatChanged, EventMax = 0x1FFFFFFF }

Enumerates event types.

DirectionType { INPUT_TYPE, OUTPUT_TYPE, ALL_TYPE }

Enumerates input and output types.

BufferMode { INTERNAL, EXTERNAL }

Enumerates allocation types.

{ CODEC_ERR_STREAM_BUF_FULL = 100, CODEC_ERR_FRAME_BUF_EMPTY, CODEC_RECEIVE_EOS, CODEC_ERR_INVALID_OP }

Enumerates codec error types.

1
https://gitee.com/famoustang/docs.git
git@gitee.com:famoustang/docs.git
famoustang
docs
docs
master

搜索帮助