Documentation
¶
Overview ¶
Package media receives source-element media on the source host and exposes bounded encoded packets for an embedding host's authenticated byte streams.
Index ¶
Constants ¶
View Source
const ( WireVersion = 1 MaxHeaderBytes = 16 * 1024 MaxPacketBytes = 2 * 1024 * 1024 StreamChunkBytes = 16 * 1024 )
Variables ¶
View Source
var ErrClosed = errors.New("media subscription closed")
View Source
var ErrInvalidPacket = errors.New("invalid media packet")
View Source
var ErrKeyframeRequired = errors.New("media video reference expired")
Functions ¶
Types ¶
type Collector ¶
type Collector struct {
// contains filtered or unexported fields
}
func NewCollector ¶
NewCollector binds a fresh source-host loopback socket. ICE-lite prevents outgoing checks to source-supplied candidates. It is never a remote carrier.
func (*Collector) RequestKeyframe ¶
func (c *Collector) RequestKeyframe()
type Header ¶
type Header struct {
Version int `json:"version"`
Target string `json:"target"`
View string `json:"view"`
Stream string `json:"stream"`
Node int64 `json:"node"`
Track string `json:"track"`
Codec string `json:"codec"`
TimestampUS int64 `json:"timestamp_us"`
DurationUS int64 `json:"duration_us"`
Keyframe bool `json:"keyframe"`
Width int `json:"width,omitempty"`
Height int `json:"height,omitempty"`
Description string `json:"description,omitempty"`
Bytes int `json:"bytes"`
}
Header carries presentation identity, never credentials or source addresses. TimestampUS is relative to the source subscription's monotonic clock.
type Queue ¶
type Queue struct {
// contains filtered or unexported fields
}
Queue belongs to one encoded track. A lost video reference invalidates all queued dependent frames. Canvas and audio have independent packet boundaries.
func NewQueue ¶
func NewQueue(limits QueueLimits) *Queue
func (*Queue) Invalidate ¶
func (q *Queue) Invalidate()
Invalidate discards dependent video frames after local capture packet loss.
type QueueLimits ¶
Directories
¶
| Path | Synopsis |
|---|---|
|
cmd
|
|
|
floebrowser-media
command
floebrowser-media is a local source helper.
|
floebrowser-media is a local source helper. |
Click to show internal directories.
Click to hide internal directories.