mirror of
https://github.com/AlexxIT/go2rtc.git
synced 2025-10-27 02:01:46 +08:00
BIG rewrite stream info
This commit is contained in:
@@ -18,6 +18,7 @@ import (
|
||||
pion "github.com/pion/webrtc/v3"
|
||||
)
|
||||
|
||||
// Deprecated: should be rewritten to core.Connection
|
||||
type Client struct {
|
||||
core.Listener
|
||||
|
||||
@@ -110,8 +111,10 @@ func (c *Client) Connect() error {
|
||||
var sendOffer sync.WaitGroup
|
||||
|
||||
c.conn = webrtc.NewConn(pc)
|
||||
c.conn.Desc = "Roborock"
|
||||
c.conn.FormatName = "roborock"
|
||||
c.conn.Mode = core.ModeActiveProducer
|
||||
c.conn.Protocol = "mqtt"
|
||||
c.conn.URL = c.url
|
||||
c.conn.Listen(func(msg any) {
|
||||
switch msg := msg.(type) {
|
||||
case *pion.ICECandidate:
|
||||
|
||||
Reference in New Issue
Block a user