Thanks to visit codestin.com
Credit goes to github.com

Skip to content

kamandk/hand-mouse-control

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 

Repository files navigation

Hand Mouse Control with MediaPipe

This project allows you to control your mouse cursor using hand gestures captured from your webcam. It uses Python libraries OpenCV, MediaPipe, and PyAutoGUI.

Features

  • Moves the mouse cursor based on the position of your index finger.
  • Performs a mouse click when you pinch your thumb and index finger together.

Requirements

  • Python 3.7 or higher
  • OpenCV
  • MediaPipe
  • PyAutoGUI

Installation

To install the required libraries, run: pip install opencv-python mediapipe pyautogui

Alternatively, if you have a requirements.txt file, run: pip install -r requirements.txt

How to Run

  1. Connect your webcam.
  2. Run the script: hand-mouse-control.py
  3. A window will open showing your webcam feed with hand landmarks.
  4. Move your index finger to move the mouse pointer.
  5. Pinch your thumb and index finger to click.
  6. Press q to quit.

Author

Kamand Kaffashi

About

Control mouse pointer using hand tracking with MediaPipe and OpenCV

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages