camera

package
v1.3.1 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RandomBytes

func RandomBytes(size int) []byte

func RandomUint32

func RandomUint32() uint32

Types

type Client

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

func NewClient

func NewClient(client *hap.Conn) *Client

func (*Client) GetFreeStream

func (c *Client) GetFreeStream() (srv *hap.Service, err error)

GetFreeStream search free streaming service. Usual every HomeKit camera can stream only to two clients simultaniosly. So it has two similar services for streaming.

func (*Client) SetConfig

func (c *Client) SetConfig(srv *hap.Service, config *rtp.StreamConfiguration) (err error)

func (*Client) SetupEndpoins

func (c *Client) SetupEndpoins(
	srv *hap.Service, req *rtp.SetupEndpoints,
) (res *rtp.SetupEndpointsResponse, err error)

func (*Client) StartStream

func (c *Client) StartStream(ses *Session) (err error)

type Session

type Session struct {
	Offer  *rtp.SetupEndpoints
	Answer *rtp.SetupEndpointsResponse
	Config *rtp.StreamConfiguration
}

func NewSession

func NewSession(vp *rtp.VideoParameters, ap *rtp.AudioParameters) *Session

func (*Session) SetLocalEndpoint

func (s *Session) SetLocalEndpoint(host string, port uint16)

Jump to

Keyboard shortcuts

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