rtmp

package
v0.0.0-...-62cb2ec Latest Latest
Warning

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

Go to latest
Published: Jul 7, 2024 License: BSD-3-Clause Imports: 13 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	EmptyID = ""
)

Functions

This section is empty.

Types

type Client

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

func NewRtmpClient

func NewRtmpClient(h av.Handler, getter av.GetWriter) *Client

func (*Client) Dial

func (self *Client) Dial(url string, method string) error

func (*Client) GetHandle

func (self *Client) GetHandle() av.Handler

type GetInFo

type GetInFo interface {
	GetInfo() (string, string, string)
}

type PackWriterCloser

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

func (*PackWriterCloser) GetWriter

func (p *PackWriterCloser) GetWriter() av.WriteCloser

type RtmpStream

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

func NewRtmpStream

func NewRtmpStream() *RtmpStream

func (*RtmpStream) CheckAlive

func (rs *RtmpStream) CheckAlive()

func (*RtmpStream) GetStreams

func (rs *RtmpStream) GetStreams() cmap.ConcurrentMap

func (*RtmpStream) HandleReader

func (rs *RtmpStream) HandleReader(r av.ReadCloser)

func (*RtmpStream) HandleWriter

func (rs *RtmpStream) HandleWriter(w av.WriteCloser)

type Server

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

func NewRtmpServer

func NewRtmpServer(h av.Handler, getters []av.GetWriter) *Server

func (*Server) Serve

func (self *Server) Serve(listener net.Listener) (err error)

type Stream

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

func NewStream

func NewStream() *Stream

func (*Stream) AddReader

func (s *Stream) AddReader(r av.ReadCloser)

func (*Stream) AddWriter

func (s *Stream) AddWriter(w av.WriteCloser)

func (*Stream) CheckAlive

func (s *Stream) CheckAlive() (n int)

func (*Stream) Copy

func (s *Stream) Copy(dst *Stream)

func (*Stream) GetReader

func (s *Stream) GetReader() av.ReadCloser

func (*Stream) GetWs

func (s *Stream) GetWs() cmap.ConcurrentMap

func (*Stream) ID

func (s *Stream) ID() string

func (*Stream) TransStart

func (s *Stream) TransStart()

func (*Stream) TransStop

func (s *Stream) TransStop()

type StreamReadWriteCloser

type StreamReadWriteCloser interface {
	GetInFo
	Close(error)
	Write(core.ChunkStream) error
	Read(c *core.ChunkStream) error
}

type VirReader

type VirReader struct {
	Uid string
	av.RWBaser
	// contains filtered or unexported fields
}

func NewVirReader

func NewVirReader(conn StreamReadWriteCloser) *VirReader

func (*VirReader) Close

func (self *VirReader) Close(err error)

func (*VirReader) Info

func (self *VirReader) Info() (ret av.Info)

func (*VirReader) Read

func (self *VirReader) Read(p *av.Packet) (err error)

type VirWriter

type VirWriter struct {
	Uid string

	av.RWBaser
	// contains filtered or unexported fields
}

func NewVirWriter

func NewVirWriter(conn StreamReadWriteCloser) *VirWriter

func (*VirWriter) Check

func (self *VirWriter) Check()

func (*VirWriter) Close

func (self *VirWriter) Close(err error)

func (*VirWriter) DropPacket

func (self *VirWriter) DropPacket(pktQue chan av.Packet, info av.Info)

func (*VirWriter) Info

func (self *VirWriter) Info() (ret av.Info)

func (*VirWriter) SendPacket

func (self *VirWriter) SendPacket() error

func (*VirWriter) Write

func (self *VirWriter) Write(p av.Packet) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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