View Single Post
  #4  
Old 10-24-2007, 09:03 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
The default screen distance of Vizard is 1 meter. This means all objects less than 1 meter from the viewpoint will pop out of the screen. If you want objects further away from the screen to pop out then you need to use the fusionDistance command. The fusion distance will control the distance at which objects will appear to be on the screen. The default behavior of the fusion distance is to use the same value as the screen distance.

For example, the following script will create a line of balls going away from the viewpoint. Pressing a key 1-8 will set the fusion distance at the specified ball, so all balls before it should appear to pop out of the screen.
Code:
import viz
viz.go(viz.ANAGLYPHIC|viz.FULLSCREEN)

for x in range(8):
	viz.add('ball.wrl',pos=(0,1,3+x))
	vizact.onkeydown(str(x+1),viz.MainWindow.fusionDistance,3+x)
	
viz.add('tut_ground.wrl')
As I mentioned in my previous post, using the viz.HMD flag will create symmetric frustums and is only intended to be used with HMDs.
Reply With Quote