VTK
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes
vtkCompositeControlPointsItem Class Reference

Control points for vtkCompositeFunction. More...

#include <vtkCompositeControlPointsItem.h>

Inheritance diagram for vtkCompositeControlPointsItem:
Inheritance graph
[legend]
Collaboration diagram for vtkCompositeControlPointsItem:
Collaboration graph
[legend]

List of all members.

Public Types

enum  PointsFunctionType { ColorPointsFunction = 1, OpacityPointsFunction = 2, ColorAndOpacityPointsFunction = 3 }
typedef
vtkColorTransferControlPointsItem 
Superclass

Public Member Functions

virtual int IsA (const char *type)
vtkCompositeControlPointsItemNewInstance () const
virtual void PrintSelf (ostream &os, vtkIndent indent)
virtual void SetColorTransferFunction (vtkColorTransferFunction *function)
virtual vtkIdType AddPoint (double *newPos)
virtual vtkIdType RemovePoint (double *pos)
void SetOpacityFunction (vtkPiecewiseFunction *opacity)
virtual vtkPiecewiseFunctionGetOpacityFunction ()
virtual void SetPointsFunction (int)
virtual int GetPointsFunction ()
virtual void SetUseOpacityPointHandles (bool)
virtual bool GetUseOpacityPointHandles ()
virtual bool MouseMoveEvent (const vtkContextMouseEvent &mouse)
virtual bool MouseDoubleClickEvent (const vtkContextMouseEvent &mouse)
virtual bool MouseButtonPressEvent (const vtkContextMouseEvent &mouse)

Static Public Member Functions

static int IsTypeOf (const char *type)
static
vtkCompositeControlPointsItem
SafeDownCast (vtkObjectBase *o)
static
vtkCompositeControlPointsItem
New ()

Protected Member Functions

virtual vtkObjectBaseNewInstanceInternal () const
 vtkCompositeControlPointsItem ()
virtual ~vtkCompositeControlPointsItem ()
virtual void emitEvent (unsigned long event, void *params)
virtual unsigned long int GetControlPointsMTime ()
virtual vtkIdType GetNumberOfPoints () const
virtual void DrawPoint (vtkContext2D *painter, vtkIdType index)
virtual void GetControlPoint (vtkIdType index, double *pos) const
virtual void SetControlPoint (vtkIdType index, double *point)
virtual void EditPoint (float tX, float tY)
virtual void EditPointCurve (vtkIdType idx)
void MergeTransferFunctions ()
void SilentMergeTransferFunctions ()

Protected Attributes

int PointsFunction
vtkPiecewiseFunctionOpacityFunction
vtkPiecewisePointHandleItemOpacityPointHandle
bool UseOpacityPointHandles

Detailed Description

Control points for vtkCompositeFunction.

vtkCompositeControlPointsItem draws the control points of a vtkPiecewiseFunction and a vtkColorTransferFunction.

See also:
vtkControlPointsItem vtkColorTransferControlPointsItem vtkCompositeTransferFunctionItem vtkPiecewisePointHandleItem
Tests:
vtkCompositeControlPointsItem (Tests)

Definition at line 41 of file vtkCompositeControlPointsItem.h.


Member Typedef Documentation

Reimplemented from vtkColorTransferControlPointsItem.

Definition at line 45 of file vtkCompositeControlPointsItem.h.


Member Enumeration Documentation

Enumerator:
ColorPointsFunction 
OpacityPointsFunction 
ColorAndOpacityPointsFunction 

Definition at line 60 of file vtkCompositeControlPointsItem.h.


Constructor & Destructor Documentation


Member Function Documentation

static int vtkCompositeControlPointsItem::IsTypeOf ( const char *  name) [static]

Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkColorTransferControlPointsItem.

virtual int vtkCompositeControlPointsItem::IsA ( const char *  name) [virtual]

Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkColorTransferControlPointsItem.

Reimplemented from vtkColorTransferControlPointsItem.

virtual vtkObjectBase* vtkCompositeControlPointsItem::NewInstanceInternal ( ) const [protected, virtual]

Reimplemented from vtkColorTransferControlPointsItem.

Reimplemented from vtkColorTransferControlPointsItem.

virtual void vtkCompositeControlPointsItem::PrintSelf ( ostream &  os,
vtkIndent  indent 
) [virtual]

Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from vtkColorTransferControlPointsItem.

Creates a piecewise control points object

Reimplemented from vtkColorTransferControlPointsItem.

Set the color transfer function to draw its points

Reimplemented from vtkColorTransferControlPointsItem.

