How cheng98989/iris works
Iris is a local webcam-based desktop gesture controller. Its main workflow captures video, derives and smooths hand landmarks, recognizes gestures, advances a timed interaction state machine, and performs cursor, click, scroll, or media actions; the preview and tray/settings UI support that runtime. The README documents these modes and multi-monitor cursor use. Some subsystems are represented by their exact tree paths but were not sampled, so uncertain internal wiring is omitted.
Main entry points: main.py Runtime loop · ui.py Preview & settings · hand.py Landmark detection · recognition.py Gesture recognition
Components 21
Capture & perception
- Camera capture
iris/camera.py - Landmark detection
iris/hand.py - Hand selection
iris/hand_selector.py - Landmark model
iris/landmarks.py - Signal conditioning
iris/signals.py
Gesture control
- Runtime loop
main.py - Gesture recognition
iris/recognition.py - State machine
iris/state.py
Desktop interaction
- Gesture actions
iris/actions.py - Cursor control
iris/cursor.py - Scroll rate
iris/scroll.py - Monitor mapping
iris/screen.py
Interface & settings
- Configuration
iris/config.py - State audio
iris/audio.py - Preview overlay
iris/overlay.py - Preview & settings
iris/ui.py - System tray
iris/ui.py - Hotkey listener
iris/listener.py
Other components
- User
- Webcam
- Desktop OS
Connections 27
- User → Webcam: presents gestures
- Webcam → Camera capture: provides frames
- Runtime loop → Camera capture: reads frames
- Runtime loop → Landmark detection: submits frames
- Runtime loop → Hand selection: selects hand
- Runtime loop → Signal conditioning: smooths landmarks
- Runtime loop → Gesture recognition: recognizes pose
- Runtime loop → State machine: updates state
- Runtime loop → Gesture actions: dispatches actions
- Runtime loop → Cursor control: moves pointer
- Runtime loop → Scroll rate: computes scroll
- Runtime loop → Monitor mapping: maps monitors
- Runtime loop → Preview overlay: draws preview
- Runtime loop → Preview & settings: shares preview frame
- Runtime loop → Hotkey listener: checks quit
- Runtime loop → Configuration: loads settings
- Runtime loop → State audio: plays state sound
- Landmark detection → Landmark model: uses landmark schema
- Gesture recognition → Landmark model: interprets points
- State machine → State audio: requests sound
- Gesture actions → Desktop OS: issues controls
- Cursor control → Desktop OS: controls pointer
- Scroll rate → Desktop OS: emits wheel input
- Monitor mapping → Desktop OS: queries displays
- User → Preview & settings: uses preview and settings
- User → System tray: opens tray menu
- System tray → Preview & settings: opens panels