2020-10-23 03:54:50 +13:00
|
|
|
package types
|
|
|
|
|
2021-02-03 07:21:48 +13:00
|
|
|
import "github.com/pion/webrtc/v3"
|
|
|
|
|
2020-11-26 06:41:40 +13:00
|
|
|
type WebRTCPeer interface {
|
|
|
|
SignalAnswer(sdp string) error
|
2021-02-03 08:43:33 +13:00
|
|
|
SignalCandidate(candidate webrtc.ICECandidateInit) error
|
2021-02-13 10:13:55 +13:00
|
|
|
|
2021-02-06 05:57:33 +13:00
|
|
|
SetVideoID(videoID string) error
|
2021-02-13 10:13:55 +13:00
|
|
|
SendCursorPosition(x, y int) error
|
2021-02-26 02:24:17 +13:00
|
|
|
SendCursorImage(cur *CursorImage, img []byte) error
|
2021-02-03 08:43:33 +13:00
|
|
|
|
2020-11-26 06:41:40 +13:00
|
|
|
Destroy() error
|
|
|
|
}
|
|
|
|
|
2020-10-23 03:54:50 +13:00
|
|
|
type WebRTCManager interface {
|
|
|
|
Start()
|
|
|
|
Shutdown() error
|
2021-02-03 07:21:48 +13:00
|
|
|
|
|
|
|
ICELite() bool
|
|
|
|
ICEServers() []string
|
|
|
|
|
2021-02-08 05:07:55 +13:00
|
|
|
CreatePeer(session Session, videoID string) (*webrtc.SessionDescription, error)
|
2020-10-23 03:54:50 +13:00
|
|
|
}
|