I tried got video stream on the rtsp with use MEAN stack, but when I added this code in my server.js file, I caught the error: "spawn ffmpeg ENOENT". Maybe I forgot to install some lib or what? please help me! Code:
app.get('/', function (req, res) {
Stream = require('node-rtsp-stream');
stream = new Stream({
name: 'name',
streamUrl: 'rtsp://184.72.239.149/vod/mp4:BigBuckBunny_115k.mov',
wsPort: 9999
});
res.send(stream);
console.log('9999')
});
Well, you need to install FFmpeg on your Ubuntu machine first.
sudo apt install FFmpeg
This will install the newest version, Also I see you're trying to send the stream as a response. The module you are using to get your RTSP feed converts it to a WebSocket connection. So you need to make a client connect to it.
Hope this helped!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With