fluidd-core / fluidd

Fluidd, the klipper UI.
https://docs.fluidd.xyz
GNU General Public License v3.0
1.36k stars 415 forks source link

FR: RTSP camera support #97

Closed dandantsui closed 3 years ago

dandantsui commented 3 years ago

Forgive me if I am wrong but I've tried mjpgstreamer and IP camera stream type with a rtsp:// link and both options don't seem to load the rtsp stream.

Is there any way to get this working or does it needs a different stream type?

cadriel commented 3 years ago

RTSP requires specialized components and code to support streaming in a web browser.

Instead, Fluidd supports the HTML 5 <video> tag. This gives native support for streaming protocols such as WebRTC.

Suggest looking into streaming something natively supported above, as that'd give you the best experience. rtsp:// may come later if there's strong enough support, but for the moment - bigger fish to fry. 👍🏼

maaad commented 1 year ago

Get binary from https://github.com/AlexxIT/go2rtc

/etc/systemd/system/go2rtc.service 
[Unit]
Description=go2rtc
After=network.target

[Service]
Type=simple
ExecStart=/usr/local/bin/go2rtc_linux_arm -config /etc/go2rtc.yaml
ExecReload=/bin/kill -HUP $MAINPID
Restart=always
StandardOutput=syslog
StandardError=syslog
SyslogIdentifier=go2rtc
User=root
Group=root
Environment=PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/bin

[Install]
WantedBy=multi-user.target
/etc/go2rtc.yaml 
streams:
  cam:
    - rtsp://

Then add HTTP Page Camera and set Camera Url to http://:1984/webrtc.html?src=cam

pedrolamas commented 1 year ago

Right now, the best option for camera management is probably using Crowsnest!