[vtkusers] Zoom of an actor in only one direction / change coordinate sytem spacing per actor ?
Kleistereimer
kleistereimer at gmx.de
Fri Sep 15 15:27:12 EDT 2006
hi!
i have some actors (3d-plots with x,y,z axes) and want to zoom one of
these actors in one direction only, without affecting the 'position' of
the points. (say zoom 800% in x- direction only)
so i need a kind of 'distorted' view per actor.
the right mouse interactive zoom does this, but for all 3 axes, and for
all actors.
the Actor->SetScale(x,y,z) call does a better job, it can scale one
actor in one direction only, BUT it changes the position of the
datapoints. Thus picking and axes-scales (done with vtkCubeAxesActor2D)
show wrong readings for x-position. ([0 .. 800] instead of [0 .. 1])
i want:
-the other actors should remain unzoomed.
(so i can not modify the coordinate-system spacing)
-picking points should reveal the real data.
(not the zoomed x position)
-axis-arrows should zoom to the new boundingbox (this works) and labels
should reveal the real data (this does not works, it displays the zoomed
x-data)
how to do that?
i think visualizing data and zooming them in one direction only while
preserving datapositions (this means changing the visualization-spacing)
is a common task. there must be some simple way for this... (i hope)
my workaround would be:
SetScale the data, and lie about the x-datapositions in the gui:
-roll my own axes or hack vtkCubeAxesActor2D to display the correct
data-labels. [0..1] instead of [0..800]
-patch the values returned by picking to reflect the real data.
why do i need it->
because my 3d-plots look like a plane (x axis value range extremly small
compared to y and z axis value range) so i want to x - zoom the diagram
for better visibility. changing x - units would work but is not an option.
thankyou for your help.
kl
(i already posted this as: "scaling of actors while preserving axes -
scale." i think i got it wrong with my limited english)
More information about the vtkusers
mailing list