[vtkusers] Question on to selectively load an image region

Elvis Dowson elvis.dowson at mac.com
Fri Oct 3 02:15:30 EDT 2008


Hi,
        I have a large 2D image file representing a map. At run-time,  
I just want to display a particular region or area on the map.

Q1. Which vtk classes should I use and how should I set it up, so that  
I only load a portion of the map into memory and display it?

Q2. How can I constrain scrolling to the x-y plane, so that when you  
move the mouse, it only moves in the x-y direction?

Q3. How can I control memory management, so that only a portion or  
region of the image gets loaded at run-time.

A possible algorithm could be as follows: If I had a 3x3 square area  
representing the map regions and I am in the center square, the moment  
I cross the boundary of the center square, the system should load the  
next row or column regions, and unload the out-of-scope row or column.

How can I implement this algorithm using vtk classes?

Best regards,

Elvis Dowson



More information about the vtkusers mailing list