Use Pion's JSON support for ICE configuration.
This commit is contained in:
+2
-6
@@ -138,9 +138,7 @@ type rtpDownConnection struct {
|
||||
|
||||
func newDownConn(c group.Client, id string, remote conn.Up) (*rtpDownConnection, error) {
|
||||
api := group.APIFromCodecs(remote.Codecs())
|
||||
pc, err := api.NewPeerConnection(
|
||||
group.ToConfiguration(group.ICEConfiguration()),
|
||||
)
|
||||
pc, err := api.NewPeerConnection(*group.ICEConfiguration())
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -459,9 +457,7 @@ func pushConn(up *rtpUpConnection, g *group.Group, cs []group.Client) {
|
||||
}
|
||||
|
||||
func newUpConn(c group.Client, id string, labels map[string]string) (*rtpUpConnection, error) {
|
||||
pc, err := c.Group().API().NewPeerConnection(
|
||||
group.ToConfiguration(group.ICEConfiguration()),
|
||||
)
|
||||
pc, err := c.Group().API().NewPeerConnection(*group.ICEConfiguration())
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
@@ -177,7 +177,7 @@ type clientMessage struct {
|
||||
Candidate *webrtc.ICECandidateInit `json:"candidate,omitempty"`
|
||||
Labels map[string]string `json:"labels,omitempty"`
|
||||
Request rateMap `json:"request,omitempty"`
|
||||
RTCConfiguration *group.RTCConfiguration `json:"rtcConfiguration,omitempty"`
|
||||
RTCConfiguration *webrtc.Configuration `json:"rtcConfiguration,omitempty"`
|
||||
}
|
||||
|
||||
type closeMessage struct {
|
||||
|
||||
Reference in New Issue
Block a user