Desktop app · Windows · webcam

Turn it up with a pinch

A contactless gesture control system for Windows. Your right hand is an analogue volume knob; your left hand sends the media keys, so Spotify, YouTube or any player that listens to them responds.

It uses a webcam and MediaPipe's hand tracking, on your own machine.

Source code

Gestures

Grab the knob

Right hand: curl your little finger to take hold of the volume.

Pinch to set

Thumb and index pinched is 0 %, spread is 100 %, measured against your palm so distance does not matter.

Lock it

Extend your little finger, or move to the edge of the frame, to leave the volume where it is.

Play / pause

Left hand: a fist.

Next track

Left hand: one finger. Return to an open hand between commands.

Previous track

Left hand: two fingers, the peace sign.

Run it

Needs Windows 10 or 11, a webcam, and uv, which installs Python 3.12 and the dependencies. The first run downloads the hand-landmark model once. H hides the preview window, S shows it, Q quits.

uv sync
uv run hand-volume-control
uv run python -m hand_volume_control.find_cam   # find your camera

If it misreads you

  1. A fist reads as "previous": tuck your thumb across your fingers.
  2. The player ignores the keys: click its window once, and check no browser tab is taking the media keys.
  3. Jittery volume: improve the lighting; shadows confuse the model.

Privacy

Camera frames are processed in memory on your machine and never saved or sent. One network request, on the first run only, fetches MediaPipe's hand-landmark model from storage.googleapis.com into your cache folder; after that it works offline. While running, a keyboard listener watches for Q, H and S from any window and records nothing.

This page stores only your light or dark choice, whether you hid the intro, and your answer to the notice, all on this device.