Search questions:

 

Browse by Category:

 
How can I stream my webcam onto my website?
Printer friendly page
Views: 1
Votes: 11
Best selling ebooks:


There are several methods to do this. One of them is to constantly upload captured image to the website and then just to refresh the picture of the website using JavaScript.

The second one is better because it saves bandwidth and time - to run your own web cam server. The following applications support both methods.

Dorgem is good free program that can be used for image capturing. It will slow down while uploading the image, but the overall performance is excellent.



Start the programs and adjust your website settings: username, password, directory - where the images will be uploaded. Set the captured image name to image.jpg. Also you may fine tune the update time of the upload for example 2 or 10 seconds.

The following is a code that you must place in your webpage:

<img id="webcam" src="image.jpg">
<p>Refresh Interval(seconds): 5</p>


<script language="JavaScript" type="text/javascript">
setInterval('document.getElementById(\'webcam\').src=\'image.jpg?l=\'+(new Date).getTime()',5*1000);
</script>


Replace 5*1000 with any number you would like to refresh the client web page.

5*1000=5 seconds.

Click Start or Capture now watch and enjoy!

Last update: 04:58 PM Tuesday, December 11, 2007

 



Related Questions: