How to create a live web cam feed with Webcam32
This section of my website describes how to create a live web
cam feed using Webcam32. You can download a trial version of Webcam32
Webcam32 is available for PCs running Windows 95, 98, NT, 2000,
ME or XP.
Webcam32 is reasonably intuitive to administer and operate on
your PC, and allows you to encode video and sound from your a web
cam and microphone connected to your PC. Webcam32 allows you to
create the following two sources of web cam simultaneously:
- live streaming web cam images with clients connected directly
to your computer's Webcam32 built in streaming application on
a port number that can be defined by the Webcam32 application
- web cam images images that can be transferred to your website
via FTP at an interval defined by the Webcam32 application
The ability to broadcast your web cam simultaneously using both
the methods mentioned above is a real added bonus to the Webcam32
application, and is another reason why many people choose to use
Webcam32 opposed to Windows Media Encoder. The result of broadcasting
your web cam simultaneously using both methods means that people
viewing your web site can choose the viewing medium they desire.
For, example some people with high speed Internet access may choose
to view your live streaming web cam images, wheras someone with
a slower Internet connection could opt to view your web cam images
transferred via FTP.
Webcam32 is fairly resource hungry, so you want a pretty modern
PC if you intend to do other things while broadcasting your live
web cam feed. The minimum specifications posted on the Webcam32
website are 32 Mb RAM, 486 CPU or higher and 4 Mb hard disk space
available. However, I suspect at least a Pentium II or Celeron based
PC is preferable. The output from Webcam32 can be viewed in any
JAVA enabled web browser. It is for this reason why many people
prefer to use Webcam32 opposed to Windows Media Player.
Before creating your live web cam feed get a "fixed domain
presence" on the Internet by using a free service provided
I discuss more about getting a fixed domain presence here.
In the examples below I use wisbey.hopto.org for the
name of my fixed domain name that I have registered with no-ip.com.
Also, before creating your live web cam feed I suggest you examine
your existing configuration to determine if you need to "open"
particular ports on any firewall software you may be running. If
you have a network address translation (NAT) device such as a broadband
Internet you will have to "forward" particular ports to
your computer streaming your live web cam feed. I briefly discuss
configuration of broadband Internet routers here. In the example
below I broadcast from port 8888, so in this case you would want
to ensure that port 8888 is not closed down by your firewall software,
and if you have a broadband Internet router you would want to ensure
that port 8888 is forwarded to the appropriate PC on your local
Configuring and running Webcam32
I will not go into great detail about configuring and running Webcam32
since it is a very simple application to use. I simply want to mention
some important aspects of configuring and running Webcam32 that
may not be obvious at a first glance.
TCP/IP Settings for live web cam feed
The default port number for broadcasting found withinTCP/IP
-> Access is 8888, which I believe is fine and does not need
to be changed. There are some default settings you may wish to change
within TCP/IP -> Server Push part of Webcam32, as the
default values mean that someone viewing your live feed will only
be able to watch you live feed for a certain period of time. In
order to allow viewers to watch your live feed for an inifinite
period of time, you want to change the TCP/IP -> Server Push
settings all to zero (i.e. Maxiumum push interval = 0 Seconds, Maximum
push size = 0 KBytes, Frame delay = 0 mSec).
FTP Settings for FTP web cam feed
The WebCam32 application FTP preferences allows you to set:
- where you want to FTP your image to (i.e. your web hosts FTP
server name, your username and password)
- the name of the image (default is webcam32.jpg)
- the frequency at which the image is sent via FTP to your web
space (I have set to 2 seconds)
You also need to set the image quality size from the Device
-> Format preferences. A reasonable resolution to choose
is 320 x 240, which should result in an image size
of about 8 kbytes.
With an image size of 8 kbytes, a 56 kbit per second modem connection
(7 kbytes per second) cannot quite handle an 8 kbyte image every
second. Hence, why the FTP update frequency should be set to 2 seconds
and NOT 1 second. This way you are catering for people who
only have a 56kbit per second modem connection.
Authoring your web pages to display your web cam feed
The HTML that is listed below in listing 1 is for the FTP version
of the Webcam32 output. The HTML that is listed below in listing
2 is for the live brodcasting version of the Webcam32 output.
Embedding the web cam output : web cam HTML Listing 1 for FTP
The Live Cam is basically an image which is sent via FTP (file
transfer protocol) to my web space every 2 seconds. The HTML required
for the image sent by the WebCam32 application is as follows, and
should be placed where you want the updated image to appear in your
code="JavaCam.class" width="320" height="240">
<param name="interval" value="2">
<param name="url" value=http://www.robertwisbey.com/webcam32.jpg>
In the HTML listing above, the text in bold are values which you
must change in order to match your WebCam32 settings and your web
host settings. The URL, http://www.robertwisbey.com/ should
be replaced with the URL of your web site's default location for
the web page, image, and associated Java applets. The width and
height values must match what you have set in the WebCam32 application.
The interval value must match the frequency value you have set in
the WebCam32 application. Finally the URL http://www.robertwisbey.com/webcam32.jpg
should be replaced with the URL of the image which is sent to your
You will also notice in the HTML that JavaCam.class is
referenced. When you FTP your HTML up to your web space, you will
also need to FTP the associated Java applets, JavaCam.class
and JavaCam.java in the same location as your HTML. You can
down load these files here.
Click here to see the
type of web cam stream that Listing 1 presents in your browser (note:
if my webcam is not running, then the last webcam32.jpg image will
appear and update with the same image every 2 seconds).
Embedding the web cam output - web cam HTML Listing 2
The following is the HTML listing (listing 2) which you would place
in your HTML where you want the image to appear.
<applet code="JavaCamPush.class" codebase="http://wisbey.dnsalias.com:8888/applet"
<param name="URL" value="http://wisbey.dnsalias.com:8888">
<param name="cabbase" value="JavaCamPush.cab">
In the HTML listing above, the text in bold are values which you
must change in order to match your WebCam32 settings and your IP
address or domain alias settings. The address and port number, wisbey.dnsalias.com:8888
should be replaced with the your IP address or domain name of your
Internet connection, and the port number you specified in Webcam32.
The width and height values must match what you have set in the
You will also notice in the HTML that JavaCamPush.class
and JavaCamPush.cab is referenced. However, these files are
based on your local PC and the Webcam32 appliaction uses them locally
on your PC when somebody has connected to your live broadcast. Therefore,
when you FTP your HTML up to your web space, you do NOT
need to FTP the associated JavaCamPush.class and JavaCamPush.cab
Click here to
see the type of web cam stream that Listing 2 presents in your browser
(note: if my webcam is not running, then this will appear
as a grey box).