Send Motion-user mailing list submissions to
        motion-user@lists.sourceforge.net

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.sourceforge.net/lists/listinfo/motion-user
or, via email, send a message with subject or body 'help' to
        motion-user-requ...@lists.sourceforge.net

You can reach the person managing the list at
        motion-user-ow...@lists.sourceforge.net

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Motion-user digest..."


Today's Topics:

   1. Grabbing a single frame (David Powell)
   2. Re: Grabbing a single frame (Eric Mansfield)
   3. Re: Grabbing a single frame (David Powell)


----------------------------------------------------------------------

Message: 1
Date: Fri, 16 Nov 2018 15:04:13 -0600
From: David Powell <da...@depowell.com>
To: Motion discussion list <Motion-user@lists.sourceforge.net>
Subject: [Motion-user] Grabbing a single frame
Message-ID: <13c4f366-298f-486b-031c-a54c34132...@depowell.com>
Content-Type: text/plain; charset="utf-8"; Format="flowed"

Hi everyone.? I have a need to be able to grab a single frame from a 
specific camera stream and display it in the browser.? Many moons ago I 
used a program that Kenneth Laversen wrote called /nph-mjgrab/. It 
worked great and was simple to set up and use.

Several years went by and I lost interest in the whole camera setup, but 
now I am back into it and need this functionality again.? I found the 
*nph-mjgrab* program on the old /motion/ web site but I can't for the 
life of me get it to work.? Does anyone else use this? Does the current 
/motion/ still support it?? Is there a better way to grab a single frame 
from a camera stream?

Thanks, David

-------------- next part --------------
An HTML attachment was scrubbed...

------------------------------

Message: 2
Date: Fri, 16 Nov 2018 16:59:54 -0700
From: Eric Mansfield <ericman...@gmail.com>
To: motion-user@lists.sourceforge.net
Subject: Re: [Motion-user] Grabbing a single frame
Message-ID:
        <CAG5KSp6j12OWAEYpwETBEmfaiebDgnb3oBwhs=lundxe0r6...@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

I searched and could not find a way to do this from within motion, but I'm
not an expert. Since I am using a node.js environment, I eventually came
across the mjpeg-camera library (https://www.npmjs.com/package/mjpeg-camera)
which can capture a single jpeg image from a mjpeg stream. You could use
the library's stand-alone server or integrate it into a simple node.js
express server, for example. Perhaps not as quick and easy to setup as you
hoped, but it has worked for me.

Eric

On Fri, Nov 16, 2018 at 2:05 PM David Powell <da...@depowell.com> wrote:

> Hi everyone.  I have a need to be able to grab a single frame from a
> specific camera stream and display it in the browser.  Many moons ago I
> used a program that Kenneth Laversen wrote called *nph-mjgrab*. It worked
> great and was simple to set up and use.
>
> Several years went by and I lost interest in the whole camera setup, but
> now I am back into it and need this functionality again.  I found the
> *nph-mjgrab* program on the old *motion* web site but I can't for the
> life of me get it to work.  Does anyone else use this? Does the current
> *motion* still support it?  Is there a better way to grab a single frame
> from a camera stream?
>
> Thanks, David
> _______________________________________________
> Motion-user mailing list
> Motion-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/motion-user
> https://motion-project.github.io/
>
> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
-------------- next part --------------
An HTML attachment was scrubbed...

------------------------------

Message: 3
Date: Fri, 16 Nov 2018 20:45:33 -0600
From: David Powell <da...@depowell.com>
To: Motion discussion list <motion-user@lists.sourceforge.net>
Subject: Re: [Motion-user] Grabbing a single frame
Message-ID: <f2a2a7e5-1026-b41c-62d4-0066c4e6b...@depowell.com>
Content-Type: text/plain; charset="utf-8"; Format="flowed"

Thanks, but this setup is already becoming a beast with many arms, I 
don't really want to add a whole 'nother infrastructure like Node.js.? I 
have Motion running on a Pi with 3 network cameras (more to be added 
later), mySQL, Apache2, and a lot of my own custom Java and HTML code to 
handle the presentation.? It gives a summary page of the last two weeks 
for each camera, which is clickable by day to show snapshots for that 
day. All of the snapshots are also clickable to see the movie that goes 
with the snapshot.? Hovering over any snapshot with your mouse pops up a 
tooltip showing the time, date, and length of the movie in seconds.

I could show a live stream from all cameras on the summary page, but I 
can't afford the bandwidth and it's not logically necessary. I'd rather 
show a snapshot of each one and update them every few seconds with 
javascript. Each snapshot is clickable, showing the live stream in a 
pop-up page when clicked.

Apparently it's possible to get a live stream from Motion also on port 
8081, no matter what port you have configured as the base port.? The URL 
is something like /http://motion-server:8081/*1*/stream/ for camera 
#*1*. I can't find anything about this in the documentation; I found it 
by examining the new configuration console (ver. 4.1.1).? I'm wondering 
if there is (or could be!) a similar URL to fetch a snapshot.? That 
would be perfect!

As it is, the simple /nph-mjgrab/ program would be all I need, if I 
could get it to work. It just hangs when executed, both manually and via 
Apache2. I have to kill the process ID to get rid of it.? I'll probably 
try to debug it, but C is not my strongest language.? If I can't figure 
it out, maybe I'll add some Java code to my existing program to give me 
the snapshot functionality.

David


On 11/16/18 5:59 PM, Eric Mansfield wrote:
> I searched and could not find a way to do this from within motion, but 
> I'm not an expert. Since I am using a node.js environment, I 
> eventually came across the mjpeg-camera library 
> (https://www.npmjs.com/package/mjpeg-camera) which can capture a 
> single jpeg image from a mjpeg stream. You could use the library's 
> stand-alone server or integrate it into a simple node.js express 
> server, for example. Perhaps not as quick and easy to setup as you 
> hoped, but it has worked for me.
>
> Eric
>
> On Fri, Nov 16, 2018 at 2:05 PM David Powell <da...@depowell.com 
> <mailto:da...@depowell.com>> wrote:
>
>     Hi everyone.? I have a need to be able to grab a single frame from
>     a specific camera stream and display it in the browser.? Many
>     moons ago I used a program that Kenneth Laversen wrote called
>     /nph-mjgrab/. It worked great and was simple to set up and use.
>
>     Several years went by and I lost interest in the whole camera
>     setup, but now I am back into it and need this functionality
>     again.? I found the *nph-mjgrab* program on the old /motion/ web
>     site but I can't for the life of me get it to work.? Does anyone
>     else use this? Does the current /motion/ still support it?? Is
>     there a better way to grab a single frame from a camera stream?
>
>     Thanks, David
>
>     _______________________________________________
>     Motion-user mailing list
>     Motion-user@lists.sourceforge.net
>     <mailto:Motion-user@lists.sourceforge.net>
>     https://lists.sourceforge.net/lists/listinfo/motion-user
>     https://motion-project.github.io/
>
>     Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
>
>
>
> _______________________________________________
> Motion-user mailing list
> Motion-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/motion-user
> https://motion-project.github.io/
>
> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
-------------- next part --------------
An HTML attachment was scrubbed...

------------------------------



------------------------------

Subject: Digest Footer

_______________________________________________
Motion-user mailing list
Motion-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/motion-user


------------------------------

End of Motion-user Digest, Vol 149, Issue 18
********************************************

Reply via email to