livestream

package
v0.3.9 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2021 License: GPL-3.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Livestream

type Livestream interface {
	Publish() error
	Meta() *pb.Meta
}

Livestream broadcasts live stream, it either consumes RTP stream from a RTP client, or pulls RTSP stream from a RTSP server. The underlining transportation is WebRTC.

func NewDeportPublisher

func NewDeportPublisher(ctx context.Context, configOptions *PublisherConfigOptions) Livestream

func NewDronePublisher

func NewDronePublisher(ctx context.Context, configOptions *PublisherConfigOptions) Livestream

type MQTTClientConfigOptions

type MQTTClientConfigOptions struct {
	OfferTopicPrefix         string
	AnswerTopicPrefix        string
	CandidateSendTopicPrefix string // Opposite to cloud's CandidateRecvTopicPrefix topic
	CandidateRecvTopicPrefix string // Opposite to cloud's CandidateSendTopicPrefix topic.
	HookStreamTopicPrefix    string
	Qos                      uint
	Retained                 bool
}

type PublisherConfigOptions

type PublisherConfigOptions struct {
	UUID string
	MQTTClientConfigOptions
	WebRTCConfigOptions

	// Currently only RTP is supported for drone.
	// Currently mainly RTSP, the other one is RTP for deport.
	StreamSource
}

type RTPOrRTMPSourceConfigOptions added in v0.3.1

type RTPOrRTMPSourceConfigOptions struct {
	Host string
	Port int
}

type RTSPSourceConfigOptions

type RTSPSourceConfigOptions struct {
	Addr string
}

type StreamSource

type StreamSource struct {
	Protocol string // rtp or rtsp or rtmp
	RTSPSourceConfigOptions
	RTPOrRTMPSourceConfigOptions

	ConsumeStreamOnDemand bool
}

type WebRTCConfigOptions

type WebRTCConfigOptions struct {
	ICEServer  string
	Username   string
	Credential string
}

Jump to

Keyboard shortcuts

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