mikedmor / OctoPrint_MultiCam

Extends the Control tab of OctoPrint, allowing the ability to switch between multiple webcam feeds.
45 stars 19 forks source link

Not working with webrtc/mp4 streams generated by go2rtc #72

Open puterboy opened 3 weeks ago

puterboy commented 3 weeks ago

I am using go2rtc to generate streams for both a PiCamera v3 and a USB cam running on my RPi5. Go2rtc seems to be a very powerful yet simple to implement streamer.

I can get it to work with Octoprint/MultiCam for mjpeg streams and legacy HLS streams. But I can't get it to work for webrtc mp4 streams.

The webrtc url I have is of form:

http://mypi/api/stream.mp4?src=picam_h264

The stream plays just fine in my browser or in apps like mplayer and vlc. But it fails to display in Octoprint.

(I would prefer not to use mjpeg since it's inefficient and and not HLS since it seems flakey)

So is there anything I need to do to get a seemingly generic webrtc stream like the above to work with MultiCam? What more generally is the status and limitations of webrtc for Octoprint?

Thanks