Files
Table-Python/config.py
T
DuOtto 1d63671fad idk
2025-07-17 21:54:45 +02:00

27 lines
958 B
Python

import numpy as np
# ----- Configuration -----
CAMERA_INDICES = [0] # List of camera device indices
FRAME_WIDTH = 3980
FRAME_HEIGHT = 2560
PIXELS_PER_INCH = 38 # will be set by calibration
PINCH_THRESHOLD = 40 # px to start touch
RELEASE_THRESHOLD = 60 # px to end touch
CIRCLE_TOUCH_THRESHOLD = 20 # px tolerance for circle touch
# HSV range for shape color (tune for your arrow: now tailored for orange)
LOWER_SHAPE = np.array([10, 100, 100]) # hue from 10° (orange) to
UPPER_SHAPE = np.array([30, 255, 255]) # hue up to 30°, full sat/val range
DEBOUNCE_TIME = 1.0 # seconds
# ——— Constants for Tabs & Buttons ———
TAB_W, TAB_H = 40, 60
TAB_X = 600 # adjust this to your projector output width
TAB_Y0 = 50
TAB_GAP = 10
# left/right arrow buttons
LEFT_BTN_TOP = (TAB_X, TAB_Y0+2*(TAB_H+TAB_GAP)+20)
RIGHT_BTN_TOP = (TAB_X, LEFT_BTN_TOP[1]+TAB_H+TAB_GAP)
DEBUG = True