mpromonet / webrtc-streamer

WebRTC streamer for V4L2 capture devices, RTSP sources and Screen Capture
https://webrtcstreamer.agreeabletree-365b9a90.canadacentral.azurecontainerapps.io/?layout=2x2
The Unlicense
2.8k stars 581 forks source link

rtsp video stream cannot be played #677

Closed yikexiaoshu1 closed 2 months ago

yikexiaoshu1 commented 3 months ago

Hello, I used VLC to simulate an rtsp video stream, such as rtsp://172.16.50.12:8554/v. I installed webrtc-streamer in window and linux and played the rtsp video stream through webrtcstreamer.html. The webrtc-streamer will report an error. Error content: Failed to SETUP: 461 Unsupported transport Failed to SETUP: 461 Unsupported transport Failed to PLAY: No RTSP session is currently in progress.

How should I solve it? Thank you.

yikexiaoshu1 commented 3 months ago

In VLC test RTSP address can be played normally

mpromonet commented 3 months ago

Hi, By default, it use rtp over TCP. Best Regards Michel

yikexiaoshu1 commented 3 months ago

Hello, I don’t understand what you mean. Can you explain it in detail?How can I set it up to play rtsp video stream?

mpromonet commented 3 months ago

Hi @yikexiaoshu1,

The default options are defined in https://github.com/mpromonet/webrtc-streamer-html/blob/f27dc4ca97aab57ce1f85589983f867a197a70cd/webrtcconfig.js, then options: "rtptransport=tcp&timeout=60",

You could overide it adding in url /webrtcstreamer.html?video=.....&options= or /webrtcstreamer.html?video=.....&options=rtptransport%3Dudp

Best Regards, Michel.