Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HandleSDP

func HandleSDP(rw http.ResponseWriter, req *http.Request, src func() av.Demuxer, addViewer func(int)) error

Types

type OfferToReceive

type OfferToReceive struct {
	PlayRequest
	Offer webrtc.SessionDescription
}

func (OfferToReceive) Answer

func (o OfferToReceive) Answer() (*Sender, error)

type PlayRequest

type PlayRequest struct {
	Remote        string
	Source        func() av.Demuxer
	AddViewer     func(int)
	SendCandidate func(webrtc.ICECandidateInit)
	GatherDone    func()
}

func (PlayRequest) OfferToSend

func (p PlayRequest) OfferToSend() (*Sender, error)

type Sender

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

func (*Sender) Candidate

func (s *Sender) Candidate(candidate webrtc.ICECandidateInit)

func (*Sender) Close

func (s *Sender) Close()

func (*Sender) SDP

func (s *Sender) SDP() webrtc.SessionDescription

func (*Sender) SetAnswer

func (s *Sender) SetAnswer(answer webrtc.SessionDescription) error