69#include "vtkRenderingAnnotationModule.h"
73VTK_ABI_NAMESPACE_BEGIN
126 vtkSetVector2Macro(Range,
double);
127 vtkGetVectorMacro(Range,
double, 2);
136 void SetBounds(
double xmin,
double xmax,
double ymin,
double ymax,
double zmin,
double zmax);
138 void GetBounds(
double bounds[6]);
145 vtkSetStringMacro(LabelFormat);
146 vtkGetStringMacro(LabelFormat);
157 vtkSetMacro(UseTextActor3D,
bool);
158 vtkGetMacro(UseTextActor3D,
bool);
166 vtkSetMacro(MinorTicksVisible,
bool);
167 vtkGetMacro(MinorTicksVisible,
bool);
168 vtkBooleanMacro(MinorTicksVisible,
bool);
175 void SetTitle(const
char* t);
176 vtkGetStringMacro(Title);
183 void SetExponent(const
char* t);
184 vtkGetStringMacro(Exponent);
192 vtkSetMacro(MajorTickSize,
double);
193 vtkGetMacro(MajorTickSize,
double);
201 vtkSetMacro(MinorTickSize,
double);
202 vtkGetMacro(MinorTickSize,
double);
207 VTK_TICKS_INSIDE = 0,
208 VTK_TICKS_OUTSIDE = 1,
232 vtkSetMacro(AxisVisibility,
bool);
233 vtkGetMacro(AxisVisibility,
bool);
234 vtkBooleanMacro(AxisVisibility,
bool);
242 vtkSetMacro(TickVisibility,
bool);
243 vtkGetMacro(TickVisibility,
bool);
244 vtkBooleanMacro(TickVisibility,
bool);
252 vtkSetMacro(LabelVisibility,
bool);
253 vtkGetMacro(LabelVisibility,
bool);
254 vtkBooleanMacro(LabelVisibility,
bool);
262 vtkSetMacro(TitleVisibility,
bool);
263 vtkGetMacro(TitleVisibility,
bool);
264 vtkBooleanMacro(TitleVisibility,
bool);
272 vtkSetMacro(ExponentVisibility,
bool);
273 vtkGetMacro(ExponentVisibility,
bool);
274 vtkBooleanMacro(ExponentVisibility,
bool);
282 vtkSetMacro(LastMajorTickPointCorrection,
bool);
283 vtkGetMacro(LastMajorTickPointCorrection,
bool);
284 vtkBooleanMacro(LastMajorTickPointCorrection,
bool);
290 VTK_ALIGN_BOTTOM = 1,
291 VTK_ALIGN_POINT1 = 2,
302 vtkGetMacro(TitleAlignLocation,
int);
312 vtkGetMacro(ExponentLocation,
int);
392 vtkSetMacro(DrawGridlines,
bool);
393 vtkGetMacro(DrawGridlines,
bool);
394 vtkBooleanMacro(DrawGridlines,
bool);
404 vtkSetMacro(DrawGridlinesOnly,
bool);
405 vtkGetMacro(DrawGridlinesOnly,
bool);
406 vtkBooleanMacro(DrawGridlinesOnly,
bool);
409 vtkSetMacro(DrawGridlinesLocation,
int);
410 vtkGetMacro(DrawGridlinesLocation,
int);
417 vtkSetMacro(DrawInnerGridlines,
bool);
418 vtkGetMacro(DrawInnerGridlines,
bool);
419 vtkBooleanMacro(DrawInnerGridlines,
bool);
427 vtkSetMacro(GridlineXLength,
double);
428 vtkGetMacro(GridlineXLength,
double);
429 vtkSetMacro(GridlineYLength,
double);
430 vtkGetMacro(GridlineYLength,
double);
431 vtkSetMacro(GridlineZLength,
double);
432 vtkGetMacro(GridlineZLength,
double);
440 vtkSetMacro(DrawGridpolys,
bool);
441 vtkGetMacro(DrawGridpolys,
bool);
442 vtkBooleanMacro(DrawGridpolys,
bool);
457 vtkSetClampMacro(
AxisType,
int, VTK_AXIS_TYPE_X, VTK_AXIS_TYPE_Z);
466 VTK_AXIS_POS_MINMIN = 0,
467 VTK_AXIS_POS_MINMAX = 1,
468 VTK_AXIS_POS_MAXMAX = 2,
469 VTK_AXIS_POS_MAXMIN = 3
477 vtkSetMacro(Log,
bool);
478 vtkGetMacro(Log,
bool);
479 vtkBooleanMacro(Log,
bool);
491 vtkSetClampMacro(
AxisPosition,
int, VTK_AXIS_POS_MINMIN, VTK_AXIS_POS_MAXMIN);
539 vtkSetMacro(MinorStart,
double);
540 vtkGetMacro(MinorStart,
double);
543 vtkSetMacro(DeltaMinor,
double);
544 vtkGetMacro(DeltaMinor,
double);
556 vtkSetMacro(MinorRangeStart,
double);
557 vtkGetMacro(MinorRangeStart,
double);
558 vtkSetMacro(MajorRangeStart,
double);
559 vtkGetMacro(MajorRangeStart,
double);
567 vtkSetMacro(DeltaRangeMinor,
double);
568 vtkGetMacro(DeltaRangeMinor,
double);
569 vtkSetMacro(DeltaRangeMajor,
double);
570 vtkGetMacro(DeltaRangeMajor,
double);
623 vtkGetMacro(NumberOfLabelsBuilt,
int);
631 vtkSetMacro(CalculateTitleOffset,
bool);
632 vtkGetMacro(CalculateTitleOffset,
bool);
633 vtkBooleanMacro(CalculateTitleOffset,
bool);
641 vtkSetMacro(CalculateLabelOffset,
bool);
642 vtkGetMacro(CalculateLabelOffset,
bool);
643 vtkBooleanMacro(CalculateLabelOffset,
bool);
651 vtkSetMacro(Use2DMode,
bool);
652 vtkGetMacro(Use2DMode,
bool);
660 vtkSetMacro(VerticalOffsetXTitle2D,
double);
661 vtkGetMacro(VerticalOffsetXTitle2D,
double);
669 vtkSetMacro(HorizontalOffsetYTitle2D,
double);
670 vtkGetMacro(HorizontalOffsetYTitle2D,
double);
678 vtkSetMacro(SaveTitlePosition,
int);
679 vtkGetMacro(SaveTitlePosition,
int);
687 vtkSetVector3Macro(AxisBaseForX,
double);
688 vtkGetVector3Macro(AxisBaseForX,
double);
696 vtkSetVector3Macro(AxisBaseForY,
double);
697 vtkGetVector3Macro(AxisBaseForY,
double);
705 vtkSetVector3Macro(AxisBaseForZ,
double);
706 vtkGetVector3Macro(AxisBaseForZ,
double);
714 vtkSetMacro(AxisOnOrigin,
bool);
715 vtkGetMacro(AxisOnOrigin,
bool);
723 vtkSetMacro(ScreenSize,
double);
724 vtkGetMacro(ScreenSize,
double);
732 vtkSetMacro(LabelOffset,
double);
733 vtkGetMacro(LabelOffset,
double);
741 vtkSetMacro(ExponentOffset,
double);
742 vtkGetMacro(ExponentOffset,
double);
754 void SetTitleOffset(
double titleOffsetY);
756 double GetTitleOffset();
757 vtkSetVector2Macro(TitleOffset,
double);
759 void GetTitleOffset(
double& titleOffsetX,
double& titleOffsetY);
766 char* Title =
nullptr;
767 char* Exponent =
nullptr;
768 char* LabelFormat =
nullptr;
769 double Range[2] = { 0.0, 1.0 };
770 double LastRange[2] = { -1.0, -1.0 };
771 bool UseTextActor3D =
false;
772 int NumberOfLabelsBuilt = 0;
773 bool MinorTicksVisible =
true;
774 bool LastMinorTicksVisible =
true;
787 int TitleAlignLocation = VTK_ALIGN_BOTTOM;
793 int ExponentLocation = VTK_ALIGN_POINT2;
795 bool DrawGridlines =
false;
796 bool DrawGridlinesOnly =
false;
797 bool LastDrawGridlines =
false;
798 int DrawGridlinesLocation = 0;
799 int LastDrawGridlinesLocation = 0;
800 double GridlineXLength = 1.0;
801 double GridlineYLength = 1.0;
802 double GridlineZLength = 1.0;
804 bool DrawInnerGridlines =
false;
805 bool LastDrawInnerGridlines =
false;
807 bool DrawGridpolys =
false;
808 bool LastDrawGridpolys =
false;
810 bool AxisVisibility =
true;
811 bool TickVisibility =
true;
812 bool LastTickVisibility =
true;
813 bool LabelVisibility =
true;
814 bool TitleVisibility =
true;
815 bool ExponentVisibility =
false;
816 bool LastMajorTickPointCorrection =
false;
823 double AxisBaseForX[3] = { 1.0, 0.0, 0.0 };
824 double AxisBaseForY[3] = { 0.0, 1.0, 0.0 };
825 double AxisBaseForZ[3] = { 0.0, 0.0, 1.0 };
831 void TransformBounds(
vtkViewport*,
double bnds[6]);
842 void RotateActor2DFromAxisProjection(
vtkTextActor* pActor2D);
860 void BuildTitle(
bool);
866 void BuildExponent(
bool force);
868 void BuildExponent2D(
vtkViewport* viewport,
bool force);
872 void SetAxisPointsAndLines();
874 bool BuildTickPoints(
double p1[3],
double p2[3],
bool force);
877 void BuildMajorTicks(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
880 void BuildMajorTicksLog(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
883 void BuildMinorTicks(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
886 void BuildMinorTicksLog(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
888 void BuildAxisGridLines(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
890 bool TickVisibilityChanged();
895 bool BoundsDisplayCoordinateChanged(
vtkViewport* viewport);
900 double MajorTickSize = 1.0;
901 double MinorTickSize = 0.5;
904 double MajorStart[3] = { 0.0, 0.0, 0.0 };
905 double DeltaMajor[3] = { 1.0, 1.0, 1.0 };
906 double MinorStart = 0.0;
907 double DeltaMinor = 1.0;
910 double MajorRangeStart = 0.0;
911 double MinorRangeStart = 0.0;
916 double DeltaRangeMinor = 1.0;
921 double DeltaRangeMajor = 1.0;
923 int LastAxisPosition = -1;
924 int LastTickLocation = -1;
988 bool AxisOnOrigin =
false;
990 bool AxisHasZeroLength =
false;
992 bool CalculateTitleOffset =
false;
993 bool CalculateLabelOffset =
false;
998 bool Use2DMode =
false;
1004 double VerticalOffsetXTitle2D = -40;
1010 double HorizontalOffsetYTitle2D = -50;
1018 int SaveTitlePosition = 0;
1023 double TitleConstantPosition[2] = { 0.0, 0.0 };
1028 bool NeedBuild2D =
false;
1030 double LastMinDisplayCoordinate[3] = { 0.0, 0.0, 0.0 };
1031 double LastMaxDisplayCoordinate[3] = { 0.0, 0.0, 0.0 };
1032 double TickVector[3] = { 0.0, 0.0, 0.0 };
1037 double ScreenSize = 10.0;
1043 double LabelOffset = 30.0;
1044 double TitleOffset[2] = { 20.0, 20.0 };
1045 double ExponentOffset = 20.0;
1049VTK_ABI_NAMESPACE_END
represents an object (geometry & properties) in a rendered scene
Create an axis with tick marks and labels.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetTickLocationToBoth()
void SetAxisPositionToMinMax()
virtual void SetPoint2(double x, double y, double z)
Specify the position of the second point defining the axis.
virtual void SetCamera(vtkCamera *)
Set/Get the camera for this axis.
virtual void SetPoint2(double x[3])
Specify the position of the second point defining the axis.
void SetDeltaMajor(int axis, double value)
Set/Get the starting position for minor and major tick points, and the delta values that determine th...
void SetAxisMainLineProperty(vtkProperty *)
Get/Set main line axis actor property.
virtual double * GetPoint1()
Specify the position of the first point defining the axis.
vtkProperty * GetGridlinesProperty()
Get/Set gridlines actor property (outer grid lines)
void SetBounds(const double bounds[6])
Set or get the bounds for this Actor as (Xmin,Xmax,Ymin,Ymax,Zmin,Zmax).
int RenderOverlay(vtkViewport *viewport) override
Draw the axis.
vtkTypeBool HasTranslucentPolygonalGeometry() override
Draw the axis.
double ComputeMaxLabelLength(const double[3])
double GetMajorStart(int axis)
Set/Get the starting position for minor and major tick points, and the delta values that determine th...
void SetGridlinesProperty(vtkProperty *)
Get/Set gridlines actor property (outer grid lines)
void SetAxisTypeToZ()
Set/Get the type of this axis.
vtkProperty * GetGridpolysProperty()
Get/Set gridPolys actor property (grid quads)
virtual void SetLabelTextProperty(vtkTextProperty *p)
Set/Get the axis labels text property.
vtkAxisFollower ** GetLabelActors()
Get label actors responsigle for drawing label text.
virtual void SetExponentLocation(int location)
Get/Set the location of the Detached Exponent related to the axis.
vtkCamera * GetCamera()
Set/Get the camera for this axis.
virtual vtkCoordinate * GetPoint2Coordinate()
Specify the position of the second point defining the axis.
vtkProperty * GetInnerGridlinesProperty()
Get/Set inner gridlines actor property.
void SetAxisPositionToMinMin()
double GetDeltaMajor(int axis)
Set/Get the starting position for minor and major tick points, and the delta values that determine th...
double * GetBounds() override
Set or get the bounds for this Actor as (Xmin,Xmax,Ymin,Ymax,Zmin,Zmax).
vtkTextProperty * GetLabelTextProperty()
Set/Get the axis labels text property.
void SetLabelScale(int labelIndex, double scale)
virtual void SetPoint1(double x[3])
Specify the position of the first point defining the axis.
void SetAxisLinesProperty(vtkProperty *)
Get/Set axis actor property (axis and its ticks) (kept for compatibility)
void SetInnerGridlinesProperty(vtkProperty *)
Get/Set inner gridlines actor property.
vtkProperty * GetAxisMajorTicksProperty()
Get/Set axis actor property (axis and its ticks)
void SetAxisMajorTicksProperty(vtkProperty *)
Get/Set axis actor property (axis and its ticks)
void SetLabelScale(double scale)
void SetTickLocationToOutside()
void SetBounds(double xmin, double xmax, double ymin, double ymax, double zmin, double zmax)
Set or get the bounds for this Actor as (Xmin,Xmax,Ymin,Ymax,Zmin,Zmax).
void BuildAxis(vtkViewport *viewport, bool)
virtual double * GetPoint2()
Specify the position of the second point defining the axis.
void SetAxisTypeToY()
Set/Get the type of this axis.
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this actor.
int RenderOpaqueGeometry(vtkViewport *viewport) override
Draw the axis.
void SetAxisTypeToX()
Set/Get the type of this axis.
void SetTitleScale(double scale)
virtual void SetTitleAlignLocation(int location)
Get/Set the alignment of the title related to the axis.
vtkProperty * GetAxisMainLineProperty()
Get/Set main line axis actor property.
virtual void SetTitleTextProperty(vtkTextProperty *p)
Set/Get the axis title text property.
double ComputeTitleLength(const double[3])
void SetAxisPositionToMaxMin()
virtual vtkCoordinate * GetPoint1Coordinate()
Specify the position of the first point defining the axis.
virtual int RenderTranslucentGeometry(vtkViewport *viewport)
Draw the axis.
vtkProp3DAxisFollower ** GetLabelProps3D()
Get label actors responsigle for drawing label text.
void SetTickLocationToInside()
void SetLabels(vtkStringArray *labels)
vtkProperty * GetAxisMinorTicksProperty()
Get/Set axis actor property (axis and its ticks)
vtkTextProperty * GetTitleTextProperty()
Set/Get the axis title text property.
void SetAxisPositionToMaxMax()
virtual void SetPoint1(double x, double y, double z)
Specify the position of the first point defining the axis.
void SetAxisMinorTicksProperty(vtkProperty *)
Get/Set axis actor property (axis and its ticks)
static vtkAxisActor * New()
Instantiate object.
void SetMajorStart(int axis, double value)
Set/Get the starting position for minor and major tick points, and the delta values that determine th...
vtkProperty * GetAxisLinesProperty()
Get/Set axis actor property (axis and its ticks) (kept for compatibility)
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
Draw the axis.
void SetGridpolysProperty(vtkProperty *)
Get/Set gridPolys actor property (grid quads)
a subclass of vtkFollower that ensures that data is always parallel to the axis defined by a vtkAxisA...
a virtual camera for 3D rendering
perform coordinate transformation, and represent position, in a variety of vtk coordinate systems
a subclass of actor that always faces the camera
a simple class to control print indentation
Allocate and hold a VTK object.
represent and manipulate 3D points
map vtkPolyData to graphics primitives
concrete dataset represents vertices, lines, polygons, and triangle strips
a subclass of vtkProp3DFollower that ensures that data is always parallel to the axis defined by a vt...
represent surface properties of a 2D image
represent surface properties of a geometric object
Hold a reference to a vtkObjectBase instance.
a vtkAbstractArray subclass for strings
An actor that displays text.
An actor that displays text.
represent text properties.
record modification and/or execution time
abstract specification for Viewports
window superclass for vtkRenderWindow
#define VTK_DEPRECATED_IN_9_3_0(reason)
#define VTK_SIZEHINT(...)