Panda3D Manual: Stereo Display RegionsA StereoDisplayRegion is a special kind of DisplayRegion that contains two views internally: one view for the left eye, and a different view for the right eye. If you have a special 3-D display device, then Panda can use it to deliver each view to the appropriate eye. Alternatively, you can also simply create the two required views independently, one DisplayRegion for the left eye, and a separate DisplayRegion for the right eye. However, creating a single StereoDisplayRegion for both eyes at the same time is often more convenient. When you call (1) You have a special 3-D display device and the drivers to support it, and you put (2) You put (3) You put Using a StereoDisplayRegionA StereoDisplayRegion actually consists of two ordinary DisplayRegions, created automatically. If you need to, you can access them individually with Both the left and the right eye DisplayRegions actually share the same Camera object. The thing that makes the view different for the left and the right eyes is the stereo channel setting, which you can set via You can set a DisplayRegion's stereo channel to one of Setting the stereo channel to left or right also resets the texture view offset associated with the DisplayRegion: the default tex view offset is 0 for the left eye, and 1 for the right eye. This allows dual-view stereo textures to render properly in the DisplayRegion, so that the left view is visible in the left eye and the right view in the right eye. See Stereo/Multiview Textures for more about this feature. The lens parameters can be controlled via In this image, the camera indicated with "C" is the center view, the normal view from the center of the camera view in the case of The gray lines on the image represent the direction the camera appears to be facing into the scene. Both the left and the right eyes converge together at one point, which is the convergence distance. This distance is represented by line "b" on the image. Generally, the objects that are this distance away will appear to be in the screen plane. Objects that are closer than the convergence distance will appear to float in front of the screen, while objects that are further than the convergence distance will appear to be inside the screen. Note that the default stereo frustums that Panda creates are off-axis frustums, not toe-in frustums. That is, both the left and the right eyes are still pointing in the precise same direction as the center camera, but the frustum is distorted a bit to make objects converge approximately at the requested distance. This is generally regarded as producing a superior stereo effect over the more naive toe-in approach, in which the left and right eyes are simply tilted towards each other to provide the required convergence. If you require a different stereo frustum--for instance, if you wish to use toe-in stereo, or some other kind of stereo frustum of your choosing--you may simply set each DisplayRegion to use its own camera (instead of both sharing the same camera), and assign the particular frustum you wish to each eye. © Carnegie Mellon University 2010 |