-
Notifications
You must be signed in to change notification settings - Fork 82
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Event stream.on is never fired #5
Comments
Hello! Can you send me full demo example? And what did you mean when you said about 'on' event of the stream object? |
Thanks for your response. I'm using your server example as is. No change but the urls for the streams. |
Do you mean that when you change sources to your ip-cams nothing works? |
Whether I change it or not. Is the same. The event that never get fired is the data instead of the on I wrote. |
Oh, now I understand. Are you sure that this is wright rstp stream? Try to check it with vlc and ffmpeg with corresponding params |
This url I open it in VLC with no problem: rtsp://192.168.1.48:554/profile1 |
This is my code:
|
Are you're sure that rtsp://192.168.1.48:554/profile1 is pure rtsp stream that can be processed with ffmpeg? |
How do you advise me to check that? That URL I open in VLC with no problem. |
In fact, if I just open rtsp://192.168.1.48 in VLC, it also works. But not with the code. |
And what is the result of |
This was the result:
|
Seems that it is failure with your rtsp stream. Just try to fix them with different ffmpeg arguments that you can later pass to the consturtuctor of rtsr.FFMpeg as an argument |
Thank you very much anyway. Can I ask your ffmpeg version? Apparently there are some issues with the latest versions. |
Hi. Finally this command worked for me to get a snapshot:
How can I translate that to rtsp-ffmpeg? Thank you very very much. |
Oh, this is simple, just look at https://github.com/agsh/rtsp-ffmpeg/blob/master/lib/rtsp-ffmpeg.js#L74 add all missing arguments in array in style of |
Hi. One last time. ¿Like this?
|
And one more thing. I need the |
Ok, I'll fix it in the next few days |
Moved additional options to be first in the list of arguments. You can try either npm version or github master branch. var uri = 'rtsp://192.168.1.48:554/profile1';
var stream = new rtsp.FFMpeg({input: uri, arguments: ['-rtsp_transport', 'tcp', '-map', '0:0', '-frames', '1']}); Please try this and comment what happens. |
Hi agsh, thank you for your interest. I still can't get the snapshot, or the streaming for my camera, with your updated code. Let me show you the log when I invoke ffmpeg in the console. Perhaps that can help:
|
I just tried something. Apparently not all optional parameters belongs at the beginning. For what I have read, the order in what the parameters appear instructs ffmpeg to apply them to the input or to the output. So, in my case, |
Hi, I'm trying to run your server example. Whether I left the URLs unchanged or if I change it to my cameras streams, the socket events fire up as expected, but not the On event of the Stream object. Can you help me pls? My cameras URL are like this: rtsp://192.168.1.48:554/profile1. Thank you.
The text was updated successfully, but these errors were encountered: