Skip to content

Virutal Volume Controller β€” OpenCV + MediaPipe, Control your system volume using just your fingers β€” no keyboard, no mouse, just pure gesture magic! πŸ–οΈπŸ€

Notifications You must be signed in to change notification settings

KunalMehra075/Volume-Control-OpenCV

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

2 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ”Š Virtual Volume Controller β€” OpenCV + MediaPipe Project

Control your system volume using just your fingers β€” no keyboard, no mouse, just pure gesture magic! πŸ–οΈπŸ€
Built using Python, OpenCV, and MediaPipe, this project uses your webcam to detect finger distance and adjust the volume in real time.

πŸ–Ό Demo

Demo

🎯 How It Works

πŸ“· Your webcam tracks your index finger and thumb using MediaPipe's hand tracking.
The distance between them determines the volume level:

  • πŸ‘‰βœŒοΈ Stretch fingers wide β†’ Volume increases
  • 🀏 Bring fingers close β†’ Volume decreases
  • πŸ‘ˆπŸ‘‰ Touch both fingers β†’ System is muted

This is a simple yet powerful demo of gesture-based human-computer interaction!

πŸš€ Features

βœ… Real-time finger tracking with MediaPipe
βœ… Dynamically adjust system volume based on finger distance
βœ… Mute system when fingers are touching
βœ… Clean UI using OpenCV overlays
βœ… Works offline (on Windows)

🧠 What You’ll Learn

  • Hand landmark detection using MediaPipe
  • Measuring Euclidean distance between fingers
  • Mapping distance to volume percentage
  • Controlling system audio using pycaw (Windows)

πŸ›  Setup Instructions

  1. Install the required dependencies, globlally or by creating a virtual environment:

    pip install -r requirements.txt
  2. Run the application:

    python volumeHandControl.py

🧰 Tech Stack & Dependencies

  • Python
  • OpenCV
  • MediaPipe
  • pycaw (for controlling system volume on Windows)

Buy me a coffee πŸ₯Ή:

Buy Me A Coffee

Contributions are welcome! πŸ™ If you have any ideas for improvements, feel free to submit a pull request.
Follow me for more exciting projects like this! 🀩

About

Virutal Volume Controller β€” OpenCV + MediaPipe, Control your system volume using just your fingers β€” no keyboard, no mouse, just pure gesture magic! πŸ–οΈπŸ€

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages