Skip to content

node-av / lib/native-types / NativeCodec

Interface: NativeCodec ​

Defined in: src/lib/native-types.ts:177

Internal

Native AVCodec binding interface

Represents a codec (encoder or decoder) definition. This is an immutable descriptor - actual encoding/decoding happens via CodecContext.

Properties ​

__brand ​

readonly __brand: "NativeCodec"

Defined in: src/lib/native-types.ts:178


capabilities ​

readonly capabilities: AVCodecCap

Defined in: src/lib/native-types.ts:184


channelLayouts ​

readonly channelLayouts: ChannelLayout[] | null

Defined in: src/lib/native-types.ts:192


id ​

readonly id: AVCodecID

Defined in: src/lib/native-types.ts:183


longName ​

readonly longName: string | null

Defined in: src/lib/native-types.ts:181


maxLowres ​

readonly maxLowres: number

Defined in: src/lib/native-types.ts:185


name ​

readonly name: string | null

Defined in: src/lib/native-types.ts:180


pixelFormats ​

readonly pixelFormats: AVPixelFormat[] | null

Defined in: src/lib/native-types.ts:189


profiles ​

readonly profiles: CodecProfile[] | null

Defined in: src/lib/native-types.ts:186


sampleFormats ​

readonly sampleFormats: AVSampleFormat[] | null

Defined in: src/lib/native-types.ts:191


supportedFramerates ​

readonly supportedFramerates: IRational[] | null

Defined in: src/lib/native-types.ts:188


supportedSamplerates ​

readonly supportedSamplerates: number[] | null

Defined in: src/lib/native-types.ts:190


type ​

readonly type: AVMediaType

Defined in: src/lib/native-types.ts:182


wrapper ​

readonly wrapper: string | null

Defined in: src/lib/native-types.ts:187

Methods ​

getHwConfig() ​

getHwConfig(index): { deviceType: AVHWDeviceType; methods: number; pixFmt: AVPixelFormat; } | null

Defined in: src/lib/native-types.ts:197

Parameters ​

index ​

number

Returns ​

{ deviceType: AVHWDeviceType; methods: number; pixFmt: AVPixelFormat; } | null


getOptions() ​

getOptions(): NativeCodecOption[]

Defined in: src/lib/native-types.ts:198

Returns ​

NativeCodecOption[]


isDecoder() ​

isDecoder(): boolean

Defined in: src/lib/native-types.ts:195

Returns ​

boolean


isEncoder() ​

isEncoder(): boolean

Defined in: src/lib/native-types.ts:194

Returns ​

boolean


isExperimental() ​

isExperimental(): boolean

Defined in: src/lib/native-types.ts:196

Returns ​

boolean