Skip to content

Commit

Permalink
docs: fix head movement definition
Browse files Browse the repository at this point in the history
  • Loading branch information
TeruyaHaroldo committed Apr 1, 2021
1 parent 325f437 commit 5b50add
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -219,8 +219,8 @@ Here we explaining the above gif and how reached the "results". Each "movement"
| Head Direction | Attribute | _v_ < -36° | -36° < _v_ < -12° | -12° < _v_ < 12° | 12° < _v_ < 36° | 36° < _v_ |
| - | - | - | - | - | - | - |
| Vertical | `headEulerAngleX` | Super Down | Down | Frontal | Up | Super Up |
| Horizontal | `headEulerAngleY` | Super Right | Right | Frontal | Left | Super Left |
| Tilt | `headEulerAngleZ` | Super Left | Left | Frontal | Right | Super Right |
| Horizontal | `headEulerAngleY` | Super Left | Left | Frontal | Right | Super Right |
| Tilt | `headEulerAngleZ` | Super Right | Right | Frontal | Left | Super Left |

### KeyError

Expand Down
16 changes: 8 additions & 8 deletions app/src/main/java/ai/cyberlabs/yoonit/camerademo/MainActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -400,20 +400,20 @@ class MainActivity : AppCompatActivity() {

headHorizontalAngleTextView.text = headEulerAngleY.toString()
headHorizontalTextView.text =
if (headEulerAngleY < -36) "Super Right"
else if (-36 < headEulerAngleY && headEulerAngleY < -12) "Right"
if (headEulerAngleY < -36) "Super Left"
else if (-36 < headEulerAngleY && headEulerAngleY < -12) "Left"
else if (-12 < headEulerAngleY && headEulerAngleY < 12) "Frontal"
else if (12 < headEulerAngleY && headEulerAngleY < 36) "Left"
else if (36 < headEulerAngleY) "Super Left"
else if (12 < headEulerAngleY && headEulerAngleY < 36) "Right"
else if (36 < headEulerAngleY) "Super Right"
else "-"

headTiltAngleTextView.text = headEulerAngleZ.toString()
headTiltTextView.text =
if (headEulerAngleZ < -36) "Super Left"
else if (-36 < headEulerAngleZ && headEulerAngleZ < -12) "Left"
if (headEulerAngleZ < -36) "Super Right"
else if (-36 < headEulerAngleZ && headEulerAngleZ < -12) "Right"
else if (-12 < headEulerAngleZ && headEulerAngleZ < 12) "Frontal"
else if (12 < headEulerAngleZ && headEulerAngleZ < 36) "Right"
else if (36 < headEulerAngleZ) "Super Right"
else if (12 < headEulerAngleZ && headEulerAngleZ < 36) "Left"
else if (36 < headEulerAngleZ) "Super Left"
else "-"
}

Expand Down
4 changes: 2 additions & 2 deletions app/src/main/res/layout/activity_main.xml
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="10px"
android:text="Left Eye Open:" />
android:text="Left Eye:" />
<TextView
android:id="@+id/leftEyeTextView"
android:layout_width="wrap_content"
Expand All @@ -371,7 +371,7 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginRight="10px"
android:text="Right Eye Open:" />
android:text="Right Eye:" />
<TextView
android:id="@+id/rightEyeTextView"
android:layout_width="wrap_content"
Expand Down

0 comments on commit 5b50add

Please sign in to comment.