Game Development Reference
In-Depth Information
2.4A UGMENTED R EALITY
Augmentedreality(AR)isatermthathasinrecentyearsbecomepopular.Ourpowerfulmo-
bile devices are creating new ways for us to interface with users and with the world around
us. As the name implies, reality is augmented, augmented with more information, images,
sounds, and user provided details, such as reviews or comments by other people.
In games, forms of augmented reality have existed for many years, but it is until recently
that user interfaces from games are converging with user interfaces we use in our daily lives
and we see new and interesting applications for it.
To implement AR in games we need to spend some time deciding how the AR data will be
assigned and retrieved. Game objects need to be marked and given the data that we wish
to display. Some information may be calculated in real-time, such as the distance to the ob-
ject, its angle in relation to the player, its world space coordinates. But the game specific
information, its name, description and any other interesting information has to be stored and
retrieved efficiently.
Once the data pipeline for an AR system is designed and implemented, we need to imple-
ment the AR display. Fortunately, in games, and unlike reality, we have very accurate in-
formation about the world and all the objects around us. We don't generally need to worry
about algorithms that perform feature detection/recognition, edges, corners, image recogni-
tion or pattern matching. Instead, we usually will have an object's world space coordinates
available, or we can generate a ray down the camera's center and if any object is hit, we use
the contact data from the intersection to first, query the object's AR data from our game's
database, and second to procedurally generate the geometry for the AR display, or project
the user interface from the object's world space into the player's screen space. We will see
many techniques that apply to augmented reality in the following chapters.
Search WWH ::




Custom Search