You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Help pls RTSPtoWebRTC found error WriteHeader unable to start track, codec is not supported by remote but do receive sdp and support H264(update log)
#234
Open
yuchinchenTW opened this issue
Jun 24, 2024
· 1 comment
Yocto kirkstone
Chromium 120.0.6099.224 stable
go version go1.20.14 linux/arm64
has tried rtsp with
gst-play-1.0 rtsp://admin:[email protected]/live/h264 and the view we want has shown this proven our device support h264
when running RTSPtoWebRTC
we found out that the camera view did not comes appeared
here is how we debug:
in the http.go
we add log to print
func HTTPAPIServerStreamWebRTC(c *gin.Context) {
if !Config.ext(c.PostForm("suuid")) {
log.Println("Stream Not Found")
return
}
Config.RunIFNotRun(c.PostForm("suuid"))
codecs := Config.coGe(c.PostForm("suuid"))
if codecs == nil {
log.Println("Stream Codec Not Found")
return
}
log.Println("Codecs:", codecs)
var AudioOnly bool
if len(codecs) == 1 && codecs[0].Type().IsAudio() {
AudioOnly = true
}
muxerWebRTC := webrtc.NewMuxer(webrtc.Options{ICEServers: Config.GetICEServers(), ICEUsername: Config.GetICEUsername(), ICECredential: Config.GetICECredential(), PortMin: Config.GetWebRTC>
sdp := c.PostForm("data")
if sdp == "" {
log.Println("Error: No SDP data provided")
}
log.Println("Received SDP data:", sdp)
log.Println("Codec Supported WebRTC :", codecs[0].Type())
answer, err := muxerWebRTC.WriteHeader(codecs, c.PostForm("data"))
if err != nil {
log.Println("error happened no answer")
log.Println("WriteHeader", err)
return
}
log.Println("")
log.Println("Generated SDP answer:", answer)
our environment:
when running RTSPtoWebRTC
we found out that the camera view did not comes appeared
here is how we debug:
in the http.go
we add log to print
turns out that
it seems like its does receive sdp but somehow stuck on
answer, err := muxerWebRTC.WriteHeader(codecs, c.PostForm("data"))
does anyone know why?
The text was updated successfully, but these errors were encountered: