Server: fix no video bug
@@ -126,13 +126,13 @@ func NewWebRTCTransport(id string, options map[string]interface{}) *WebRTCTransp
return nil
}
- _, err = w.pc.AddTransceiver(webrtc.RTPCodecTypeVideo, webrtc.RtpTransceiverInit{Direction: webrtc.RTPTransceiverDirectionSendrecv})
+ _, err = w.pc.AddTransceiver(webrtc.RTPCodecTypeVideo, webrtc.RtpTransceiverInit{Direction: webrtc.RTPTransceiverDirectionRecvonly})
if err != nil {
log.Errorf("w.pc.AddTransceiver video %v", err)
return nil
}
- _, err = w.pc.AddTransceiver(webrtc.RTPCodecTypeAudio, webrtc.RtpTransceiverInit{Direction: webrtc.RTPTransceiverDirectionSendrecv})
+ _, err = w.pc.AddTransceiver(webrtc.RTPCodecTypeAudio, webrtc.RtpTransceiverInit{Direction: webrtc.RTPTransceiverDirectionRecvonly})
if err != nil {
log.Errorf("w.pc.AddTransceiver audio %v", err)
return nil
