[vtkusers] selective scaling in vtkAssembly
Dean Inglis
dean.inglis at camris.ca
Mon Mar 19 17:14:54 EDT 2007
Hi Angela!
I am tried something like that, but it fails for this
case. I am trying to change the appearance of
vtkCheckerboardRepresentation which uses 4 internal vtkSliderWidgets
with their representations being vtkSliderRepresentation3D.
For images that have rectangular shapes (not square), two
of the sliders will appear scaled smaller than the other two
since they scale according to length. I was trying to interrupt
that scaling by a callback but this is not the "right" way
to do it apparently.
thnx,
Dean
-----Original Message-----
From: Noecker, Angela M. [mailto:noeckera at ccf.org]
Sent: Monday, March 19, 2007 2:03 PM
To: Dean Inglis
Subject: RE: [vtkusers] selective scaling in vtkAssembly
Hey Dean!
couldn't you do something like the following:?
apply actor2_transform to actor2
actor2_transform Scale [expr wx_different/wx] 1 1
Then you effectively undo the x-component of the scale applied to the
assembly and replace it with the scale you want to have applied to actor2.
Angela
From: vtkusers-bounces+noeckera=ccf.org at vtk.org on behalf of Dean Inglis
Sent: Mon 3/19/2007 1:56 PM
To: vtkusers archive
Subject: [vtkusers] selective scaling in vtkAssembly
I have an assembly made of actors
defined on a unit length scale (0-1)
which are then scaled up to the size they
need to be in the world. However, I want
one of the actors to have a different X scale
factor. e.g.:
actor1->SetScale(x1,y1,z1);
actor2->SetScale(x2,y2,z2);
...
actorN->SetScale(xN,yN,zN);
assembly->SetScale(wx, wy, wz)
but for only actor2, I want the assembly to
apply a scale
assembly->SetScale(wx_different, wy, wz)
Any ideas on how to do this?
thanks,
Dean
_______________________________________________
This is the private VTK discussion list.
Please keep messages on-topic. Check the FAQ at:
http://www.vtk.org/Wiki/VTK_FAQ
Follow this link to subscribe/unsubscribe:
http://www.vtk.org/mailman/listinfo/vtkusers
Cleveland Clinic is ranked one of the top 3 hospitals in
America by U.S.News & World Report. Visit us online at
http://www.clevelandclinic.org for a complete listing of
our services, staff and locations.
Confidentiality Note: This message is intended for use
only by the individual or entity to which it is addressed
and may contain information that is privileged,
confidential, and exempt from disclosure under applicable
law. If the reader of this message is not the intended
recipient or the employee or agent responsible for
delivering the message to the intended recipient, you are
hereby notified that any dissemination, distribution or
copying of this communication is strictly prohibited. If
you have received this communication in error, please
contact the sender immediately and destroy the material in
its entirety, whether electronic or hard copy. Thank you.
===================================
More information about the vtkusers
mailing list