Documentation ¶
Index ¶
Constants ¶
View Source
const ( AudioID = 0 VideoID = 1 )
List of packet ids
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { SecretKey []byte PeerList []*Peer Addr DeterminableAddr // contains filtered or unexported fields }
Client refers to the backend of the client containing all basic information needed by the core
func (*Client) Initialize ¶
Initialize setup the client, should be called first
type DeterminableAddr ¶
type DeterminableAddr struct { Candidates []*net.UDPAddr // contains filtered or unexported fields }
DeterminableAddr is a container of candidates and the current one
type PacketBuffer ¶
type PacketBuffer struct {
// contains filtered or unexported fields
}
PacketBuffer is a queue of packet, handles packet ordering internally
func (*PacketBuffer) Push ¶
func (buffer *PacketBuffer) Push(packet *Packet)
Push a packet to the buffer
type Peer ¶
type Peer struct { PublicKey []byte Addr DeterminableAddr Volume float32 Name string GetAudioData func() []float32 SendOpusData func([]byte) // contains filtered or unexported fields }
Peer refers to another spear user
func (*Peer) DisplayName ¶
DisplayName returns the displayed name on CUI
Click to show internal directories.
Click to hide internal directories.