The main idea was to use augmented reality as a way to define a race-course for a cartoon racing game. Each marker defines a race-track part, which get automatically connected via a spline to define the whole track.
The integration was done using the vuforia package with framemarkers, which allow for some markers to be tracked at the same time, beeing computationally a lot lighter than the image markers.
The racetrack pieces were created as gameobjects in Unity. Each piece has a spline attached to it providing the waypoints for the racetrack.
When the tracking is running, an algorithm tries to find a closed track through the pieces and creates a spline for the whole course.
When starting, the track is frozen (so that potentially a number of players can play on the same track). The car gets oriented in the direction of the spline and the player can accelerate and decelerate. When the speed of the car is too high for the curvature it gets dragged outside or even drifts along – which means that the fastet lap can only be driven when choosen carefully when to aceelerate and break.
This was only done for proove of concept and will be paused for now.
Some more technical details will be provided in the blog.