mirror of
https://github.com/EyeTrackVR/EyeTrackVR.git
synced 2025-11-04 14:39:42 +08:00
fix: eye falloff dom eye bugged
This commit is contained in:
parent
7c9ed1dc5c
commit
25591b6104
@ -317,7 +317,7 @@ class cal:
|
||||
out_x = -abs(max(0.0, min(1.0, xl)))
|
||||
|
||||
if self.settings.gui_outer_side_falloff:
|
||||
print("pn")
|
||||
|
||||
run_time = time.time()
|
||||
out_x_mult = out_x * 100
|
||||
out_y_mult = out_y * 100
|
||||
|
||||
@ -10,7 +10,12 @@ class EyeId(IntEnum):
|
||||
|
||||
|
||||
def velocity_falloff(self, var, out_x, out_y):
|
||||
print("call")
|
||||
|
||||
if (
|
||||
self.settings.gui_right_eye_dominant
|
||||
or self.settings.gui_left_eye_dominant
|
||||
or self.settings.gui_outer_side_falloff
|
||||
):
|
||||
# Calculate the distance between the two eyes
|
||||
dist = np.sqrt(np.square(var.l_eye_x - var.r_eye_x) + np.square(var.left_y - var.right_y))
|
||||
if self.eye_id == EyeId.LEFT:
|
||||
@ -41,5 +46,6 @@ def velocity_falloff(self, var, out_x, out_y):
|
||||
else:
|
||||
# If the distance is within the threshold, do not mirror the eyes
|
||||
pass
|
||||
|
||||
else:
|
||||
pass
|
||||
return out_x, out_y
|
||||
|
||||
Loading…
Reference in New Issue
Block a user