[vtkusers] vtkImageViewer2::Render

Charl P. Botha c.p.botha at ewi.tudelft.nl
Mon Sep 1 08:39:48 EDT 2003


On Mon, 2003-09-01 at 14:23, Charl P. Botha wrote:
> My current suspicion is that ParallelProjectionOn() is being called too
> late, and that the visual glitch we see is due to the fact that the
> imageviewer starts up in perspective projection and gets switched to
> parallel projection.  See what happens when you start your Python
> example and immediately begin to window/level with the left mouse
> button.

Okay, I've just confirmed my suspicion.  vtkImageViewer2::Render() is
only called once you start window/leveling, but NOT during zooming. 
This means that the FirstRender init potentially happens only long after
the user has interacted with vtkImageViewer2 for the first time and thus
the ParallelProjectionOn() is called after the user has already seen the
perspective projection, hence the glitch.

I believe this problem can also be solved by moving the
ParallelProjectionOn() statement to the vtkImageViewer2 constructor. 
Could anyone else comment on this?

Thanks,
Charl

-- 
charl p. botha http://cpbotha.net/ http://visualisation.tudelft.nl/




More information about the vtkusers mailing list