FBOViewport does not work in a client-server configuration
|Reported by:||rstanchak||Owned by:||unassigned|
|Keywords:||FBO FBOViewport MultiDisplayWindow cluster client server fbo||Cc:|
The first problem is that FBOViewport.cpp has a number of FCD fields that store OpenGL handles, and these are being included in the syncronization step between client and servers. This doesn't make sense to me since these are probably going to be different machines altogether. Fixing this involved adding these fields to the RemoteAspect? field filter, and then modifying MultiDisplayWindow? to actually check whether the field should be updated.
The second problem is MultiDisplayWindow? seems to assume that all the Viewports attached to a particular window should be cropped and resized when tiling the display. With the FBO viewport this is completely incorrect behavior since the scene is being rendered to a texture, not to an actual window. This brings up the question of where the rendering should take place --
- Should the FBO texture be rendered on one computing node and then the texture distributed to other nodes?
- Should the FBO texture be rendered on each of the display nodes?
The former is more computationally efficient but would involve transmitting a potentially large texture across the network at a high frequency.
My patch takes the 2nd approach and has each display node recompute the FBO texture. This creates some wasted effort, but was simpler to implement. As such, in the section of MultiDisplayWindow? where the viewports are tiled, I basically just made this cropping conditional on the viewport not being an FBOViewport.