Documentation for vtkProp

vtkProp - represents an object for placement in a rendered scene

Super Class: vtkObject

Description:

vtkProp is an abstract class used to represent an entity in a rendering scene. It handles functions related to the position, orientation and scaling. It combines these instance variables into one 4x4 transformation matrix as follows: [x y z 1] = [x y z 1] Translate(-origin) Scale(scale) Rot(y) Rot(x) Rot (z) Trans(origin) Trans(position). Both vtkActor and vtkVolume are specializations of class vtkProp. The constructor defaults to: origin(0,0,0) position=(0,0,0) visibility=1 pickable=1 dragable=1 orientation=(0,0,0). No user defined matrix and no texture map.

 

See Also:

vtkActor vtkAssembly vtkVolume

 

Methods:

void vtkProp ()
void vtkProp ()
const char *GetClassName ()
void PrintSelf (unknown & ,vtkIndent )
void Render (vtkRenderer *)
void SetPosition (float ,float ,float )
void SetPosition (float *)
float *GetPosition ()
void AddPosition (float )
void AddPosition (float ,float ,float )
void SetOrigin (float ,float ,float )
void SetOrigin (float *)
float *GetOrigin ()
void SetVisibility (int )
int GetVisibility ()
void VisibilityOn ()
void VisibilityOff ()
void SetPickable (int )
int GetPickable ()
void PickableOn ()
void PickableOff ()
void SetPickMethod (const )
void SetPickMethodArgDelete (const )
void SetDragable (int )
int GetDragable ()
void DragableOn ()
void DragableOff ()
void SetUserMatrix (vtkMatrix4x4 *)
vtkMatrix4x4 *GetUserMatrix ()
vtkMatrix4x4 *GetMatrixPointer ()
void GetMatrix (vtkMatrix4x4 *)
void GetBounds (float )
float *GetBounds ()
float *GetCenter ()
float *GetXRange ()
float *GetYRange ()
float *GetZRange ()
float GetLength ()
void RotateX (float )
void RotateY (float )
void RotateZ (float )
void RotateWXYZ (float ,float ,float ,float )
void SetOrientation (float ,float ,float )
void SetOrientation (float )
float *GetOrientation ()
float *GetOrientationWXYZ ()
void AddOrientation (float ,float ,float )
void AddOrientation (float )
void Pick ()
vtkMatrix4x4 &GetMatrix ()
void GetMatrix (vtkMatrix4x4 &)

 

Detailed Method Descriptions:

All concrete subclasses must implement a Render method.

void Render (vtkRenderer *)

Set/Get/Add the position of the Prop in world coordinates.

void SetPosition (float ,float ,float )
void SetPosition (float *)
float *GetPosition ()
void AddPosition (float )
void AddPosition (float ,float ,float )

Set/Get the origin of the Prop. This is the point about which all rotations take place.

void SetOrigin (float ,float ,float )
void SetOrigin (float *)
float *GetOrigin ()

Set/Get the visibility of the Prop. Visibility is like a light switch for Props. Use it to turn them on or off.

void SetVisibility (int )
int GetVisibility ()
void VisibilityOn ()
void VisibilityOff ()

Set/Get the pickable instance variable. This determines if the Prop can be picked (typically using the mouse). Also see dragable.

void SetPickable (int )
int GetPickable ()
void PickableOn ()
void PickableOff ()

This method is invoked when an instance of vtkProp (or subclass, e.g., vtkActor) is picked by vtkPicker.

void SetPickMethod (const )
void SetPickMethodArgDelete (const )

Set/Get the value of the dragable instance variable. This determines if an Prop, once picked, can be dragged (translated) through space. This is typically done through an interactive mouse interface. This does not affect methods such as SetPosition, which will continue to work. It is just intended to prevent some Props from being dragged from within a user interface.

void SetDragable (int )
int GetDragable ()
void DragableOn ()
void DragableOff ()

In addition to the instance variables such as position and orientation, you can specify your own 4x4 transformation matrix that will get concatenated with the actor's 4x4 matrix as determined by the other instance variables. If the other instance variables such as position and orientation are left with their default values then they will result in the identity matrix. And the resulting matrix will be the user defined matrix.

void SetUserMatrix (vtkMatrix4x4 *)
vtkMatrix4x4 *GetUserMatrix ()

Return a reference to the prop's 4x4 composite matrix.

vtkMatrix4x4 *GetMatrixPointer ()
void GetMatrix (vtkMatrix4x4 *)

Get the bounds for this Prop as (Xmin,Xmax,Ymin,Ymax,Zmin,Zmax).

void GetBounds (float )
float *GetBounds ()

Get the center of the bounding box in world coordinates.

float *GetCenter ()

Get the prop's x range in world coordinates.

float *GetXRange ()

Get the prop's y range in world coordinates.

float *GetYRange ()

Get the prop's z range in world coordinates.

float *GetZRange ()

Get the length of the diagonal of the bounding box.

float GetLength ()

Rotate the prop in degrees about the X axis using the right hand rule. The axis is the prop's X axis, which can change as other rotations are performed. To rotate about the world X axis use RotateWXYZ (angle, 1, 0, 0). This rotation is applied before all others in the current transformation matrix.

void RotateX (float )

Rotate the prop in degrees about the Y axis using the right hand rule. The axis is the prop's Y axis, which can change as other rotations are performed. To rotate about the world Y axis use RotateWXYZ (angle, 0, 1, 0). This rotation is applied before all others in the current transformation matrix.

void RotateY (float )

Rotate the prop in degrees about the Z axis using the right hand rule. The axis is the prop's Z axis, which can change as other rotations are performed. To rotate about the world Z axis use RotateWXYZ (angle, 0, 0, 1). This rotation is applied before all others in the current transformation matrix.

void RotateZ (float )

Rotate the prop in degrees about an arbitrary axis specified by the last three arguments. The axis is specified in world coordinates. To rotate an about its model axes, use RotateX, RotateY, RotateZ.

void RotateWXYZ (float ,float ,float ,float )

Sets the orientation of the prop. Orientation is specified as X,Y and Z rotations in that order, but they are performed as RotateZ, RotateX, and finally RotateY.

void SetOrientation (float ,float ,float )
void SetOrientation (float )

Returns the orientation of the prop as s vector of X,Y and Z rotation. The ordering in which these rotations must be done to generate the same matrix is RotateZ, RotateX, and finally RotateY. See also SetOrientation.

float *GetOrientation ()

Returns the WXYZ orientation of the prop.

float *GetOrientationWXYZ ()

Add to the current orientation. See SetOrientation and GetOrientation for more details. This basically does a GetOrientation, adds the passed in arguments, and then calls SetOrientation.

void AddOrientation (float ,float ,float )
void AddOrientation (float )

Method invokes PickMethod() if one defined

void Pick ()

For legacy compatibility. Do not use.

vtkMatrix4x4 &GetMatrix ()