How does a phone know which way your head is moving in a VR scene? Its accelerometer measures motion, its gyroscope measures rotation, and its magnetometer supplies compass direction. A sensor fusion algorithm combines those readings to estimate head movement. section 15.2
That estimate can steer the viewpoint in a 3D scene: instead of dragging a mouse to look around, you move your head. Slightly different views shown to each eye create a stereo effect. Sensor fusion supplies the tracking; it does not, by itself, render the scene. The math and code for fusion are left aside here. section 15.2
