Creating videos with ffmpeg when FPS is below 25
-
- Posts: 5111
- Joined: Wed Jun 08, 2005 8:07 pm
- Location: Midlands UK
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
-
- Posts: 5111
- Joined: Wed Jun 08, 2005 8:07 pm
- Location: Midlands UK
Hi Phil.
I tried to follow your instruction, and modified the zmvideo.pl accordingly:
my $command = ZM_PATH_FFMPEG." -y ".ZM_FFMPEG_OPTIONS." -r $frame_rate -s ${width}x${height} -i %0".ZM_EVENT_IMAGE_DIGITS."d-capture.jpg -r 25 $video_file > mpeg.log";
The live streaming videos are still not working (as they always do ).
Update: Well, just learned a new bit - all the online video is generated via zmMonitor, StreamMPEG function. Phil, if you made there any small change that caused the live streaming to finally work, could you please post this small piece of code?
I tried to follow your instruction, and modified the zmvideo.pl accordingly:
my $command = ZM_PATH_FFMPEG." -y ".ZM_FFMPEG_OPTIONS." -r $frame_rate -s ${width}x${height} -i %0".ZM_EVENT_IMAGE_DIGITS."d-capture.jpg -r 25 $video_file > mpeg.log";
The live streaming videos are still not working (as they always do ).
Update: Well, just learned a new bit - all the online video is generated via zmMonitor, StreamMPEG function. Phil, if you made there any small change that caused the live streaming to finally work, could you please post this small piece of code?
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
Hi Phil.
Well, I'm always (as long as I can remember using ZM) getting a black screen when trying to view a live (or playback - not the generated, this works fine) video. The WMP I have tried (both 9 and 10) are simply not able to display the stream, and even doesn't start buffering it. Tried from many XP computers, both with SP1 and SP2.
I will gladly install the CVS version and apply your changes, if it will finally solve the situation.
My current version of FFMPEG is the one distributed with FC4 (0.4.9-0.2.20050427).
Well, I'm always (as long as I can remember using ZM) getting a black screen when trying to view a live (or playback - not the generated, this works fine) video. The WMP I have tried (both 9 and 10) are simply not able to display the stream, and even doesn't start buffering it. Tried from many XP computers, both with SP1 and SP2.
I will gladly install the CVS version and apply your changes, if it will finally solve the situation.
My current version of FFMPEG is the one distributed with FC4 (0.4.9-0.2.20050427).
I have been successfuly running 0.4.8 since I started using zm (well I think it was 0.4.7 or a bit earlier but I stopped at . with out any issues up till recently (maybe my own fault ) but it stills works for both streaming and generation. Although I oppsed and had tried to build on cvs some time back and forgot that the shared libs were still installed (till last month) so every time I built zm appearently it used the CVS version of the libaries
My box that I religh on for watching my driveway had the same thing (since I installed there for testing and made the same mistake. Some how it still worked [scratching head]
Now if I remove the ffmpeg libs from CVS install of coarse it breaks, even though the 0.4.8 libs are there. I tried to rebuild zm on the old Libaries and keep getting errors about ffmpeg and some undefined calls.
I'll get the build enviroment back up and try rebuilding with 0.4.8 and when Phil makes his release work on the CVS version (I downloaded from CVS shortly after Phil) I'll get them both packaged up and have it all available for DL.
Regards,
Cordel
My box that I religh on for watching my driveway had the same thing (since I installed there for testing and made the same mistake. Some how it still worked [scratching head]
Now if I remove the ffmpeg libs from CVS install of coarse it breaks, even though the 0.4.8 libs are there. I tried to rebuild zm on the old Libaries and keep getting errors about ffmpeg and some undefined calls.
I'll get the build enviroment back up and try rebuilding with 0.4.8 and when Phil makes his release work on the CVS version (I downloaded from CVS shortly after Phil) I'll get them both packaged up and have it all available for DL.
Regards,
Cordel
Hi.
Well, I was finally able to stream a video from ZM. There are 2 caveats thought, one is quite large:
1) I had to rollback the FFMPEG to 0.4.8.
2) Most seriously, the Windows Media Player is unable to advance more then the first frame - this is the effect I always had. Today, I got an idea of playing the stream via Classic Media Player, and behold, it all works and streams properly.
This is a serious limitation thought, as it means that you can't use the WMP ActiveX player from within the browser. Moreover, you also can't use the "Montage" feature.
This effect with WMP is seen on version 10 - perhaps with a lesser version it works ok?
Phil, does your development version work with the latest WMP? It probably means that FFMPEG CVS has resolved this issue.
Well, I was finally able to stream a video from ZM. There are 2 caveats thought, one is quite large:
1) I had to rollback the FFMPEG to 0.4.8.
2) Most seriously, the Windows Media Player is unable to advance more then the first frame - this is the effect I always had. Today, I got an idea of playing the stream via Classic Media Player, and behold, it all works and streams properly.
This is a serious limitation thought, as it means that you can't use the WMP ActiveX player from within the browser. Moreover, you also can't use the "Montage" feature.
This effect with WMP is seen on version 10 - perhaps with a lesser version it works ok?
Phil, does your development version work with the latest WMP? It probably means that FFMPEG CVS has resolved this issue.
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact:
For those that are using the FC rpm, I cleaned my enviroment and rebuilt ZM on the correct libraries. I haven't yet had a chance to test it though. I'll load it this evening.
If any one wants to test it it is at:
http://www.computerntelecom.com/pub/lin ... testing/3/
Regards,
Cordel
If any one wants to test it it is at:
http://www.computerntelecom.com/pub/lin ... testing/3/
Regards,
Cordel
Hi.
I discovered why the 0.4.9 version of FFMPEG does not work. Every time the zms tries to start streaming the video, it crashes with the message "Could not open codec", which source is located in zm_mpeg.cpp, line 130. Apparently, the FFMPEG developers have changed the API which broke backwards compatibility.
Phil, you probably aware of this one, and have addressed this in the upcoming version?
I discovered why the 0.4.9 version of FFMPEG does not work. Every time the zms tries to start streaming the video, it crashes with the message "Could not open codec", which source is located in zm_mpeg.cpp, line 130. Apparently, the FFMPEG developers have changed the API which broke backwards compatibility.
Phil, you probably aware of this one, and have addressed this in the upcoming version?
Last edited by SyRenity on Sun Nov 06, 2005 6:50 pm, edited 1 time in total.
- zoneminder
- Site Admin
- Posts: 5215
- Joined: Wed Jul 09, 2003 2:07 pm
- Location: Bristol, UK
- Contact: