gstreamer

package
v0.0.0-...-2087a59 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 14, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetProperties

func SetProperties(e *gst.Element, pp map[string]any) error

Types

type RTPBin

type RTPBin struct {
	SetTargetRateEncoder func(ratebps uint) error
	// contains filtered or unexported fields
}

func NewRTPBin

func NewRTPBin(opts ...RTPBinOption) (*RTPBin, error)

func (*RTPBin) AddRTPSink

func (r *RTPBin) AddRTPSink(id int, sink RTPSinkBin) error

func (*RTPBin) AddRTPSourceStreamGst

func (r *RTPBin) AddRTPSourceStreamGst(id int, src RTPSourceBin) error

func (*RTPBin) AddRTPTransportSink

func (r *RTPBin) AddRTPTransportSink(id int, wc io.WriteCloser) error

func (*RTPBin) AddRTPTransportSinkGst

func (r *RTPBin) AddRTPTransportSinkGst(id int, sink *gst.Element) error

func (*RTPBin) DebugBinToDotFile

func (r *RTPBin) DebugBinToDotFile(name string)

func (*RTPBin) Pipeline

func (r *RTPBin) Pipeline() *gst.Pipeline

func (*RTPBin) ReceiveRTCPFrom

func (r *RTPBin) ReceiveRTCPFrom(rc io.ReadCloser) error

func (*RTPBin) ReceiveRTCPFromGst

func (r *RTPBin) ReceiveRTCPFromGst(src *gst.Element) error

func (*RTPBin) ReceiveRTPStreamFrom

func (r *RTPBin) ReceiveRTPStreamFrom(id int, rc io.ReadCloser, screamCCFB bool) error

func (*RTPBin) ReceiveRTPStreamFromGst

func (r *RTPBin) ReceiveRTPStreamFromGst(id int, src *gst.Element, screamCCFB bool) error

func (*RTPBin) Run

func (r *RTPBin) Run() error

func (*RTPBin) SendRTCPForStream

func (r *RTPBin) SendRTCPForStream(id int, wc io.WriteCloser) error

func (*RTPBin) SendRTCPForStreamGst

func (r *RTPBin) SendRTCPForStreamGst(id int, sink *gst.Element) error

type RTPBinOption

type RTPBinOption func(*RTPBin) error

func EnableSCReAM

func EnableSCReAM(initRateKbps, minRateKbps, maxRateKbps uint) RTPBinOption

type RTPSinkBin

type RTPSinkBin interface {
	Element() *gst.Element
	SinkPad() (*gst.Pad, error)
	ClockRate() int
	EncodingName() string
	PayloadTypeName() string
	PayloadType() int
	MediaType() string
}

type RTPSourceBin

type RTPSourceBin interface {
	Element() *gst.Element
	SrcPad() (*gst.Pad, error)
	EncodingName() string
}

type SinkType

type SinkType uint
const (
	Autovideosink SinkType = iota
	Filesink
	Fakesink
)

type Source

type Source int
const (
	Videotestsrc Source = iota
	Filesrc
)

type StreamSink

type StreamSink struct {
	// contains filtered or unexported fields
}

func NewStreamSink

func NewStreamSink(name string, opts ...StreamSinkOption) (*StreamSink, error)

func (*StreamSink) ClockRate

func (s *StreamSink) ClockRate() int

func (*StreamSink) Element

func (s *StreamSink) Element() *gst.Element

func (*StreamSink) EncodingName

func (s *StreamSink) EncodingName() string

func (*StreamSink) MediaType

func (s *StreamSink) MediaType() string

func (*StreamSink) PayloadType

func (s *StreamSink) PayloadType() int

func (*StreamSink) PayloadTypeName

func (s *StreamSink) PayloadTypeName() string

func (*StreamSink) SinkPad

func (s *StreamSink) SinkPad() (*gst.Pad, error)

type StreamSinkOption

type StreamSinkOption func(*StreamSink) error

func StreamSinkCodec

func StreamSinkCodec(codec mrtp.Codec) StreamSinkOption

func StreamSinkLocation

func StreamSinkLocation(location string) StreamSinkOption

func StreamSinkPayloadType

func StreamSinkPayloadType(pt int) StreamSinkOption

func StreamSinkType

func StreamSinkType(sinkType SinkType) StreamSinkOption

func StreamSourcePayloadType

func StreamSourcePayloadType(pt int) StreamSinkOption

type StreamSource

type StreamSource struct {
	// contains filtered or unexported fields
}

func NewStreamSource

func NewStreamSource(name string, opts ...StreamSourceOption) (*StreamSource, error)

func (*StreamSource) Element

func (s *StreamSource) Element() *gst.Element

func (*StreamSource) EncodingName

func (s *StreamSource) EncodingName() string

func (*StreamSource) SetBitrate

func (s *StreamSource) SetBitrate(ratebps uint) error

SetBitrate sets the target bit rate of the encoder

func (*StreamSource) SrcPad

func (s *StreamSource) SrcPad() (*gst.Pad, error)

type StreamSourceOption

type StreamSourceOption func(*StreamSource) error

func StreamSourceCodec

func StreamSourceCodec(codec mrtp.Codec) StreamSourceOption

func StreamSourceFileSourceLocation

func StreamSourceFileSourceLocation(location string) StreamSourceOption

func StreamSourceType

func StreamSourceType(source Source) StreamSourceOption

type UDPSink

type UDPSink struct {
	// contains filtered or unexported fields
}

func NewUDPSink

func NewUDPSink(address string, port uint32, opts ...UDPSinkOption) (*UDPSink, error)

func (*UDPSink) GetGstElement

func (s *UDPSink) GetGstElement() *gst.Element

type UDPSinkOption

type UDPSinkOption func(*UDPSink)

func EnabelUDPSinkPadProbe

func EnabelUDPSinkPadProbe(enabled bool) UDPSinkOption

type UDPSrc

type UDPSrc struct {
	// contains filtered or unexported fields
}

func NewUDPSrc

func NewUDPSrc(address string, port uint32, opts ...UDPSrcOption) (*UDPSrc, error)

func (*UDPSrc) GetGstElement

func (s *UDPSrc) GetGstElement() *gst.Element

type UDPSrcOption

type UDPSrcOption func(*UDPSrc)

func EnabelUDPSrcPadProbe

func EnabelUDPSrcPadProbe(enabled bool) UDPSrcOption

func SetReceiveBufferSize

func SetReceiveBufferSize(size int) UDPSrcOption

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL