-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.py
More file actions
36 lines (26 loc) · 1.07 KB
/
Copy pathmain.py
File metadata and controls
36 lines (26 loc) · 1.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# main.py
# ─────────────────────────────────────────────────────────────
# Entry point: wires GestureEngine → CameraWorker → HUDWindow
# ─────────────────────────────────────────────────────────────
import sys
from PyQt5.QtWidgets import QApplication
from gesture_engine import GestureEngine
from ui_layer import create_app, CameraWorker
def main():
try:
engine = GestureEngine()
app, win = create_app(engine)
# Camera worker thread
worker = CameraWorker(engine)
worker.frame_ready.connect(win.feed_frame)
worker.start()
win.show()
def on_close():
worker.stop()
app.aboutToQuit.connect(on_close)
sys.exit(app.exec_())
except Exception as exc:
print(f"Startup error: {exc}")
raise
if __name__ == "__main__":
main()