Here's a simple stereo viewer which presents the left and right
side-by-side stereo image to the left and right eye of an HMD.
This works with a stereo video as well as a stereo still image.
Code:
from viz import *
go(HMD | STEREO)
thepic = add('stereoimage.jpg')
screen1 = add(TEXQUAD, WORLD, 1)
screen1.scale(2,.8,1)
screen1.translate(.5,1.82,.91)
screen2 = add(TEXQUAD, WORLD, 2)
screen2.scale(2,.8,1)
screen2.translate(-.44,1.82,.91)
setscene(1, LEFT_EYE)
setscene(2, RIGHT_EYE)
screen1.texture(thepic)
screen2.texture(thepic)