stream local webcam directly to webpage

All you've ever wanted to know about the ActiveX, Mozilla plugins, the web interface and various PHP extensions
Jyske Web
New Cone
New Cone
Posts: 9
Joined: 26 Aug 2010 12:49

stream local webcam directly to webpage

Postby Jyske Web » 08 Nov 2010 14:58

Hello VLC Experts,

I want to know how to save local and IP webcam stream as file on PC or server. Or better stream local webcam directly to webpage so that
all on the internet can se the webcam.

But how to do that??

I have search and search in the VLC topics and haven't found the answer.

1) On my webform (.aspx) I have a <object> where Id="vlc1" that embed the VLC plugin.
2) On the html boby I call a javascript funtion like this: <body onload="play();">
3) Here is the java function:
<script type="text/javascript">
function play() {
var vlc = document.getElementById("vlc1");
var mrl = "http://camcure.myipcamera.com:1024/img/video.asf"; //my IP camera
var options = new Array(":dshow-size=320*240", ":sout=#transcode{vcodec=DIV3,vb=256,scale=1,acodec=asf,ab=32,soverlay}:duplicate{dst=display, dst=std{access=file,mux=ogg,dst=\"c:\\testing.ogg\"}}");

vlc.playlist.playItem(vlc.playlist.add(mrl, null, options));
vlc.playlist.play();
}
</script>

What am I do wrong ?? I have spent 4 weeks to find out....and I am so confused (and tired)......

Please help me experts - thx. a lot!!

Best regards and sorry about my english !
Ole - a developer
from litte Denmark

rogerdpack
Big Cone-huna
Big Cone-huna
Posts: 574
Joined: 19 Jul 2008 23:48
Operating System: windows

Re: stream local webcam directly to webpage

Postby rogerdpack » 18 Nov 2010 20:59

to stream to two places use the "duplicate" parameter of sout
does the url "http://camcure.myipcamera.com:1024/img/video.asf" work as expected?


Return to “Web and scripting”

Who is online

Users browsing this forum: No registered users and 1 guest