How bassam-alomari/auto-brightness works
Auto Brightness estimates ambient light from camera images and adapts selected display brightness, with user-configurable curves, stability safeguards, and Windows desktop controls. The main workflow is start monitoring in the desktop UI, capture and meter camera samples, calculate and verify brightness changes, and report status; settings and review tools shape that behavior. The README also documents a separate experimental Linux terminal and desktop preview. Relationships are limited to README statements and shown source references; unsampled internals are not assumed.
Main entry points: settings.py Persistent settings · qt_ui.py Qt desktop · linux_control.py Linux monitor CLI · adaptive.py Adaptive controller
Components 25
Desktop interfaces
- Qt desktop
src/room_brightness/qt_ui.py - Curve editor
src/room_brightness/comfort_ui.py - Calibration tools
src/room_brightness/tuning_ui.py - Display and suggestions
src/room_brightness/review_ui.py
Capture and control
- Control engine
src/room_brightness/qt_engine.py - Camera capture
src/room_brightness/camera.py - Image metering
src/room_brightness/metering.py - Display brightness
src/room_brightness/brightness.py
Adaptation and safeguards
- Adaptive controller
src/room_brightness/adaptive.py - Curve and stability
src/room_brightness/comfort.py - Quality safeguards
src/room_brightness/quality.py - Image analysis
src/room_brightness/vision.py - Power and trials
src/room_brightness/experience.py - Recovery diagnostics
src/room_brightness/recovery.py
Settings and tools
- Persistent settings
src/room_brightness/settings.py - Languages
src/room_brightness/i18n.py - Themes
src/room_brightness/themes.py - Profiles and updates
src/room_brightness/extras.py - Calibration and performance
src/room_brightness/tuning.py
Linux preview
- Linux monitor CLI
src/room_brightness/linux_control.py - Linux desktop preview
src/room_brightness/linux_ui.py - Linux restore helper
src/room_brightness/linux_backup.py
Other components
- User
- Camera device
- Display device
Connections 29
- User → Qt desktop: starts monitoring
README.md - Qt desktop → Control engine: controls
src/room_brightness/qt_ui.py - Control engine → Persistent settings: loads and saves
src/room_brightness/qt_engine.py - Control engine → Camera capture: selects camera
src/room_brightness/qt_engine.py - Camera capture → Camera device: captures from
README.md - Camera capture → Image metering: meters samples
src/room_brightness/camera.py - Image metering → Quality safeguards: checks quality
src/room_brightness/metering.py - Adaptive controller → Quality safeguards: gates readings
src/room_brightness/adaptive.py - Adaptive controller → Curve and stability: uses stability rules
src/room_brightness/adaptive.py - Adaptive controller → Image analysis: uses image targets
src/room_brightness/adaptive.py - Control engine → Display brightness: controls brightness
- Display brightness → Display device: reads and writes
README.md - Power and trials → Adaptive controller: calculates targets
src/room_brightness/experience.py - Power and trials → Recovery diagnostics: builds reports
src/room_brightness/experience.py - Persistent settings → Languages: resolves language
src/room_brightness/settings.py - Persistent settings → Themes: validates theme
src/room_brightness/settings.py - Persistent settings → Profiles and updates: validates profiles
src/room_brightness/settings.py - Persistent settings → Calibration and performance: validates options
src/room_brightness/settings.py - Qt desktop → Curve editor: opens editor
src/room_brightness/qt_ui.py - Qt desktop → Calibration tools: opens tools
src/room_brightness/qt_ui.py - Qt desktop → Display and suggestions: opens review
src/room_brightness/qt_ui.py - User → Linux monitor CLI: runs preview
README.md - User → Linux desktop preview: opens preview
README.md - Linux monitor CLI → Adaptive controller: uses adaptation
src/room_brightness/linux_control.py - Linux monitor CLI → Image metering: uses metering
src/room_brightness/linux_control.py - Linux monitor CLI → Persistent settings: loads preferences
src/room_brightness/linux_control.py - Linux desktop preview → Linux monitor CLI: uses control
src/room_brightness/linux_ui.py - Linux desktop preview → Linux restore helper: uses restore helper
src/room_brightness/linux_ui.py - Linux desktop preview → Recovery diagnostics: uses diagnostics
src/room_brightness/linux_ui.py