字幕列表 影片播放 列印英文字幕 SHANEE NISHRY: Cardboard is a virtual reality viewer anyone can make. But how does it work? My name is Shanee, and in this video I'll show you how Cardboard works from hardware to software. Cardboard creates a window into another world, with a little help of your phone, allowing you to travel the world from the comfort of your seat, and gamers like me to fly a spaceship and fight dragons. It does that in three ways, leaving you to concentrate on making the best possible experience. It provides visual immersion, takes to user's movement into the virtual world, and it allows for user interaction. Let's take a closer look at each of these features. To make the users feel as if they have been taken to another world, we need to have them visually immersed. The screen of a phone is small and if [INAUDIBLE] close to a TV monitor doesn't make you feel like you're inside. We need to focus the user's field a view into the screen. The box and lenses, together with the picture on the phone, create the 3-D effect needed for virtual reality. When looking through the viewer, the lenses focus the wide field of view into the screen, making it appear closer and bigger than it is. This means all the user can see is the screen and the virtual world, putting them inside the game. To make visual immersion convincing, the user needs to perceive depth, just like we do in real life, or else things will look flat. To give the user depth perception, the screen is joined in a split-screen configuration. That is, there is a separate and slightly different image for each eye. To illustrate that, think about your eyes. Each eye sees the world from a different perspective. In the virtual world, a camera is deployed for each eye. Each camera is slightly offset to correlate with the position of the eye. This creates the stereoscopic effect and an illusion of depth making the brain think that the virtual space is real. All this together solves the first challenge of achieving visual immersion, except there is still one problem. Even though we can't see it from here, when looking through the headset, the image looks as if it were stretched along the edges. This happens because the lenses cause distortion to the image. This effect is called pincushion distortion. To fix the image, an opposite effect called barrel distortion is applied and post-process, creating a seemingly perfect and undistorted image. Now that we solved visual immersion, let's take a look at correlating with the user's movement. The user needs to move in the virtual world just about the same way as they would in the real world. To do that, virtual movement must be correlated with physical movement. Luckily, we have all the tools we need. Phones have motion sensors, including accelerometers and gyroscopes to track orientation. Using these sensors, Cardboard can track your head movement. So when you look around, the virtual camera's follow your head. Back to your to do list. We have just one challenge left. We talked about drawing an image to the screen and looking around, but how do we interact with the world? Looking around is nice, but not enough. You could connect a game controller to your phone, but we've made it much more simple and accessible. This is where the magnet at the side comes into play. Moving the magnet creates a distortion in the magnetic field. The magnetometer sensors in the phone detect it as input, which can then be used to trigger an action. And that's how Cardboard puts the user inside the virtual world. Now it is your job to create the next virtual reality experience. Check out the Cardboard website for the SDK and code samples, and follow up on the next videos where I will explain how to program for Cardboard. Until next time.