Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Channel ¶
type Channel struct { Model models.Channel `json:"data"` Streams []StreamSource `json:"stream_sources"` Ingress *StreamIngress `json:"ingress,omitemptry"` }
type ConfigStream ¶
type ConfigStream struct { Streams []StreamSource `config:"stream_sources"` Ingress StreamIngress `config:"ingress"` }
func (*ConfigStream) ForChannel ¶
func (cs *ConfigStream) ForChannel(expire *oven.Policy, obj models.Channel) ConfigStream
ForChannel fills ConfigStream by placeholder with values for a defined channel
type Restream ¶
type Restream struct { ID string `json:"id" example:"d592d376-0d93-4c2a-8156-5ea872fa748a Blub"` Name string `json:"name" example:"Blub"` Protocol string `json:"protocol" example:"rtmp"` URL string `json:"url" example:"rtmp://a.rtmp.youtube.com/live2"` StreamKey string `json:"secret" example:"SUPERSECRET"` // extras State string `json:"state" example:"ready"` Sequence int `json:"sequence" example:"1"` }
Restream data
func RestreamFromOven ¶
func RestreamFromOven(data *oven.ResponsePushData) *Restream
type RestreamAdd ¶
type RestreamAdd struct { Name string `json:"name" example:"Blub"` Protocol string `json:"protocol" example:"rtmp"` URL string `json:"url" example:"rtmp://a.rtmp.youtube.com/live2"` StreamKey string `json:"secret" example:"SUPERSECRET"` }
RestreamAdd
func (*RestreamAdd) ToOven ¶
func (d *RestreamAdd) ToOven(channelID string) *oven.ResponsePushStart
Convert for Oven
type StreamIngress ¶
type StreamIngress struct { OvenPolicySignedKey string `config:"-" json:"-"` PolicyExpire time.Duration `config:"-" json:"-"` WebRTC string `json:"webrtc"` RTMP string `json:"rtmp"` Policy *oven.Policy `config:"-" json:"policy,omitempty"` }
func (*StreamIngress) ForChannel ¶
func (si *StreamIngress) ForChannel(policy *oven.Policy, r *strings.Replacer) StreamIngress
ForChannel fills StreamIngress by replacer with values for a defined channel
type StreamSource ¶
type StreamSource struct { Label string `json:"label"` Type string `json:"type"` File string `json:"file"` FrameRate int `json:"framerate,omitempty"` }
func (*StreamSource) ForChannel ¶
func (ss *StreamSource) ForChannel(r *strings.Replacer) StreamSource
ForChannel fills StreamSource by replacer with values for a defined channel
Click to show internal directories.
Click to hide internal directories.