Sie sind auf Seite 1von 13

Virtual Mouse Using a

Under guidance of Dr. Rajeev


Webcam
Tripathi
by
Sunil Rathore

INTRODUCTION
In this presentation I present a approach

to HUMAN MACHINE INTERACTION, where I


am controlling of mouse using color
detection technique without any physical
contact with computer hardware.

The basic block diagram of the


system
Capturing the real time video using
webcam
processing the individual image frame
Conversion of flipped image into gray

scale image

Color detection

The basic block diagram of the


system
Conversion of gray scale image into
binary scale image
Finding the centroid of the object
Tracking the mouse pointer
Performing clicking action

Capturing the real time


video:
Computer Webcam is used to capture the Real

Time Video at a fixed frame rate and


resolution.
Video is divided into Image frames based on
the FPS (Frames per second) of the camera.
Processing of individual Frames.

Conversion of Flipped image


into
Gray scale Image
As compared to colored image, computational

complexity is reduced in a gray scale image.


Thus the flipped image is converted into gray
scale image.

Gray scale image

Color Detection
The red, green and blue color object is detected by

subtracting the flipped color suppressed channel


from the flipped gray-scale image.

red

green

blue

Conversion of Gray scale


Image into
Binary scale Image
The grey region of the image obtained after

subtraction needs to be converted to a binary


image for finding the region of the detected object.

red

green

blue

Finding Centroid of an
object and
plotting
An inbuilt functional in MATLAB is used to find the

centroid of the detected region.


These coordinates change with time as the object
moves across the screen.

red

green

blue

Tracking the Mouse pointer


Once the coordinates has been determined,

the mouse driver is accessed and the


coordinates are sent to the cursor.
With these coordinates, the cursor places
itself in the required position.

Performing Clicking and scrolling


Clicking action is based on the presence or absence of

object.
If red, green and blue color is detected , Left and
right clicking action is not performed.
If red color is not detected, right clicking action is
performed.
If blue color is not detected, left clicking action is
performed.
If green color is detected, wheel scrolling action is
performed.

Conclusion
In this project, an object tracking based

virtual mouse application has been developed


and implemented using a webcam.
This technology has wide applications in the
fields of computer graphics, computer
gaming.

REFERENCES
http://

www.mathworks.com/matlabcentral/fileexchange/2
8757-tracking-red-color-objects-using-matlab
.
Hojoon Park, A Method For Controlling The
MouseMovement using a Real Time Camera,
2008, Brown University,Providence ,RI ,USA,
Department of computer science.
Chu-Feng Lien, Portable Vision-Based HCI A
Real-time Hand Mouse System on Handheld
Devices, National Taiwan University, Computer
Science and Information Engineering Department

Das könnte Ihnen auch gefallen