From the course: Unity: Building VR User Interfaces

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Distance from the eye

Distance from the eye - Unity Tutorial

From the course: Unity: Building VR User Interfaces

Start my 1-month free trial

Distance from the eye

- [Lecturer] Now that we've seen our safe area in VR, the big question is, How did this make you feel? Where you able to just comfortably read the text at the extremities of the safe area, hopefully so, but this is at a fixed distance from the user. What happens when we change that distance? Well, we're going to do that using a script. And we're also connect here to the distance, independent, millimeter principle from Google. To bring in the script, navigate over to the exercise folder for this video. In this exercise folder, 02, 04, you'll see another folder called Assets, open that up, and you'll see a script called the DMMMover. Drag that into the Scripts folder in unity under project. Switch back over to unity, and now we have our script. We're going to attach the script to the HUD, go to a VR Player Controller, and expand until we get to our HUD component. Go ahead and drag the DMMMover script onto the HUD, and…

Contents