The Maths behind gesture: 'facing center' #150
-
Can you explain to me the logic and the maths behind facing centre gesture in this code : `for (let i = 0; i < res.length; i++) {
Thank you |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
i'd consider actual value of
you can think of |
Beta Was this translation helpful? Give feedback.
i'd consider actual value of
iris: facing center
gesture less important than similar oneface: facing center
which looks at the Z coordinates of corners of the eyes (not corners of the face as with higher angles face corner is likely not visible to start with)iris: facing center
is weird, but i've tried different methods and this algorithm gave ok results on averageit first calculates square area of each eye (
areaLeft
andareaRight
) based on corners of the eyeand then if difference in eye areas is less than 25% it states
facing center
- meaning both eyes are of similar size so thus face is not turned to either sideyou can think of
iris: facing center
as an intermediate result towardsi…