Utility function that calls SetPiecewiseFunction()

Utility function that calls SetPiecewiseFunction()

PointsFunction controls wether the points represent the ColorTransferFunction, OpacityTransferFunction or both. If ColorPointsFunction, only the points of the ColorTransfer function are used. If OpacityPointsFunction, only the points of the Opacity function are used If ColorAndOpacityPointsFunction, the points of both functions are shared by both functions. ColorAndOpacityPointsFunction by default. Note: Set the mode before the functions are set. ColorPointsFunction is not fully supported.

PointsFunction controls wether the points represent the ColorTransferFunction, OpacityTransferFunction or both. If ColorPointsFunction, only the points of the ColorTransfer function are used. If OpacityPointsFunction, only the points of the Opacity function are used If ColorAndOpacityPointsFunction, the points of both functions are shared by both functions. ColorAndOpacityPointsFunction by default. Note: Set the mode before the functions are set. ColorPointsFunction is not fully supported.

virtual vtkIdType vtkCompositeControlPointsItem::AddPoint ( double newPos) [virtual]

Add a point to the function. Returns the index of the point (0 based), or -1 on error. Subclasses should reimplement this function to do the actual work.

Reimplemented from vtkColorTransferControlPointsItem.

Remove a point of the function. Returns the index of the point (0 based), or -1 on error. Subclasses should reimplement this function to do the actual work.

Reimplemented from vtkColorTransferControlPointsItem.

If UseOpacityPointHandles is true, when the current point is double clicked, a vtkPiecewisePointHandleItem will show up so that the sharpness and mid point can be adjusted in the scene with those handles False by default.

If UseOpacityPointHandles is true, when the current point is double clicked, a vtkPiecewisePointHandleItem will show up so that the sharpness and mid point can be adjusted in the scene with those handles False by default.

virtual bool vtkCompositeControlPointsItem::MouseMoveEvent ( const vtkContextMouseEvent mouse) [virtual]

Mouse move event. To take care of some special Key stroke

Reimplemented from vtkControlPointsItem.

Mouse move event. To take care of some special Key stroke

Reimplemented from vtkControlPointsItem.

Mouse move event. To take care of some special Key stroke

Reimplemented from vtkControlPointsItem.

virtual void vtkCompositeControlPointsItem::emitEvent ( unsigned long  event,
void *  params 
) [protected, virtual]

Reimplemented from vtkColorTransferControlPointsItem.

virtual unsigned long int vtkCompositeControlPointsItem::GetControlPointsMTime ( ) [protected, virtual]

Must be reimplemented by subclasses to calculate the points to draw. It's subclass responsibility to call ComputePoints() via the callback

Reimplemented from vtkColorTransferControlPointsItem.

virtual vtkIdType vtkCompositeControlPointsItem::GetNumberOfPoints ( ) const [protected, virtual]

Return the number of points in the color transfer function.

Reimplemented from vtkColorTransferControlPointsItem.

virtual void vtkCompositeControlPointsItem::DrawPoint ( vtkContext2D painter,
vtkIdType  index 
) [protected, virtual]

Internal function that paints a collection of points and optionally excludes some.

Reimplemented from vtkColorTransferControlPointsItem.

virtual void vtkCompositeControlPointsItem::GetControlPoint ( vtkIdType  index,
double point 
) const [protected, virtual]

Returns the x and y coordinates as well as the midpoint and sharpness of the control point corresponding to the index. Note: The y (point[1]) is always 0.5

Reimplemented from vtkColorTransferControlPointsItem.

virtual void vtkCompositeControlPointsItem::SetControlPoint ( vtkIdType  index,
double point 
) [protected, virtual]

Sets the x and y coordinates as well as the midpoint and sharpness of the control point corresponding to the index. Changing the y has no effect, it will always be 0.5

Reimplemented from vtkColorTransferControlPointsItem.

virtual void vtkCompositeControlPointsItem::EditPoint ( float  tX,
float  tY 
) [protected, virtual]

Reimplemented from vtkColorTransferControlPointsItem.

virtual void vtkCompositeControlPointsItem::EditPointCurve ( vtkIdType  idx) [protected, virtual]

Member Data Documentation

Definition at line 122 of file vtkCompositeControlPointsItem.h.

Definition at line 123 of file vtkCompositeControlPointsItem.h.

Definition at line 124 of file vtkCompositeControlPointsItem.h.

Definition at line 125 of file vtkCompositeControlPointsItem.h.


The documentation for this class was generated from the following file: