local video file

Forum for questions and support relating to the 1.28.x releases only.
Locked
iomari
Posts: 4
Joined: Mon Apr 27, 2015 11:47 am

local video file

Post by iomari »

Greetings,
I just getting my feet wet with zoneminder. I've set up a local file as source but I can't seem o get it to display. Can someone give me the steps to achieve this? The local file is a standard mpg file. Just for testing.
User avatar
asker
Posts: 1553
Joined: Sun Mar 01, 2015 12:12 pm

Re: local video file

Post by asker »

iomari wrote:Greetings,
I just getting my feet wet with zoneminder. I've set up a local file as source but I can't seem o get it to display. Can someone give me the steps to achieve this? The local file is a standard mpg file. Just for testing.
If you are using source type as file, you need to point it to an image file not a video file
http://www.zoneminder.com/wiki/index.ph ... ly_support
I no longer work on zmNinja, zmeventnotification, pyzm or mlapi. I may respond on occasion based on my available time/interest.

Please read before posting:
How to set up logging properly
How to troubleshoot and report - ES
How to troubleshoot and report - zmNinja
ES docs
zmNinja docs
iomari
Posts: 4
Joined: Mon Apr 27, 2015 11:47 am

Re: local video file

Post by iomari »

Thanks
mikb
Posts: 595
Joined: Mon Mar 25, 2013 12:34 pm

Re: local video file

Post by mikb »

If you really want to test it with a VIDEO file (for testing motion detection on a pre-recorded, predictable file), as it appears you might be doing, try this :-

I got an "mjpeg" stream from my camera into a file, and although it wasn't viewable in XINE/VLC, I used

ffmpeg -r 5 -i input.mjpeg -f avi -q:v 5 -vtag XVID -g 60 -bf 2 output.avi

to get a compliant file to look at it (output.avi)

Then I set up a new monitor called "FileTest" with Source type: FFMPEG and FPS set to 5/5 to control rate to match camera (or 25/25 to test at faster than real time) and pointed it at "input.mjpeg"

When camera is set to "monitor" or "modetect", input is processed as if it is from a camera. Return to "none" to reset and try again.

I used this with ZM when I first set it up -- having recorded a chunk of video from various cameras with a range from "known nothing" "known nothing much important" "borderline motion can u see it?" "this is motion!!" etc. examples in, makes the tuning easier if you already know the answers :)
User avatar
asker
Posts: 1553
Joined: Sun Mar 01, 2015 12:12 pm

Re: local video file

Post by asker »

That's a nice idea mikb.
mikb wrote:If you really want to test it with a VIDEO file (for testing motion detection on a pre-recorded, predictable file), as it appears you might be doing, try this :-

I got an "mjpeg" stream from my camera into a file, and although it wasn't viewable in XINE/VLC, I used

ffmpeg -r 5 -i input.mjpeg -f avi -q:v 5 -vtag XVID -g 60 -bf 2 output.avi

to get a compliant file to look at it (output.avi)

Then I set up a new monitor called "FileTest" with Source type: FFMPEG and FPS set to 5/5 to control rate to match camera (or 25/25 to test at faster than real time) and pointed it at "input.mjpeg"

When camera is set to "monitor" or "modetect", input is processed as if it is from a camera. Return to "none" to reset and try again.

I used this with ZM when I first set it up -- having recorded a chunk of video from various cameras with a range from "known nothing" "known nothing much important" "borderline motion can u see it?" "this is motion!!" etc. examples in, makes the tuning easier if you already know the answers :)
I no longer work on zmNinja, zmeventnotification, pyzm or mlapi. I may respond on occasion based on my available time/interest.

Please read before posting:
How to set up logging properly
How to troubleshoot and report - ES
How to troubleshoot and report - zmNinja
ES docs
zmNinja docs
Locked