Skip to content

LemiSt24/SG2022-We-Got-The-Moves

Repository files navigation

Serious Games - We got the Moves

Description

In the following we present 'We got the Moves' as tracking App for sport movements and exercises developed in cooperation with TU Darmstadt as part of the Serious Games ( Project-)Praktikum.

Authors

  • Alexander Hartmann
  • Jan-Luca Barthel
  • Lennard Michael Strohmeyer
  • Simon Westermann

Features

  • Camera tracking of movements during a selected workout ( via Google's mediapipe)
  • Quality measurement for exercises during workout sessions
  • Statistics for user's calories (daily & calendar) and exercises
  • Profile settings
  • Tutorial for the app (as manual)
  • Tutorials for exercises
  • Workout planner
  • Training video replays
  • Training video recording (Future work)

Demo

You can download the apk for Android here. This app can run on phones with Android 9.0 or newer installed and is not running on emulators in Android Studio due to problems with OpenGL.

License

MIT

For Developers

Basics

Preferable Android IDE

Android Developer Guides

Code style / Code formatter

To ensure that Code is readable and is formatted uniformly, the plugin google-java-format can be installed via Settings -> Plugins. Note that the plugin has to be enabled afterwards. Furthermore it's advisable to enable 'Reformat Code', 'Organize imports', 'Rearrange Code' in Android Studio as show here

UI libraries

Basics

'We got the moves' offers the use of two UI binding libraries as alternative possibilities. Please refer to the specific links below.

For most purposes, it's easier to use the View Binding Library. In case you want to bind specific data objects to a view's components (e.g. list items bounded to certain objects), it can be advantageous to use the Data Binding Library instead. Once any example_layout.xml file has been created under app/src/main/res/layout, both libraries will generate the target layout binding class, e.g. named as ExampleLayoutBinding automatically.

Images

In order to render images of exercises in the Dashboard in fitting size, the Bumptech / Glide library is used. It's recommend to place input images in the drawable folder res/images/drawable in order to not mix them with ** icons.xml** files in the common res/drawable folder.

Youtube Videos

Exercises are links with their corresponding Youtube Videos provided using PierfrancescoSoffritti / Android-youtube-player library .

Statistics

We use a well known PhilJay / MPAndroidChart library for building and displaying charts in the statistic view. This tool allows all kind of charts, like bar, graph or pie charts.

ML libraries

Mediapipe

One of core features (pose and position tracking) provided by 'We go the Moves' App relies on the Google's Mediapipe library.

Database

Android Room DB library

'We go the Moves' uses Android Room as abstract Layer over Android SQLite. Local data is saved persistently on device.

General procedure:

  • Create an Entity Class (or Model Class) and annotate it (table name, primary key, columns, etc.)
  • Create an abstract DAO Class (Data Object Class) which maps queries (e.g. insert, update, delete, read) to their related methods using annotations. For observable data holding, LiveData or RxJava 's datatype Publisher, Observable or Flowable as well as non-automatic fetching data holder classes like Single, Maybe or Completable might be useful and can be used interchangeable. An overview is shown here:

here

  • In the AppDataBase Class, add the Entity (Table) as well as the DAO below the TODO comments. Hint: It isn't always necessary to increase the migration version number when the DB has been changed if you wipe the DB from your device (e.g. by deleting the app or wipe the emulator). Be aware that all data will be lost.
  • Optionally, you can create a Repository Class ( e.g. as a Singleton) which bundles data from DB, external sources (such as remote DBs) or allow asynchronous execution. The Repository can be instanced in the BasicApp Class below the TODO comment.

References

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •