17 #include "vtkChartsCoreModule.h"
27 VTK_ABI_NAMESPACE_BEGIN
56 void SetGeometry(
const vtkRectf& bounds);
70 vtkSetMacro(Angle,
double);
75 void SetAroundX(
bool isX);
90 virtual void SetAxis(
int axisIndex,
vtkAxis* axis);
141 vtkSetMacro(EnsureOuterEdgeAxisLabelling,
bool);
147 vtkSetMacro(AutoRotate,
bool);
153 void SetDecorateAxes(
bool b);
159 void SetFitToScene(
bool b);
179 virtual bool RemovePlot(
vtkPlot3D* plot);
190 void RecalculateBounds();
197 void RecalculateTransform();
229 void SetClippingPlanesEnabled(
bool);
234 vtkGetMacro(ClippingPlanesEnabled,
bool);
239 vtkSetMacro(ScaleBoxWithPlot,
bool);
244 vtkGetMacro(ScaleBoxWithPlot,
bool);
294 virtual void CalculateTransforms();
312 bool Rotate(RotateDirection rotateDirection);
362 bool CheckForSceneResize();
377 void ScaleDownAxes();
382 void ZoomAxes(
int delta);
388 void InitializeAxesBoundaryPoints();
399 void InitializeFutureBox();
404 void ComputeDataBounds();
415 void DetermineWhichAxesToLabel();
421 void NewDetermineWhichAxesToLabel();
427 void LegacyDetermineWhichAxesToLabel();
443 void GetOffsetForAxisLabel(
int axis,
float* bounds,
float*
offset);
450 double CalculateNiceMinMax(
double& min,
double&
max,
int axis);
455 void GetClippingPlaneEquation(
int i,
double* planeEquation);
460 std::size_t GetMarginLeft()
const;
465 std::size_t GetMarginBottom()
const;
470 std::size_t GetPlotWidth()
const;
475 std::size_t GetPlotHeight()
const;
484 } SizeStrategy = USE_GEOMETRY;
501 std::vector<vtkSmartPointer<vtkAxis>>
Axes;
507 bool AutoRotate =
false;
525 bool DrawAxesDecoration =
true;
531 bool FitToScene =
true;
635 bool EnsureOuterEdgeAxisLabelling =
false;
645 float AxesBoundaryPoints[8][3];
651 float TickLabelOffset[3][2];
675 int DirectionToData[3];
680 double DataBounds[4];
685 bool ClippingPlanesEnabled =
true;
690 bool ScaleBoxWithPlot =
true;
697 VTK_ABI_NAMESPACE_END
int SceneHeight
The height of the scene, as of the most recent call to Paint().
Wrapper around std::string to keep symbols short.
data structure to represent key events.
int SceneWidth
The weight of the scene, as of the most recent call to Paint().
AxisState
The state of an axis.
vtkNew< vtkTransform > PlotTransform
This transform translates and scales the plots' data points so that they appear within the axes of th...
base class for items that are part of a vtkContextScene.
virtual bool MouseButtonPressEvent(const vtkContextMouseEvent &mouse)
Mouse button down event Return true if the item holds the event, false if the event can be propagated...
vtkNew< vtkTransform > Scale
This transform keeps track of how the data points have been scaled (zoomed in or zoomed out) within t...
virtual bool Paint(vtkContext2D *painter)
Paint event for the item, called whenever the item needs to be drawn.
maintain a list of planes
vtkNew< vtkTransform > Rotation
This transform keeps track of how the chart has been rotated.
std::vector< vtkIdType > FreePlaces
These plots got removed (from Plots), try to reuse the free spot.
vtkNew< vtkTextProperty > AxesTextProperty
The text properties of the axes.
std::vector< vtkSmartPointer< vtkAxis > > Axes
The 3 axes of this chart.
Class for drawing 2D primitives to a graphical context.
virtual bool MouseWheelEvent(const vtkContextMouseEvent &mouse, int delta)
Mouse wheel event, positive delta indicates forward movement of the wheel.
takes care of drawing 2D axes
data structure to represent mouse events.
a simple class to control print indentation
std::string YAxisLabel
The label for the Y Axis.
std::string ZAxisLabel
The label for the Z Axis.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
provides a pen that draws the outlines of shapes drawn by vtkContext2D.
vtkNew< vtkTransform > Translation
This transform keeps track of how the data points have been panned within the chart.
vtkSmartPointer< vtkAnnotationLink > Link
This link is used to share selected points with other classes.
represent text properties.
virtual bool KeyPressEvent(const vtkContextKeyEvent &key)
Key press event.
dynamic, self-adjusting array of unsigned char
std::vector< vtkPlot3D * > Plots
The plots that are drawn within this chart.
A table, which contains similar-typed columns of data.
vtkNew< vtkPen > AxisPen
This is the pen that is used to draw the axes.
Direction
The direction to data from an axis.
virtual bool MouseMoveEvent(const vtkContextMouseEvent &mouse)
Mouse move event.
vtkNew< vtkTransform > ContextTransform
This is the transform that is applied when rendering data from the plots.
virtual bool Hit(const vtkContextMouseEvent &mouse)
Return true if the supplied x, y coordinate is inside the item.
std::string XAxisLabel
The label for the X Axis.
Abstract class for 3D plots.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
vtkNew< vtkPlaneCollection > BoundingCube
The six planes that define the bounding cube of our 3D axes.
RotateDirection
Rotation directions.
vtkNew< vtkTransform > BoxScale
This transform keeps track of how the axes have been scaled (zoomed in or zoomed out).
Factory class for drawing 3D XYZ charts.
vtkNew< vtkTransform > FutureBox
This transform is initialized as a copy of Box.
virtual void Update()
Perform any updates to the item that may be necessary before rendering.
An algorithm for linking annotations among objects.
vtkNew< vtkTransform > FutureBoxScale
This transform keeps track of the Scale of the FutureBox transform.
vtkNew< vtkTransform > Box
This is the transform that is applied when rendering data from the plots.
vtkNew< vtkPen > Pen
This is the pen that is used to draw data from the plots.
Class for drawing 3D primitives to a graphical context.