From 2d98ac67326dff680feb05ff38df7174503ebccb Mon Sep 17 00:00:00 2001 From: Théo de la Hogue Date: Wed, 10 May 2023 16:11:25 +0200 Subject: Writing visual scan path. --- src/argaze/utils/demo_gaze_features_run.py | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src') diff --git a/src/argaze/utils/demo_gaze_features_run.py b/src/argaze/utils/demo_gaze_features_run.py index 3eaa79f..b83d60d 100644 --- a/src/argaze/utils/demo_gaze_features_run.py +++ b/src/argaze/utils/demo_gaze_features_run.py @@ -185,6 +185,14 @@ def main(): # Draw movement from start to next cv2.line(aoi_matrix, start_gaze_position, next_gaze_position, (0, 0, 255), 1) + # Write last 5 steps of visual scan path + path = '' + for step in visual_scan_path[-5:]: + path += f'> {step.aoi} ' + path += f'> {visual_scan_path.current_aoi}' + + cv2.putText(aoi_matrix, path, (20, args.window_size[1]-40), cv2.FONT_HERSHEY_SIMPLEX, 1, (255, 255, 255), 1, cv2.LINE_AA) + # Unlock gaze movement identification gaze_movement_lock.release() -- cgit v1.1