[vtkusers] Repositioning Image within Render Window

Alexis Cheng acheng_1221 at hotmail.com
Wed Oct 20 21:32:57 EDT 2010


Hi David,

By using the world coordinate system as ground, do you mean to use: coordinate->setCoordinateSystemToWorld

I have 2 renderers: backgroundRenderer and sceneRenderer

Checking the ComputedWorldValue of each shows that they're both at 0,0. How do I actually move a renderer (sceneRenderer) within this render window? It doesn't seem like changing the position of the actor in sceneRenderer has an effect on the final render window.

Your help is greatly appreciated.

Thanks,
Alexis Cheng
Electrical Engineering
University of British Columbia

> From: david.gobbi at gmail.com
> Date: Wed, 20 Oct 2010 18:21:48 -0600
> Subject: Re: [vtkusers] Repositioning Image within Render Window
> To: acheng_1221 at hotmail.com
> CC: daviddoria at gmail.com; vtkusers at vtk.org
> 
> On Wed, Oct 20, 2010 at 6:04 PM, Alexis Cheng <acheng_1221 at hotmail.com> wrote:
> > Hi David,
> >
> > That was the example I used to set the background to an image. Is it
> > possible to have multiple cameras focused on different objects?
> 
> The only way to have multiple, simultaneous cameras is to have
> multiple renderers sharing a render window (which means they share the
> color buffer and depth buffer of the window).  I strongly advise
> against doing this, though, because it can be tricky to have two
> renderers share a depth buffer properly.
> 
> Usually I find that it is best to ground everthing within a common
> coordinate system, and I always use the world coordinate system as my
> "ground".  Then I have most actors positioned correctly with respect
> to this "ground", and for other actors I have them follow the camera
> i.e. every time the camera moves, I reposition those actors within the
> world coordinate system to keep them stationary with respect to the
> camera.
> 
>   David
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20101020/bd85bd79/attachment.htm>


More information about the vtkusers mailing list