View Single Post
  #6  
Old 03-24-2009, 02:51 PM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
You don't need to specify the cfg options if you are using the cluster master app.

Regarding your original problem, Gladsomebeast is correct. You cannot use the push/popMask commands around viz.add commands. The way to deal with this is to add the object to all computers and use the mask to modify the settings for each client. If I understand your specific scenario correctly, you have the master and one client in your cluster, and each will display 2 windows? If this is the case, then here is some pseudo-code that should set this up:
Code:
#Need to initialize window with viz.QUAD_BUFFER flag
viz.go(viz.QUAD_BUFFER)

#Resize main window to take up left half of screen
window1 = viz.MainWindow
window1.setSize(0.5,1.0)

#Create window to take up right half of screen
window2 = viz.addWindow(pos=(0.5,1.0),size=(0.5,1.0))
window2.stereo(viz.QUAD_BUFFER)

#Create 4 walls
wall1 = vizcave.Wall(...)
wall2 = vizcave.Wall(...)
wall3 = vizcave.Wall(...)
wall4 = vizcave.Wall(...)

#Add walls to cave
cave.addWall(wall1,window=window1,mask=viz.MASTER)
cave.addWall(wall2,window=window2,mask=viz.MASTER)
cave.addWall(wall3,window=window1,mask=viz.CLIENT)
cave.addWall(wall4,window=window2,mask=viz.CLIENT)
The vizcave module will handle updating the view frustum for each window on each client, assuming you use the cave.setTracker command.

In the code you posted above, you were using the window.fov command. Keep in mind that the vizcave module will update the projection matrix of the window every frame based on the position of the tracker. So the value you specified will be overwritten.
Reply With Quote