Notices


Reply
Thread Tools
Posts: 1,378 | Thanked: 1,604 times | Joined on Jun 2010 @ Göteborg, Sweden
#61
Would be nice if this could read mjpeg format :-)
 
Copernicus's Avatar
Posts: 1,986 | Thanked: 7,698 times | Joined on Dec 2010 @ Dayton, Ohio
#62
Originally Posted by handaxe View Post
Would be nice if this could read mjpeg format :-)
Well, back in the old, old days, webcams only provided a single image at a time. I suppose I could put in some support for video, though, as I've already got animated gifs supported. Let me take a look...
 

The Following 3 Users Say Thank You to Copernicus For This Useful Post:
Posts: 1,378 | Thanked: 1,604 times | Joined on Jun 2010 @ Göteborg, Sweden
#63
Originally Posted by Copernicus View Post
Well, back in the old, old days, webcams only provided a single image at a time. I suppose I could put in some support for video, though, as I've already got animated gifs supported. Let me take a look...
Bump.... (I feel so guilty doing this:-)
 

The Following User Says Thank You to handaxe For This Useful Post:
Copernicus's Avatar
Posts: 1,986 | Thanked: 7,698 times | Joined on Dec 2010 @ Dayton, Ohio
#64
Originally Posted by handaxe View Post
Bump.... (I feel so guilty doing this:-)
Let me take another look. (I'm starting to get some real work done again...)

EDIT: BTW, can you give me an example of a webcam you'd like to see supported? A lot of the streaming webcams today aren't actually using mjpeg (and are probably using closed formats that I won't be able to support)...

Last edited by Copernicus; 2015-05-18 at 18:07. Reason: Need more info
 

The Following 2 Users Say Thank You to Copernicus For This Useful Post:
Posts: 1,378 | Thanked: 1,604 times | Joined on Jun 2010 @ Göteborg, Sweden
#65
Originally Posted by Copernicus View Post
EDIT: BTW, can you give me an example of a webcam you'd like to see supported? A lot of the streaming webcams today aren't actually using mjpeg (and are probably using closed formats that I won't be able to support)...
I was wanting to access the mjpeg output of motion (a version is compiled for the n900 / fremantle).

But really, this is not essential....
 

The Following User Says Thank You to handaxe For This Useful Post:
Copernicus's Avatar
Posts: 1,986 | Thanked: 7,698 times | Joined on Dec 2010 @ Dayton, Ohio
#66
Originally Posted by handaxe View Post
I was wanting to access the mjpeg output of motion (a version is compiled for the n900 / fremantle).
Just a quick FYI: Motion appears to support the ability to work like a classic snapshot webcam, so you may already be able to use it with Fettuccine. But I'll see if I can add mjpeg support as well.
 

The Following 2 Users Say Thank You to Copernicus For This Useful Post:
Posts: 1,378 | Thanked: 1,604 times | Joined on Jun 2010 @ Göteborg, Sweden
#67
Originally Posted by Copernicus View Post
Just a quick FYI: Motion appears to support the ability to work like a classic snapshot webcam, so you may already be able to use it with Fettuccine. But I'll see if I can add mjpeg support as well.
Indeed it does. And a useful reminder (I now remember why I chose not to go this way).

I have motion producing mjpegs at a fairly high frame-rate so that when I wish, I can use VLC and view near real-time video-style feed. So sampling the mjpegs at a chosen interval would be a good n900 option for me.
 

The Following 2 Users Say Thank You to handaxe For This Useful Post:
Copernicus's Avatar
Posts: 1,986 | Thanked: 7,698 times | Joined on Dec 2010 @ Dayton, Ohio
#68
Ok, version 0.9.4 of Fettuccine is now making its way up to extras-devel. This version provides (initial) support for MJpeg streaming webcams; I've finally picked up some info on how MJpeg works, and have been able to pull images out of the few webcams that I've tested. So far things look good, so I thought I'd go ahead and push up this update, even though I suspect that there may still be varieties of MJpeg webcam that I'm not supporting properly.

Fettuccine does not (yet) have the ability to automagically detect whether a webcam is providing still images or an MJpeg stream; so, I've added a new parameter to the XML format, the "webcamType":

Code:
 <webcam
  link="http://76.10.86.11/mjpg/video.mjpg?camera=1"
  webcamType="MJpeg"
  homepage="http://76.10.86.11"
  refreshRate="1">
  <name>Devils Lake, North Dakota</name>
 </webcam>
Right now, the only values supported are "Static" (for still images) or "MJpeg" (for MJpeg streaming). This parameter is optional; if you don't include it in the webcam specification, it will default to "Static".

Also by default, Fettuccine will simply grab the current image from the stream and display it. If you'd like to instead collect a short sequence of images and loop them, there are two more new parameters, "maxImages" and "slideshowDelay":

Code:
 <webcam
  link="http://216.8.159.21/mjpg/video.mjpg"
  webcamType="MJpeg"
  maxImages="10"
  slideshowDelay="1"
  homepage="http://216.8.159.21"
  refreshRate="30">
  <name>Detroit - Windsor Tunnel</name>
 </webcam>
As you might expect, the "maxImages" parameter defines how many images to retrieve, and the "slideshowDelay" parameter defines how long to pause (in seconds) between each image as the slideshow is being displayed. New slideshows will be downloaded at the refresh rate.

Enjoy! And please inform me of bugs. Thanks.
 

The Following 4 Users Say Thank You to Copernicus For This Useful Post:
Posts: 1,378 | Thanked: 1,604 times | Joined on Jun 2010 @ Göteborg, Sweden
#69
This is working for me, with output from motion. Thank you. I will check properly when daylight arrives.

One thing, is there a way to pause the widget - that is to suspend the refreshing until re-enabled?
 

The Following User Says Thank You to handaxe For This Useful Post:
Copernicus's Avatar
Posts: 1,986 | Thanked: 7,698 times | Joined on Dec 2010 @ Dayton, Ohio
#70
Originally Posted by handaxe View Post
One thing, is there a way to pause the widget - that is to suspend the refreshing until re-enabled?
Ah, good question! I should be able to implement something like that without too much trouble. Let me give it a try.

BTW, I should also say that I've been doing some more testing; I originally assumed that I should avoid just displaying the entire stream full-blast, to avoid consuming all network and CPU bandwidth. But, I've been testing an instance of Fettuccine displaying a mjpeg webcam as fast as the data comes in, and the N900 is holding up fine. (It's getting a little warm after over a half hour of constant use, but so far it doesn't seem dangerously hot.) So, here's another question -- is there any value to not displaying a streaming webcam at full speed?

(I've gotta admit, it's also quite nice to watch the stream running on the task manager screen; the video libraries I've been using in my other apps use rather ugly tricks to optimize the speed with which they send data to XWindows, which normally break down when you open up the task manager. Fettuccine, on the other hand, is simply redrawing an image over and over again... )
Attached Images
 
 
Reply

Tags
webcam


 
Forum Jump


All times are GMT. The time now is 17:04.