rtmp

package
v0.0.0-...-545087f Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	FunctionRequest         = 1
	FunctionRDRSplitHorizon = 2
	FunctionRDRComplete     = 3
	FunctionLoopProbe       = 4 // AURP Ch.4 pp 94
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DataPacket

type DataPacket struct {
	RouterAddr    ddp.Addr
	Extended      bool
	NetworkTuples []NetworkTuple
}

DataPacket represents an RTMP Data packet.

func UnmarshalDataPacket

func UnmarshalDataPacket(data []byte) (*DataPacket, error)

UnmarshalDataPacket unmarshals a DataPacket.

func (*DataPacket) Marshal

func (dp *DataPacket) Marshal() ([]byte, error)

Marshal marshals an RTMP Data packet.

type NetworkTuple

type NetworkTuple struct {
	Extended   bool
	RangeStart ddp.Network
	RangeEnd   ddp.Network
	Distance   uint8
}

NetworkTuple represents routing information.

func (*NetworkTuple) Size

func (nt *NetworkTuple) Size() int

type RequestPacket

type RequestPacket struct {
	Function uint8
	Data     []byte // only for LoopProbe
}

RequestPacket represents an RTMP Request, Route Data Request, or Loop Probe.

func UnmarshalRequestPacket

func UnmarshalRequestPacket(data []byte) (*RequestPacket, error)

UnmarshalRequestPacket unmarshals an RTMP Request or RTMP RDR packet.

func (*RequestPacket) Marshal

func (rp *RequestPacket) Marshal() ([]byte, error)

Marshal marshals an RTMP Request or RTMP RDR packet.

type ResponsePacket

type ResponsePacket struct {
	SenderAddr ddp.Addr
	Extended   bool
	RangeStart ddp.Network
	RangeEnd   ddp.Network
}

ResponsePacket represents an RTMP Response packet.

func UnmarshalResponsePacket

func UnmarshalResponsePacket(data []byte) (*ResponsePacket, error)

UnmarshalResponsePacket unmarshals an RTMP Response packet.

func (*ResponsePacket) Marshal

func (rp *ResponsePacket) Marshal() ([]byte, error)

Marshal marshals an RTMP Response packet.

Jump to

Keyboard shortcuts

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