Documentation ¶
Index ¶
- Constants
- func FillADTSHeader(header []byte, config MPEG4AudioConfig, samples int, payloadLength int)
- func WriteMPEG4AudioConfig(w io.Writer, config MPEG4AudioConfig) (err error)
- type CodecData
- func (inst CodecData) ChannelLayout() av.ChannelLayout
- func (inst CodecData) MPEG4AudioConfigBytes() []byte
- func (inst CodecData) PacketDuration(data []byte) (dur time.Duration, err error)
- func (inst CodecData) SampleFormat() av.SampleFormat
- func (inst CodecData) SampleRate() int
- func (inst CodecData) Type() av.CodecType
- type MPEG4AudioConfig
Constants ¶
View Source
const ( AotAACMain = 1 + iota ///< Y Main AotAACLc ///< Y Low Complexity AotAACSsr ///< N (code in SoC repo) Scalable Sample Rate AotAACLtp ///< Y Long Term Prediction AotSBR ///< Y Spectral Band Replication AotAACScalable ///< N Scalable AotTWINVQ ///< N Twin Vector Quantizer AotCELP ///< N Code Excited Linear Prediction AotHVXC ///< N Harmonic Vector eXcitation Coding AotTTSI = 12 + iota ///< N Text-To-Speech Interface AotMAINSYNTH ///< N Main Synthesis AotWAVESYNTH ///< N Wavetable Synthesis AotMIDI ///< N General MIDI AotSAFX ///< N Algorithmic Synthesis and Audio Effects AotErAACLc ///< N Error Resilient Low Complexity AotErAACLtp = 19 + iota ///< N Error Resilient Long Term Prediction AotErAACScalable ///< N Error Resilient Scalable AotErTWINVQ ///< N Error Resilient Twin Vector Quantizer AotErBSAC ///< N Error Resilient Bit-Sliced Arithmetic Coding AotErAACLd ///< N Error Resilient Low Delay AotErCELP ///< N Error Resilient Code Excited Linear Prediction AotErHVXC ///< N Error Resilient Harmonic Vector eXcitation Coding AotErHILN ///< N Error Resilient Harmonic and Individual Lines plus Noise AotErPARAM ///< N Error Resilient Parametric AotSSC ///< N SinuSoidal Coding AotPS ///< N Parametric Stereo AotSURROUND ///< N MPEG Surround AotESCAPE ///< Y Escape Value AotL1 ///< Y Layer 1 AotL2 ///< Y Layer 2 AotL3 ///< Y Layer 3 AotDST ///< N Direct Stream Transfer AotALS ///< Y Audio LosslesS AotSLS ///< N Scalable LosslesS AotSlsNonCore ///< N Scalable LosslesS (non core) AotErAACEld ///< N Error Resilient Enhanced Low Delay AotSmrSimple ///< N Symbolic Music Representation Simple AotSmrMain ///< N Symbolic Music Representation Main AotUsacNosbr ///< N Unified Speech and Audio Coding (no SBR) AotSAOC ///< N Spatial Audio Object Coding AotLdSurround ///< N Low Delay MPEG Surround AotUsac ///< N Unified Speech and Audio Coding )
copied from libavcodec/mpeg4audio.h
View Source
const ADTSHeaderLength = 7
ADTSHeaderLength const
Variables ¶
This section is empty.
Functions ¶
func FillADTSHeader ¶
func FillADTSHeader(header []byte, config MPEG4AudioConfig, samples int, payloadLength int)
FillADTSHeader func
func WriteMPEG4AudioConfig ¶
func WriteMPEG4AudioConfig(w io.Writer, config MPEG4AudioConfig) (err error)
WriteMPEG4AudioConfig func
Types ¶
type CodecData ¶
type CodecData struct { ConfigBytes []byte Config MPEG4AudioConfig }
CodecData struct
func NewCodecDataFromMPEG4AudioConfig ¶
func NewCodecDataFromMPEG4AudioConfig(config MPEG4AudioConfig) (inst CodecData, err error)
NewCodecDataFromMPEG4AudioConfig func
func NewCodecDataFromMPEG4AudioConfigBytes ¶
NewCodecDataFromMPEG4AudioConfigBytes func
func (CodecData) ChannelLayout ¶
func (inst CodecData) ChannelLayout() av.ChannelLayout
ChannelLayout func
func (CodecData) MPEG4AudioConfigBytes ¶
MPEG4AudioConfigBytes func
func (CodecData) PacketDuration ¶
PacketDuration func
func (CodecData) SampleFormat ¶
func (inst CodecData) SampleFormat() av.SampleFormat
SampleFormat func
type MPEG4AudioConfig ¶
type MPEG4AudioConfig struct { SampleRate int ChannelLayout av.ChannelLayout ObjectType uint SampleRateIndex uint ChannelConfig uint }
MPEG4AudioConfig struct
func ParseADTSHeader ¶
func ParseADTSHeader(frame []byte) (config MPEG4AudioConfig, hdrlen int, framelen int, samples int, err error)
ParseADTSHeader func
func ParseMPEG4AudioConfigBytes ¶
func ParseMPEG4AudioConfigBytes(data []byte) (config MPEG4AudioConfig, err error)
ParseMPEG4AudioConfigBytes func
Click to show internal directories.
Click to hide internal directories.