33 #ifndef vtkCompositeControlPointsItem_h 34 #define vtkCompositeControlPointsItem_h 36 #include "vtkChartsCoreModule.h" 68 ColorPointsFunction = 1,
69 OpacityPointsFunction = 2,
70 ColorAndOpacityPointsFunction = 3
85 vtkSetMacro(PointsFunction,
int);
86 vtkGetMacro(PointsFunction,
int);
111 vtkSetMacro(UseOpacityPointHandles,
bool);
112 vtkGetMacro(UseOpacityPointHandles,
bool);
128 void emitEvent(
unsigned long event,
void* params)
override;
136 void EditPoint(
float tX,
float tY)
override;
137 virtual void EditPointCurve(
vtkIdType idx);
139 void MergeTransferFunctions();
140 void SilentMergeTransferFunctions();
static vtkColorTransferControlPointsItem * New()
Creates a piecewise control points object.
bool UseOpacityPointHandles
bool MouseButtonPressEvent(const vtkContextMouseEvent &mouse) override
Mouse button down event.
Defines a 1D piecewise function.
vtkTypeUInt32 vtkMTimeType
void GetControlPoint(vtkIdType index, double *point) const override
Returns the x and y coordinates as well as the midpoint and sharpness of the control point correspond...
vtkIdType GetNumberOfPoints() const override
Return the number of points in the color transfer function.
vtkMTimeType GetControlPointsMTime() override
Must be reimplemented by subclasses to calculate the points to draw.
Class for drawing 2D primitives to a graphical context.
a vtkContextItem that draws handles around a point of a piecewise function
bool MouseDoubleClickEvent(const vtkContextMouseEvent &mouse) override
Mouse button down event.
data structure to represent mouse events.
a simple class to control print indentation
Control points for vtkCompositeFunction.
vtkPiecewiseFunction * OpacityFunction
vtkIdType AddPoint(double *newPos) override
Add a point to the function.
void EditPoint(float tX, float tY) override
vtkIdType RemovePoint(double *pos) override
Remove a point of the function.
vtkPiecewisePointHandleItem * OpacityPointHandle
Control points for vtkColorTransferFunction.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetColorTransferFunction(vtkColorTransferFunction *function)
Set the piecewise function to draw its points.
Defines a transfer function for mapping a property to an RGB color value.
bool MouseMoveEvent(const vtkContextMouseEvent &mouse) override
Mouse move event.
void SetControlPoint(vtkIdType index, double *point) override
Sets the x and y coordinates as well as the midpoint and sharpness of the control point corresponding...
void emitEvent(unsigned long event, void *params) override
void DrawPoint(vtkContext2D *painter, vtkIdType index) override
Internal function that paints a collection of points and optionally excludes some.