Documentation
¶
Index ¶
- func Descriptor() codec.Descriptor
- func Register(registry *codec.SimpleRegistry)
- type Decoder
- func (d *Decoder) Close() error
- func (d *Decoder) DecodeInto(ctx context.Context, pkt *av.Packet, out *codec.DecodeResult) error
- func (d *Decoder) Descriptor() codec.Descriptor
- func (d *Decoder) FlushInto(ctx context.Context, _ *codec.DecodeResult) error
- func (d *Decoder) HandleEvent(ctx context.Context, event *av.Event) error
- func (d *Decoder) Open(ctx context.Context, config codec.DecodeConfig) error
- type DecoderFactory
- type Encoder
- func (e *Encoder) Close() error
- func (e *Encoder) Descriptor() codec.Descriptor
- func (e *Encoder) EncodeInto(ctx context.Context, frame *av.Frame, out *codec.EncodeResult) error
- func (e *Encoder) EncodedParameters() av.CodecParameters
- func (e *Encoder) FlushInto(ctx context.Context, out *codec.EncodeResult) error
- func (e *Encoder) HandleEvent(ctx context.Context, event *av.Event) error
- func (e *Encoder) Open(ctx context.Context, config codec.EncodeConfig) error
- type EncoderFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Descriptor ¶
func Descriptor() codec.Descriptor
func Register ¶
func Register(registry *codec.SimpleRegistry)
Types ¶
type Decoder ¶
type Decoder struct {
// contains filtered or unexported fields
}
func (*Decoder) DecodeInto ¶
func (*Decoder) Descriptor ¶
func (d *Decoder) Descriptor() codec.Descriptor
func (*Decoder) HandleEvent ¶
type DecoderFactory ¶
type DecoderFactory struct{}
func NewDecoderFactory ¶
func NewDecoderFactory() DecoderFactory
func (DecoderFactory) NewDecoder ¶
func (DecoderFactory) NewDecoder(ctx context.Context, config codec.DecodeConfig) (codec.Decoder, error)
type Encoder ¶
type Encoder struct {
// contains filtered or unexported fields
}
func (*Encoder) Descriptor ¶
func (e *Encoder) Descriptor() codec.Descriptor
func (*Encoder) EncodeInto ¶
func (*Encoder) EncodedParameters ¶
func (e *Encoder) EncodedParameters() av.CodecParameters
EncodedParameters reports the identification header, whose pre-skip tells decoders to drop the lookahead samples the first packets start with.
func (*Encoder) FlushInto ¶
FlushInto encodes what the input left at end of stream: the final partial frame and the lookahead still inside the encoder, padded with silence to whole Opus frames. The last packet's duration ends where the input did.
func (*Encoder) HandleEvent ¶
type EncoderFactory ¶
type EncoderFactory struct{}
func NewEncoderFactory ¶
func NewEncoderFactory() EncoderFactory
func (EncoderFactory) NewEncoder ¶
func (EncoderFactory) NewEncoder(ctx context.Context, config codec.EncodeConfig) (codec.Encoder, error)