[vtkusers] Transforms

Reinhold Füreder R.Fureder at exeter.ac.uk
Tue Sep 14 10:05:14 EDT 2004


Dear Sean,

Probably my previous posting should have been slightly longer:

> I think you could use vtkProp3D::GetMatrix(vtkMatrix4x4 *m) 
> -- vtkActor is inheriting from vtkProp3D -- and apply it on 
> the original polydata by means of vtkTransformPolyDataFilter 
> and vtkTransform.

(1) Inheritance: vtkLinearTransform---<|---vtkTransform.

(2) Use vtkTransform::SetMatrix (vtkMatrix4x4 *matrix) for the
"conversion".

HTH Reinhold

> -----Original Message-----
> From: vtkusers-bounces at vtk.org 
> [mailto:vtkusers-bounces at vtk.org] On Behalf Of Sean Richards
> Sent: Tuesday, September 14, 2004 3:34 PM
> To: vtkusers at vtk.org
> Subject: [vtkusers] Transforms
> 
> 
> Hello,
> 
> I have a situation where I move actors around the screen. 
> Later, I need to apply the transformation the actor has 
> undergone to the original data.
> 
> I have found the method (in Prop3D)
> 
> virtual void  GetMatrix (vtkMatrix4x4 *m) 
> 
> so I can use this to gain access to the transformation for 
> the actor. The problem is how to apply this to the original data.
> 
> I have found
> 
> vtkMatrixToLinearTransform
> 
> but cannot seem to get this to convert a vtkMatrix4x4 to a 
> vtkAbstractTransform
> 
> I need the vtkAbstractTransform so I can use
> 
> vtkTransformPolyDataFilter
> 
> which I think should be able to transform the original polydata.
> 
> If anyone knows how to apply the actor transformation to the 
> original data, I would greatly appreciate some help.
> 
> Thanks!!
> 
> Sean
> 




More information about the vtkusers mailing list