Skip to main content

2019 | Buch

Beginning iOS AR Game Development

Developing Augmented Reality Apps with Unity and C#

insite
SUCHEN

Über dieses Buch

Create a fully featured application that’s both sophisticated and engaging. This book provides a detailed guide in developing augmented reality games that can take advantage of the advanced capabilities of new iOS devices and code while also offering compatibility with still supported legacy devices.

No programming experience is necessary as this book begins on the ground floor with basic programming concepts in Unity and builds to incorporating input from the real world to create interactive realities. You’ll learn to program with the Unity 2017 development platform using C#.

Recent announcements of increased AR capabilities on the latest iPhones and iPads show a clear dedication on Apple’s part to this emerging market of immersive games and apps. Unity 2017 is the latest version of this industry leading development platform and C# is a ubiquitous programming language perfect for any programmer to begin with.

Using the latest development technologies, Beginning iOS AR Game Development will show you how to program games that interact directly with the real world environment around the user for creative fantastic augmented reality experiences.

What You'll Learn

Download assets from the Unity store

Create a scene in Unity 2017

Use physics and controls on mobile devices

Who This Book Is For

Beginner programmers and/or people new to developing games using Unity. It also serves as a great introduction to developing AR games and educators teaching the subject at high school or higher levels.

Inhaltsverzeichnis

Frontmatter
Chapter 1. Introduction
Abstract
In this book, we are going to learn how to create an Augmented Reality (or AR) Game using the game development software from Unity (Unity3D 2018 or, more commonly, Unity). In this chapter, we will go through the process of downloading and installing Unity and learn about some of the tools that Unity provides. We will also install an existing AR project from the Unity Asset Store and explore some of the features of this game. In Chapter 2, we will install the ARKit and provide an overview of the Unity user interface. In chapter 3, we will start using the Unity ARKit and use some of the key functions. I will also provide a basic overview of visual inertial odometry and what this means for creating AR projects. We will make a basic scene to use and test Unity ARKit. In Chapter 4, we will use some of the more advanced functions in Unity ARKit such as hit testing and lighting an AR scene. Finally, in Chapter 5, we will put this all together and make an AR game using the Unity ARKit.
Allan Fowler
Chapter 2. Getting Started
Abstract
Hopefully, you might already have a good idea of what Augmented Reality (or AR) is. As there is some confusion about the difference between the terms Virtual Reality (or VR), Augmented Reality, and Mixed Reality, I thought it might be worth trying to clarify what I mean by AR in this book.
Allan Fowler
Chapter 3. The Unity ARKit
Abstract
Now that you have installed Unity and the Unity ARKit Plug-in, it’s time to get to learn a bit more about this tool and make our first AR experience. Note, I called this an experience and not a game, although it could possibly be used as a game in some way; from my point of view a game needs some key elements, which I will go into detail in Chapter 4.
Allan Fowler
Chapter 4. Hit Testing and Lighting
Abstract
In our last chapter, we used both Cloud Points and Generated Planes to help the camera track the movement of the device. However, you may have noticed that our amazing cube continued to stay at the point of origin. While this may be okay for our first AR App, I’m sure in time you might want to create virtual objects that appear to be located on a physical object in the real world. To do this, we are going to use a feature of the Unity ARKit called hit testing. You may have also noted that the lighting of the GameObject on the screen of your iOS device is not consistent with the lighting in the real world; we are also going to address this issue in this chapter.
Allan Fowler
Chapter 5. Making AR Games
Abstract
Now that you have learned some fundamentals of using the ARKit and have a grasp of Unity, we are going to start making an AR Game. Along the way, we will also cover some of the more advanced functions of the ARKit.
Allan Fowler
Chapter 6. Introducing Touch
Abstract
In the last chapter we were able to test our Game in the Unity Game View; now, let’s see what the game will look like in AR. With the FuguBowlAR Game open in Unity, let’s add the Unity AR Camera Manager to our Main Camera. In the Hierarchy select the Main Camera and then in the Inspector, select Add Component (Figure 6-1). In the Add Component search bar, search for Camera and select the Unity AR Camera Manager (Figure 6-2).
Allan Fowler
Chapter 7. Adding Plane Detection and Point Clouds
Abstract
Now we are going to add the Generated Planes to our game, which will help the ARKit camera track the movement of the device.
Allan Fowler
Chapter 8. Final Steps
Abstract
In the previous chapter, we found that in order to stop the bowling ball and pin to stop falling through our generated plane, we needed to keep the Plane(t) GameObject in the scene. The reason for this is that Unity creates (or instantiates) the bowling ball and pins GameObjects before generating the generated plane. In this chapter, we are going to make some changes to our project to be able to do this
Allan Fowler
Backmatter
Metadaten
Titel
Beginning iOS AR Game Development
verfasst von
Allan Fowler
Copyright-Jahr
2019
Verlag
Apress
Electronic ISBN
978-1-4842-3618-5
Print ISBN
978-1-4842-3617-8
DOI
https://doi.org/10.1007/978-1-4842-3618-5