Skip to content

MuthuAmuthan7/Virtual-Piano

Β 
Β 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🎹 Virtual-Piano

Virtual-Piano is an AI-powered virtual piano that lets you play piano in the air without needing a physical instrument.
Using computer vision, it detects finger movements and simulates key presses, allowing users to create music seamlessly.


πŸš€ Features

  • 🎡 Air Gesture Control – Play piano using only Finger movements.
  • πŸ” Computer Vision-Based Detection – Detects finger speed and motion to simulate key presses.
  • πŸ”’ 10 Simultaneous Notes – Allows playing up to 10 notes at a time.
  • πŸ‘€ Smart Octave Control – Close your eyes for 3 seconds to shift octaves automatically.
  • πŸ“Ή Real-time Tracking – Uses webcam-based tracking for precise hand motion recognition.

πŸ› οΈ Technologies Used

  • Python 🐍
  • OpenCV πŸŽ₯ (Computer Vision for motion detection)
  • MediaPipe βœ‹ (Hand tracking)
  • PyGame πŸ”Š (Audio processing)
  • NumPy πŸ”’ (Data processing)

🎯 How It Works

  1. Start the Application – The webcam captures hand movements in real time.
  2. Detect Finger Motion – When fingers move downward at a certain speed, it is considered a key press.
  3. Play Notes – The system plays corresponding piano notes based on detected hand positions.
  4. Switch Octaves – Close your eyes for 3 seconds to change octaves.
  5. Enjoy Playing! 🎢

πŸ–₯️ Installation & Setup

  • Clone the repo to Your local machine.
  • Make sure that your webcam connectd
  • Finally to run the piano run Launcher1.py or Launcher2.py file.
  • Launcher1.py for basic piano and Launcher2.py to shift Octaves

πŸ”Ή Prerequisites

Ensure you have any version of Python below 3.12 installed.

πŸ”Ή Install Dependencies

pip install opencv-python mediapipe numpy pygame

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 100.0%