Page 1 of 1

VLC Media Player and Remote Cam

Posted: Sun Apr 03, 2005 4:51 pm
by themutt
VLC Media Player will stream using the mjpg codec, various encapsulations including mpeg, asf, raw and can use protocols such as http from a given URL:port etc. Is there a way to make ZM 1.20.1 catch a remote stream from VLC? Or is setting up ZM to stream from the remote site the only approach. Am using Mandrake 10.1, KDE 3.4, 2.6.11 kernel and YC72 webcam using the konicawc kernel module. The webcam works fine locally with ZM and also when streaming remotely using VLC as the viewer (as well as the stream generator). Have tried a number of codecs. encapsulation methods and protocols with VLC but have not been able to catch the stream with ZM using "Remote Host Name" 192.168.XXX.XXX and "Remote Host Port" say 3000, but no entry for "Remote Host Path". VLC can stream on any port, firewall isn't an issue since the setup works with VLC as the viewer. Any help appreciated.

Posted: Sun Apr 03, 2005 7:52 pm
by zoneminder
Do you have any links to the documentation anywhere? Otherwise you may just have to 'wget' the various media types and see if any come down as mpjpeg or jpeg format.

Phil

Posted: Mon Apr 18, 2005 7:01 pm
by themutt
Looking at VLC streaming features indicates the svn version of VLC can stream mpmjpeg, believe this is mpjpeg, via http.
http://www.videolan.org/streaming/features.html

Additional docs and streaming howto.
http://www.videolan.org/doc/
http://www.videolan.org/doc/streaming-h ... owto-en.ht

I was able to compile the svn version and using the following command string ./vlc -vvv v4l:/dev/video0 --sout '#transcode{vcodec=mjpg,vb=1024,width=320,height=240}:standard{access=http,mux=mpjpeg,url=myserverip:myport}'
was able to stream to zoneminder using knetload to monitor the stream but zoneminder was unable to display video. The VLC server side showed zoneminder was connecting repeatedly. Knetload showed what appeared to be a video stream to the ZM client but no picture. I was able to capture the stream with VLC as a client so possibly the format is slightly different or ZM didn't capture the stream correctly. Have run out of ideas if you want to give it a try.

Capturing streaming from VLC

Posted: Fri Jun 10, 2005 9:19 pm
by lgmoltrasio
Do you get the answer? I need somethig like this...

Thanks

Re: Capturing streaming from VLC

Posted: Tue Jun 13, 2006 7:58 am
by DarkBear
lgmoltrasio wrote:Do you get the answer? I need somethig like this...

Thanks
Here is my patch for VLC plugin (libmux_mpjpeg_plugin.dll) to work correctly with ZM.
diff -urN ./original/mpjpeg.c ./patched/mpjpeg.c
--- ./original/mpjpeg.c 2006-06-08 02:00:50.000000000 +0400
+++ ./patched/mpjpeg.c 2006-06-13 08:39:46.000000000 +0400
@@ -191,9 +191,9 @@
char *psz_separator = var_CreateGetString( p_mux,
SOUT_CFG_PREFIX "separator" );
char *psz_separator_block = (char *)malloc( strlen( psz_separator ) +
- 2 + strlen( CONTENT_TYPE ) );
+ 2 + strlen( CONTENT_TYPE ) + 2 + 2);

- sprintf( psz_separator_block, "%s\r\n%s\r\n", psz_separator,
+ sprintf( psz_separator_block, "%s\r\n%s\r\n\r\n", psz_separator,
CONTENT_TYPE );

p_header = block_New( p_mux, strlen( psz_separator_block ) );
Sample command string for Logitech USB QuickCam on Win2000.
./vlc.exe -I rc dshow:// --dshow-vdev="Logitech QuickCam Messenger" --dshow-adev="none" --dshow-size="640x480" --dshow-fps="5.000" --sout-http-mime="multipart/x-mixed-replace;boundary=ZoneMinderFrame" --sout-mpjpeg-separator="--ZoneMinderFrame" --no-sout-audio --sout=#transcode{vcodec=MJPG,vb=1024,scale=1}:duplicate{dst=std{access=http,mux=mpjpeg,dst=:8050/thestream}}

I test vlc-0.8.5 & vlc-0.8.6 with ZM v1.22.2.
Options - ZM_NETCAM_REGEXPS checked, ZM_HTTP_VERSION 1.0

It Work! :D

Posted: Tue Jun 13, 2006 9:30 am
by zoneminder
Very useful I'm sure. Thanks for posting this.

ZoneMinder + VideoLan as a IP CAM

Posted: Fri Jul 18, 2008 2:26 am
by bonesbr
Hi, i'ved installed a Slackware 12.1 kernel 2.6.24 with zoneminder 1.23.3 runing four cams localy using bt878 chipset , and works great.
On another computer , i'ved installed s Slackware 12.1 kernel 2.6.24 with VideoLan Client vlc-0.8.5-i686.tgz acting as mpjeg streaming server on IP 192.168.0.253:8080/GetData.cgi. With vlc client i can get the streaming runing , in color and a hight fps. But when i configure a new IP CAM on ZoneMinder , with this same data , Zone Minder show to me a black screen in place of image .
I think was my problem is the same of this post, but i do not understood how i can patch my system in way to put things to work.

-- i'ved tried set this:
Options - ZM_NETCAM_REGEXPS checked, ZM_HTTP_VERSION 1.0 , and still nothing .

Can anyone help me ?

More info

Posted: Fri Jul 18, 2008 12:13 pm
by bonesbr
Hi ,

I'ved just make another test : I downloaded the Motion JPEG Player from http://gmax.gpnet.at/mjpg.html , and when i try http://192.168.0.253:8080/GetData.cgi , works really great(1023.24kbps/30fps/on collor). Only on ZoneMinder i get no frames (0 fps) , and still a black screen on camera place. Zoneminder can detect the stream , because the IP on Console goes green , but no images.
Maybe is a bug from ZoneMinder ? If i can contribute , please tell me how. ZoneMinder is a really good program , and i really want to implement my factory CFTV system with this.
Thanks.

more deep

Posted: Tue Jul 29, 2008 11:47 pm
by bonesbr
well, the problem is , the vlc encoder has a problem, and, firefox don't show up the images and sometimes crashes.
So, if anyone can patch this , please tell me how.

tks

Posted: Wed Jul 30, 2008 6:55 pm
by jameswilson
check you logs, also this is old thread for an old version.
You might be getting shmget errors

Posted: Wed Jul 30, 2008 7:01 pm
by cordel
If vlc is having a problem, you would need to take it to vlc's developers to fix.
Are you sure you are building vlc up with the right codecs correctly and you have correctly patched vlc before the build?

Posted: Wed Jul 30, 2008 8:08 pm
by bonesbr
Hi, thanks for your attention.
Yes , i got contact with the vlc developers by mirc , and they are working to fix this .
But i has solved this problem using another zoneminder instaled acting as streaming server , and works really good.
Thanks to the developers of zoneminder , this software is really best!
if anyone wants to do the same , here is the topic that i was followed : http://www.zoneminder.com/forums/viewtopic.php?t=5549

---

regards from Brasil.[/quote]

Follow Up:

Posted: Thu Jun 10, 2010 2:58 pm
by rbliss
Wanted to say that streaming vlc as mpjpeg didnt work for me specifying the content/type;boundary...

so i finally changed the command:

vlc.exe dshow:// --dshow-vdev="Logitech QuickCam Pro 4000" --dshow-adev="none" --dshow-size="640x480" --dshow-fps="5.000" --sout-mpjpeg-separator="--ZoneMinderFrame" --no-sout-audio --sout=#transcode{vcodec=MJPG,vb=1024,scale=1}:duplicate{dst=std{access=http,mux=mpjpeg,dst=:8080/test.mpjpeg}}

and that worked for me.

vlc 1.0.5 winx86
zm: 1.24.2

Posted: Tue Jun 22, 2010 11:53 am
by neji
Meet the world on time,visit trustdownloads get wat you want from - VLC Media Player

Posted: Sat Oct 23, 2010 7:15 pm
by KajolThappar1
I think was my problem is the same of this post, but i do not understood how i can patch my system in way to put things to work.Is there any one from Crezh bought from Chinabuye?