Skip to content

Gebort/FESTU.Navigator

Repository files navigation

FESTU.Navigator

The project, developed for a FESTU university (city Khabarovsk) competition, implements AR navigation through the FESTU university buildings along a pre-created corridor graph. Work with AR is done entirely using the SceneView library

Video demonstration available below

The application builds routes between university classrooms. When launching the application, it is required to scan the number of the nearest classroom in order to set the starting point of the route. Classrooms number recognition performed using Google MLKit.

By default, the recognizable classroom number must be vertical and not contain letters in the name


It is required to confirm the recognized classroom number and its position in 3D space, since an error is possible in determining the planes around the user


Initialization is required to determine the user's current position relative to the saved classrooms graph. After initialization, the user can select both the start and end points of the route


The built route thanks to the SceneView AR library is displayed in 3D space in front of the user. Finding the shortest route is done using the A* algorithm, path smoothing is done using Bezier curves.


The classrooms graph is created manually by the application administrator through a special interface


Video demonstration

user_mode.mp4

Settings

You can change the path rendering distance (increase the number of nodes) and other settings, in festunavigator/presentation/preview/PreviewFragment.kt:

360 companion object {
361        //path rendering distance (number of nodes)
362        const val VIEWABLE_PATH_NODES = 21
363        //tree rendering distance, used only in admin mode
364        const val VIEWABLE_ADMIN_NODES = 5f
365        //how often the check for path and tree redraw will be
366        const val POSITION_DETECT_DELAY = 100L
367        //image crop for recognition
368        val DESIRED_CROP = Pair(8, 72)
369    }

You can change the classroom number template (first char must be a digit by standard) in festunavigator/data/ml/classification/TextAnalyzer.kt:

143    private fun filterFunction(text: Text.TextBlock): Boolean {
144        return text.text[0].isDigit()
145    }

Admin/User mode

To enable the audience graph editing mode, change the build variant to adminDebug or adminRelease:


By default, the application is installed with a pre-installed FESTU university classrooms graph. To run the application without a pre-installed graph, in festunavigator/domain/di/ModuleApp.kt find:

32 return Room.databaseBuilder(this, GraphDatabase::class.java, DATABASE_NAME)
33     .createFromAsset(DATABASE_DIR)
34     .allowMainThreadQueries()
35     .addMigrations()
36     .build()

Remove line - .createFromAsset(DATABASE_DIR):

32 return Room.databaseBuilder(this, GraphDatabase::class.java, DATABASE_NAME)
33     .allowMainThreadQueries()
35     .addMigrations()
34     .build()

Now you can run the app and experience it anywhere

Admin mode video demonstration

An example of setting up navigation in a new space is available here (the video is too long for github): https://drive.google.com/file/d/11a_lTeQmXhMfE2AxJ8mg5ec34yCC1uoH/view?usp=sharing