**5.4 Webcam**

A webcam is used to capture live video or image through computer interfaced network. Webcams are more compatible with user's monitor and hardware interface. Webcams finds popular application in video chat session with live audio and video streaming. The device such as Apple's iSight camera, iMacs webcams provides clear picture for video chat sessions. The software supported with Webcam records the video and also it can be live streamed through Internet. The video streaming over the Internet needs a wide bandwidth and it is compressed for live streaming. The maximum resolution of a webcam is lower compared with handheld video cameras and it suits for video chat session. Webcam are used to capture the view of camera over its web page. The evolution of webcam technology uses advanced webcams with the improvement from 1080 pixel to 2160 pixel for the better image quality and widely used in several industries including marketing, security, traffic management and healthcare systems.

### *5.4.1 Working of the webcam*

Webcam works as a conventional digital camera to interact with the web pages and other internet pages. The camera technology is framed to capture the images

#### *Vehicle Collision Avoidance System Using Li-Fi DOI: http://dx.doi.org/10.5772/intechopen.98616*

through a tiny grid of light-detectors, known as charge-coupled devices (CCD). The output of CCD is the digital format so that computers can access this data. Webcams do not provide the option of image storage and it transmits the data immediately to the host device through the USB cable. The advancement in technology leads to integration of microphone with camera. Webcam function in two ways as capture the image or video and to transfer it to the predestined device [9]. Similar as digital camera, the webcam has come with the appropriate software to interact with the host device. The Software provides the flexibility to edit the images and to record the videos for particular duration. This software collects the digital data of image from the camera at certain intervals of time. The frame rate decides the number of pictures or video streaming displayed on the computer or other display systems. The image frame is converted into a JPEG file and finally sends it to the web server using the file transfer protocol (FTP). To utilize the webcam in transferring the data, certain configuration steps to be followed in uploading the images and videos [10].

Modern day desktop and laptops are provided with built in webcam of small in size. Due to this compactible size, the provision for multi-piece lens is not possible and this results in the reduced image quality. To overcome the drawback in image quality, external webcams are chosen. Adjusting the camera position is difficult as it is fixed with the device [11]. The integrated webcam and external webcams are varied with respect to cost, focal length, stereo quality sound, light sensitivity and certification.

#### *5.4.2 Image sensor*

Image sensors are classified based on its structure type as CMOS or CCD. In CMOS image sensor uses a solid-state image sensor chip which is made up of light sensitive elements, micro lenses, and micro electrical components. In CCD the pixel exposure occurs at the same time in the technology of global shutters. The webcams are capable of providing VGA-resolution with the frame rate of 30 frames per second. Modern day devices are developed to produce video in multi-megapixel resolutions such as the PlayStation Eye, which can produce 320 × 240 video at 120 frames per second. Nintendo Wii Remote uses an image sensor with a resolution of 1024 × 768 pixels [10].

#### *5.4.3 Webcam Interface*

Typical interfaces such as Ethernet and IEEE 802.11 (denominated as IP camera) are used for webcam connectivity for desktop or Wi-Fi devices. To communicate with high quality video through single channel or with two or more channels, the interface such as composite video or S-Video interface is used. The video streaming functionality to USB enabled device is achieved through USB video class (UVC) specification to interface effectually with host machines.

#### *5.4.4 Webcam features*

#### *5.4.4.1 Frame rate*

The webcam with good image quality is obtained with the frame rate of 30 frames per second (fps). The frame rate less than 30fps leads to blurred in image quality. It is better to choose webcam which that supports 60 fps recording to obtain decent image quality. The increase in fbs rate occupies the modern day monitors to capture live image and the fps rate decides the speed at which the image moves on the screen. Webcam image is transferred with a range of 15 frames per second to

an ideal rate of 30 fps and this provides better video streaming with respect to the speed of the internet.

### *5.4.4.2 Resolution*

The resolution of webcam has improved to 720 × 1080 pixel to meet highdefinition capabilities. The higher end webcams are also available as 4 k range, which can be used for specific applications and it is supported with HD-capable monitor to view the true high definition. Webcams with 1080p are compatible with all interfacing devices to perform real time video streaming.

## *5.4.4.3 Autofocus*

Autofocus is an option provided in webcam, which is used to focus the object automatically from camera position. Autofocus mode creates a delay for image capture as the camera takes the time to focus the object. In order to speed up the video streaming then the auto focus mode is turned to off condition.

#### *5.4.4.4 Microphone*

High-quality recording for episodes or other higher-tech films requires an upgrade. For those situations, invest in an external microphone.

#### *5.4.4.5 Megapixels*

It decides the quality of the picture or image. Most of the cameras provide reasonable quality images. It is good if we use 320\*240 or 640\*480 pixels. For better quality webcam should have 1280\*720 resolutions.

#### *5.4.4.6 Lens*

Webcams are designed with glass lens or plastic lens based on the pixel range required and the cost convenience. For professional video presentation through Skype and other video chat software can use webcams with plastic lens, as it is more adequate for decent image quality [12].

#### *5.4.5 Webcam resolution test*

The Webcam Resolution Test is used to estimate the resolution of webcam through internet connectivity. The test results will show the clear list of resolutions supported by the camera and provides the information for attaining the ways of maximum resolution, minimum resolution and default resolution. The analysis provides the support to estimate each supported resolution for the image taken and each image quality can be compared. The webcam resolution test initially checks as default mode for possible resolution standards the major drawback occurs if the supported resolution is missed out.

The pixel value of captured image depends on the height and width of captured image. The image quality is specified as megapixel as one million pixel equals to one megapixel and abbreviated as Mpx or MPixel. The image quality of camera is determined based on the megapixel range as the manufacturer indicates the maximum supported value [13]. An webcam with a resolution of 1920 × 1080 can capture up to 2073600 pixels or 2.0736 megapixels, rounded off as 2MP. The resolution of camera is not the only parameter for better image quality as higher the resolution

*Vehicle Collision Avoidance System Using Li-Fi DOI: http://dx.doi.org/10.5772/intechopen.98616*

provides more accurate details and good sharpness. The image taken with a higher resolution camera finds more clarity, when printing in large formats or viewing on big screens.
