diff options
author | Théo de la Hogue | 2022-12-09 00:05:29 +0100 |
---|---|---|
committer | Théo de la Hogue | 2022-12-09 00:05:29 +0100 |
commit | 3d8d16d62d4cd738747b72d13efe837236be555c (patch) | |
tree | 58afe8879a2f1987b491e889636d800be1ea9563 /src | |
parent | 88a213a383cddeb0b5e4944fc8838ae428bceb47 (diff) | |
download | argaze-3d8d16d62d4cd738747b72d13efe837236be555c.zip argaze-3d8d16d62d4cd738747b72d13efe837236be555c.tar.gz argaze-3d8d16d62d4cd738747b72d13efe837236be555c.tar.bz2 argaze-3d8d16d62d4cd738747b72d13efe837236be555c.tar.xz |
Replacing TobiiSpecifications.ACCURACY by TobiiSpecifications.PRECISION.
Diffstat (limited to 'src')
-rw-r--r-- | src/argaze/utils/tobii_segment_display.py | 2 | ||||
-rw-r--r-- | src/argaze/utils/tobii_segment_gaze_movements_export.py | 2 | ||||
-rw-r--r-- | src/argaze/utils/tobii_stream_display.py | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/src/argaze/utils/tobii_segment_display.py b/src/argaze/utils/tobii_segment_display.py index dbef15f..2e0dab5 100644 --- a/src/argaze/utils/tobii_segment_display.py +++ b/src/argaze/utils/tobii_segment_display.py @@ -93,7 +93,7 @@ def main(): # Ignore frame when gaze position 3D is not valid if nearest_gaze_position_3d.validity == 0: - gaze_precision_mm = numpy.tan(numpy.deg2rad(TobiiSpecifications.ACCURACY)) * nearest_gaze_position_3d.value[2] + gaze_precision_mm = numpy.tan(numpy.deg2rad(TobiiSpecifications.PRECISION)) * nearest_gaze_position_3d.value[2] tobii_camera_hfov_mm = numpy.tan(numpy.deg2rad(TobiiSpecifications.CAMERA_HFOV / 2)) * nearest_gaze_position_3d.value[2] gaze_position_pixel.precision = round(video_frame.width * float(gaze_precision_mm) / float(tobii_camera_hfov_mm)) diff --git a/src/argaze/utils/tobii_segment_gaze_movements_export.py b/src/argaze/utils/tobii_segment_gaze_movements_export.py index fd36200..426d4bf 100644 --- a/src/argaze/utils/tobii_segment_gaze_movements_export.py +++ b/src/argaze/utils/tobii_segment_gaze_movements_export.py @@ -150,7 +150,7 @@ def main(): # Test gaze position 3d validity if tobii_gaze_position_3d.validity == 0: - gaze_precision_mm = numpy.sin(numpy.deg2rad(TobiiSpecifications.ACCURACY)) * tobii_gaze_position_3d.value[2] + gaze_precision_mm = numpy.sin(numpy.deg2rad(TobiiSpecifications.PRECISION)) * tobii_gaze_position_3d.value[2] tobii_camera_hfov_mm = numpy.sin(numpy.deg2rad(TobiiSpecifications.CAMERA_HFOV)) * tobii_gaze_position_3d.value[2] gaze_precision_px = round(tobii_segment_video.width * float(gaze_precision_mm) / float(tobii_camera_hfov_mm)) diff --git a/src/argaze/utils/tobii_stream_display.py b/src/argaze/utils/tobii_stream_display.py index 34e09f1..55051e5 100644 --- a/src/argaze/utils/tobii_stream_display.py +++ b/src/argaze/utils/tobii_stream_display.py @@ -109,7 +109,7 @@ def main(): # Ignore frame when gaze position 3D is not valid if data_object.validity == 0: - gaze_precision_mm = numpy.tan(numpy.deg2rad(TobiiSpecifications.ACCURACY)) * data_object.value[2] + gaze_precision_mm = numpy.tan(numpy.deg2rad(TobiiSpecifications.PRECISION)) * data_object.value[2] tobii_camera_hfov_mm = numpy.tan(numpy.deg2rad(TobiiSpecifications.CAMERA_HFOV / 2)) * data_object.value[2] gaze_position_px.precision = round(video_frame.width * float(gaze_precision_mm) / float(tobii_camera_hfov_mm)) |