mirror of
https://github.com/pion/webrtc.git
synced 2025-10-04 14:53:05 +08:00
Enable STUN by default in examples
This commit is contained in:
@@ -32,7 +32,13 @@ func main() {
|
||||
webrtc.RegisterCodec(webrtc.NewRTCRtpVP8Codec(webrtc.DefaultPayloadTypeVP8, 90000))
|
||||
|
||||
// Create a new RTCPeerConnection
|
||||
peerConnection, err := webrtc.New(webrtc.RTCConfiguration{})
|
||||
peerConnection, err := webrtc.New(webrtc.RTCConfiguration{
|
||||
ICEServers: []webrtc.RTCICEServer{
|
||||
{
|
||||
URLs: []string{"stun:stun.l.google.com:19302"},
|
||||
},
|
||||
},
|
||||
})
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
Reference in New Issue
Block a user