VTK  9.4.20241227
vtkAxisActor.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
63#ifndef vtkAxisActor_h
64#define vtkAxisActor_h
65
66#include "vtkActor.h"
67#include "vtkNew.h" // For vtkNew
68#include "vtkRenderingAnnotationModule.h" // For export macro
69#include "vtkSmartPointer.h" // For vtkSmartPointer
70#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
71
72VTK_ABI_NAMESPACE_BEGIN
73class vtkAxisFollower;
74class vtkCamera;
75class vtkCoordinate;
76class vtkFollower;
77class vtkPoints;
78class vtkPolyData;
81class vtkProperty2D;
82class vtkStringArray;
83class vtkTextActor;
84class vtkTextActor3D;
85class vtkTextProperty;
86class vtkVectorText;
87
88class VTKRENDERINGANNOTATION_EXPORT VTK_MARSHALAUTO vtkAxisActor : public vtkActor
89{
90public:
91 vtkTypeMacro(vtkAxisActor, vtkActor);
92 void PrintSelf(ostream& os, vtkIndent indent) override;
93
97 static vtkAxisActor* New();
98
100
104 virtual void SetPoint1(double x[3]) { this->SetPoint1(x[0], x[1], x[2]); }
105 virtual void SetPoint1(double x, double y, double z);
106 virtual double* GetPoint1();
108
110
114 virtual void SetPoint2(double x[3]) { this->SetPoint2(x[0], x[1], x[2]); }
115 virtual void SetPoint2(double x, double y, double z);
116 virtual double* GetPoint2();
118
120
125 vtkSetVector2Macro(Range, double);
126 vtkGetVectorMacro(Range, double, 2);
128
130
134 void SetBounds(const double bounds[6]);
135 void SetBounds(double xmin, double xmax, double ymin, double ymax, double zmin, double zmax);
136 double* GetBounds() VTK_SIZEHINT(6) override;
137 void GetBounds(double bounds[6]);
139
141
144 vtkSetStringMacro(LabelFormat);
145 vtkGetStringMacro(LabelFormat);
147
149
156 vtkSetMacro(UseTextActor3D, bool);
157 vtkGetMacro(UseTextActor3D, bool);
159
161
165 vtkSetMacro(MinorTicksVisible, bool);
166 vtkGetMacro(MinorTicksVisible, bool);
167 vtkBooleanMacro(MinorTicksVisible, bool);
169
171
174 void SetTitle(const char* t);
175 vtkGetStringMacro(Title);
177
179
182 void SetExponent(const char* t);
183 vtkGetStringMacro(Exponent);
185
187
191 vtkSetMacro(MajorTickSize, double);
192 vtkGetMacro(MajorTickSize, double);
194
196
200 vtkSetMacro(MinorTickSize, double);
201 vtkGetMacro(MinorTickSize, double);
203
205 {
206 VTK_TICKS_INSIDE = 0,
207 VTK_TICKS_OUTSIDE = 1,
208 VTK_TICKS_BOTH = 2
209 };
210
212
218 vtkSetClampMacro(TickLocation, int, VTK_TICKS_INSIDE, VTK_TICKS_BOTH);
219 vtkGetMacro(TickLocation, int);
221
222 void SetTickLocationToInside() { this->SetTickLocation(VTK_TICKS_INSIDE); }
223 void SetTickLocationToOutside() { this->SetTickLocation(VTK_TICKS_OUTSIDE); }
224 void SetTickLocationToBoth() { this->SetTickLocation(VTK_TICKS_BOTH); }
225
227
231 vtkSetMacro(AxisVisibility, bool);
232 vtkGetMacro(AxisVisibility, bool);
233 vtkBooleanMacro(AxisVisibility, bool);
235
237
241 vtkSetMacro(TickVisibility, bool);
242 vtkGetMacro(TickVisibility, bool);
243 vtkBooleanMacro(TickVisibility, bool);
245
247
251 vtkSetMacro(LabelVisibility, bool);
252 vtkGetMacro(LabelVisibility, bool);
253 vtkBooleanMacro(LabelVisibility, bool);
255
257
261 vtkSetMacro(TitleVisibility, bool);
262 vtkGetMacro(TitleVisibility, bool);
263 vtkBooleanMacro(TitleVisibility, bool);
265
267
271 vtkSetMacro(ExponentVisibility, bool);
272 vtkGetMacro(ExponentVisibility, bool);
273 vtkBooleanMacro(ExponentVisibility, bool);
275
277
281 vtkSetMacro(LastMajorTickPointCorrection, bool);
282 vtkGetMacro(LastMajorTickPointCorrection, bool);
283 vtkBooleanMacro(LastMajorTickPointCorrection, bool);
285
287 {
288 VTK_ALIGN_TOP = 0,
289 VTK_ALIGN_BOTTOM = 1,
290 VTK_ALIGN_POINT1 = 2,
291 VTK_ALIGN_POINT2 = 3
292 };
293
295
300 virtual void SetTitleAlignLocation(int location);
301 vtkGetMacro(TitleAlignLocation, int);
303
305
310 virtual void SetExponentLocation(int location);
311 vtkGetMacro(ExponentLocation, int);
313
315
321
323
329
331
337
339
345
347
353
355
361
363
369
371
377
379
385
387
391 vtkSetMacro(DrawGridlines, bool);
392 vtkGetMacro(DrawGridlines, bool);
393 vtkBooleanMacro(DrawGridlines, bool);
395
397
403 vtkSetMacro(DrawGridlinesOnly, bool);
404 vtkGetMacro(DrawGridlinesOnly, bool);
405 vtkBooleanMacro(DrawGridlinesOnly, bool);
407
408 vtkSetMacro(DrawGridlinesLocation, int);
409 vtkGetMacro(DrawGridlinesLocation, int);
410
412
416 vtkSetMacro(DrawInnerGridlines, bool);
417 vtkGetMacro(DrawInnerGridlines, bool);
418 vtkBooleanMacro(DrawInnerGridlines, bool);
420
422
426 vtkSetMacro(GridlineXLength, double);
427 vtkGetMacro(GridlineXLength, double);
428 vtkSetMacro(GridlineYLength, double);
429 vtkGetMacro(GridlineYLength, double);
430 vtkSetMacro(GridlineZLength, double);
431 vtkGetMacro(GridlineZLength, double);
433
435
439 vtkSetMacro(DrawGridpolys, bool);
440 vtkGetMacro(DrawGridpolys, bool);
441 vtkBooleanMacro(DrawGridpolys, bool);
443
445 {
446 VTK_AXIS_TYPE_X = 0,
447 VTK_AXIS_TYPE_Y = 1,
448 VTK_AXIS_TYPE_Z = 2
449 };
450
452
456 vtkSetClampMacro(AxisType, int, VTK_AXIS_TYPE_X, VTK_AXIS_TYPE_Z);
457 vtkGetMacro(AxisType, int);
458 void SetAxisTypeToX() { this->SetAxisType(VTK_AXIS_TYPE_X); }
459 void SetAxisTypeToY() { this->SetAxisType(VTK_AXIS_TYPE_Y); }
460 void SetAxisTypeToZ() { this->SetAxisType(VTK_AXIS_TYPE_Z); }
462
464 {
465 VTK_AXIS_POS_MINMIN = 0,
466 VTK_AXIS_POS_MINMAX = 1,
467 VTK_AXIS_POS_MAXMAX = 2,
468 VTK_AXIS_POS_MAXMIN = 3
469 };
470
472
476 vtkSetMacro(Log, bool);
477 vtkGetMacro(Log, bool);
478 vtkBooleanMacro(Log, bool);
480
482
490 vtkSetClampMacro(AxisPosition, int, VTK_AXIS_POS_MINMIN, VTK_AXIS_POS_MAXMIN);
491 vtkGetMacro(AxisPosition, int);
493
494 void SetAxisPositionToMinMin() { this->SetAxisPosition(VTK_AXIS_POS_MINMIN); }
495 void SetAxisPositionToMinMax() { this->SetAxisPosition(VTK_AXIS_POS_MINMAX); }
496 void SetAxisPositionToMaxMax() { this->SetAxisPosition(VTK_AXIS_POS_MAXMAX); }
497 void SetAxisPositionToMaxMin() { this->SetAxisPosition(VTK_AXIS_POS_MAXMIN); }
498
500
504 virtual void SetCamera(vtkCamera*);
507
509
512 int RenderOpaqueGeometry(vtkViewport* viewport) override;
515 int RenderOverlay(vtkViewport* viewport) override;
518
525
526 double ComputeMaxLabelLength(const double[3]);
527 double ComputeTitleLength(const double[3]);
528
529 void SetLabelScale(double scale);
530 void SetLabelScale(int labelIndex, double scale);
531 void SetTitleScale(double scale);
532
534
538 vtkSetMacro(MinorStart, double);
539 vtkGetMacro(MinorStart, double);
540 double GetMajorStart(int axis);
541 void SetMajorStart(int axis, double value);
542 vtkSetMacro(DeltaMinor, double);
543 vtkGetMacro(DeltaMinor, double);
544 double GetDeltaMajor(int axis);
545 void SetDeltaMajor(int axis, double value);
547
549
555 vtkSetMacro(MinorRangeStart, double);
556 vtkGetMacro(MinorRangeStart, double);
557 vtkSetMacro(MajorRangeStart, double);
558 vtkGetMacro(MajorRangeStart, double);
560
562
566 vtkSetMacro(DeltaRangeMinor, double);
567 vtkGetMacro(DeltaRangeMinor, double);
568 vtkSetMacro(DeltaRangeMajor, double);
569 vtkGetMacro(DeltaRangeMajor, double);
571
573
574 void BuildAxis(vtkViewport* viewport, bool);
575
577
581 vtkGetObjectMacro(TitleActor, vtkAxisFollower);
583
585
588 vtkGetObjectMacro(ExponentActor, vtkAxisFollower);
590
594 inline vtkAxisFollower** GetLabelActors() { return this->LabelActors; }
595
597
601 vtkGetObjectMacro(TitleProp3D, vtkProp3DAxisFollower);
603
607 inline vtkProp3DAxisFollower** GetLabelProps3D() { return this->LabelProps3D; }
608
610
614 vtkGetObjectMacro(ExponentProp3D, vtkProp3DAxisFollower);
616
618
622 vtkGetMacro(NumberOfLabelsBuilt, int);
624
626
630 vtkSetMacro(CalculateTitleOffset, bool);
631 vtkGetMacro(CalculateTitleOffset, bool);
632 vtkBooleanMacro(CalculateTitleOffset, bool);
634
636
640 vtkSetMacro(CalculateLabelOffset, bool);
641 vtkGetMacro(CalculateLabelOffset, bool);
642 vtkBooleanMacro(CalculateLabelOffset, bool);
644
646
650 vtkSetMacro(Use2DMode, bool);
651 vtkGetMacro(Use2DMode, bool);
653
655
659 vtkSetMacro(VerticalOffsetXTitle2D, double);
660 vtkGetMacro(VerticalOffsetXTitle2D, double);
662
664
668 vtkSetMacro(HorizontalOffsetYTitle2D, double);
669 vtkGetMacro(HorizontalOffsetYTitle2D, double);
671
673
677 vtkSetMacro(SaveTitlePosition, int);
678 vtkGetMacro(SaveTitlePosition, int);
680
682
686 vtkSetVector3Macro(AxisBaseForX, double);
687 vtkGetVector3Macro(AxisBaseForX, double);
689
691
695 vtkSetVector3Macro(AxisBaseForY, double);
696 vtkGetVector3Macro(AxisBaseForY, double);
698
700
704 vtkSetVector3Macro(AxisBaseForZ, double);
705 vtkGetVector3Macro(AxisBaseForZ, double);
707
709
713 vtkSetMacro(AxisOnOrigin, bool);
714 vtkGetMacro(AxisOnOrigin, bool);
716
718
722 vtkSetMacro(ScreenSize, double);
723 vtkGetMacro(ScreenSize, double);
725
727
731 vtkSetMacro(LabelOffset, double);
732 vtkGetMacro(LabelOffset, double);
734
736
740 vtkSetMacro(ExponentOffset, double);
741 vtkGetMacro(ExponentOffset, double);
743
745
752 vtkSetVector2Macro(TitleOffset, double);
753 vtkGetVector2Macro(TitleOffset, double);
755
756protected:
758 ~vtkAxisActor() override;
759
760 char* Title = nullptr;
761 char* Exponent = nullptr;
762 char* LabelFormat = nullptr;
763 double Range[2] = { 0.0, 1.0 };
764 double LastRange[2] = { -1.0, -1.0 };
765 bool UseTextActor3D = false;
766 int NumberOfLabelsBuilt = 0;
767 bool MinorTicksVisible = true;
768 bool LastMinorTicksVisible = true;
769
775 int TickLocation = VTK_TICKS_INSIDE;
776
781 int TitleAlignLocation = VTK_ALIGN_BOTTOM;
782
787 int ExponentLocation = VTK_ALIGN_POINT2;
788
789 bool DrawGridlines = false;
790 bool DrawGridlinesOnly = false;
791 bool LastDrawGridlines = false;
792 int DrawGridlinesLocation = 0; // 0: all | 1: closest | 2: furthest
793 int LastDrawGridlinesLocation = 0; // 0: all | 1: closest | 2: furthest
794 double GridlineXLength = 1.0;
795 double GridlineYLength = 1.0;
796 double GridlineZLength = 1.0;
797
798 bool DrawInnerGridlines = false;
799 bool LastDrawInnerGridlines = false;
800
801 bool DrawGridpolys = false;
802 bool LastDrawGridpolys = false;
803
804 bool AxisVisibility = true;
805 bool TickVisibility = true;
806 bool LastTickVisibility = true;
807 bool LabelVisibility = true;
808 bool TitleVisibility = true;
809 bool ExponentVisibility = false;
810 bool LastMajorTickPointCorrection = false;
811
812 bool Log = false;
813 int AxisType = VTK_AXIS_TYPE_X;
814 int AxisPosition = VTK_AXIS_POS_MINMIN;
815
816 // coordinate system for axisAxtor, relative to world coordinates
817 double AxisBaseForX[3] = { 1.0, 0.0, 0.0 };
818 double AxisBaseForY[3] = { 0.0, 1.0, 0.0 };
819 double AxisBaseForZ[3] = { 0.0, 0.0, 1.0 };
820
821private:
822 vtkAxisActor(const vtkAxisActor&) = delete;
823 void operator=(const vtkAxisActor&) = delete;
824
825 void TransformBounds(vtkViewport*, double bnds[6]);
826
827 void BuildLabels(vtkViewport*, bool);
828 void BuildLabels2D(vtkViewport*, bool);
829 void SetLabelPositions(vtkViewport*, bool);
830 void SetLabelPositions2D(vtkViewport*, bool);
831
836 void RotateActor2DFromAxisProjection(vtkTextActor* pActor2D);
837
841 void InitTitle();
842
846 void InitExponent();
847
854 void BuildTitle(bool);
855
860 void BuildExponent(bool force);
861
862 void BuildExponent2D(vtkViewport* viewport, bool force);
863
864 void BuildTitle2D(vtkViewport* viewport, bool);
865
866 void SetAxisPointsAndLines();
867
868 bool BuildTickPoints(double p1[3], double p2[3], bool force);
869
870 // Build major ticks for linear scale.
871 void BuildMajorTicks(double p1[3], double p2[3], double localCoordSys[3][3]);
872
873 // Build major ticks for logarithmic scale.
874 void BuildMajorTicksLog(double p1[3], double p2[3], double localCoordSys[3][3]);
875
876 // Build minor ticks for linear scale.
877 void BuildMinorTicks(double p1[3], double p2[3], double localCoordSys[3][3]);
878
879 // Build minor ticks for logarithmic scale enabled
880 void BuildMinorTicksLog(double p1[3], double p2[3], double localCoordSys[3][3]);
881
882 void BuildAxisGridLines(double p1[3], double p2[3], double localCoordSys[3][3]);
883
884 bool TickVisibilityChanged();
885 vtkProperty* NewTitleProperty();
886 vtkProperty2D* NewTitleProperty2D();
887 vtkProperty* NewLabelProperty();
888
889 bool BoundsDisplayCoordinateChanged(vtkViewport* viewport);
890
891 vtkNew<vtkCoordinate> Point1Coordinate;
892 vtkNew<vtkCoordinate> Point2Coordinate;
893
894 double MajorTickSize = 1.0;
895 double MinorTickSize = 0.5;
896
897 // For each axis (for the inner gridline generation)
898 double MajorStart[3] = { 0.0, 0.0, 0.0 };
899 double DeltaMajor[3] = { 1.0, 1.0, 1.0 };
900 double MinorStart = 0.0;
901 double DeltaMinor = 1.0;
902
903 // For the ticks, w.r.t to the set range
904 double MajorRangeStart = 0.0;
905 double MinorRangeStart = 0.0;
906
910 double DeltaRangeMinor = 1.0;
911
915 double DeltaRangeMajor = 1.0;
916
917 int LastAxisPosition = -1;
918 int LastTickLocation = -1;
919
920 vtkNew<vtkPoints> MinorTickPts;
921 vtkNew<vtkPoints> MajorTickPts;
922 vtkNew<vtkPoints> GridlinePts;
923 vtkNew<vtkPoints> InnerGridlinePts;
924 vtkNew<vtkPoints> GridpolyPts;
925
926 vtkNew<vtkVectorText> TitleVector;
927 vtkNew<vtkPolyDataMapper> TitleMapper;
928 vtkNew<vtkAxisFollower> TitleActor;
929 vtkNew<vtkTextActor> TitleActor2D;
931 vtkNew<vtkTextActor3D> TitleActor3D;
932 vtkSmartPointer<vtkTextProperty> TitleTextProperty;
933
935
938 vtkNew<vtkVectorText> ExponentVector;
939 vtkNew<vtkPolyDataMapper> ExponentMapper;
940 vtkNew<vtkAxisFollower> ExponentActor;
941 vtkNew<vtkTextActor> ExponentActor2D;
942 vtkNew<vtkProp3DAxisFollower> ExponentProp3D;
943 vtkNew<vtkTextActor3D> ExponentActor3D;
945
946 vtkSmartPointer<vtkVectorText>* LabelVectors = nullptr;
947 vtkSmartPointer<vtkPolyDataMapper>* LabelMappers = nullptr;
948 vtkAxisFollower** LabelActors = nullptr;
949 vtkProp3DAxisFollower** LabelProps3D = nullptr;
950 vtkSmartPointer<vtkTextActor>* LabelActors2D = nullptr;
951 vtkSmartPointer<vtkTextActor3D>* LabelActors3D = nullptr;
952 vtkSmartPointer<vtkTextProperty> LabelTextProperty;
953
954 // Main line axis
955 vtkNew<vtkPolyData> AxisLines;
956 vtkNew<vtkPolyDataMapper> AxisLinesMapper;
957 vtkNew<vtkActor> AxisLinesActor;
958
959 // Ticks of the axis
960 vtkNew<vtkPolyData> AxisMajorTicks, AxisMinorTicks;
961 vtkNew<vtkPolyDataMapper> AxisMajorTicksMapper, AxisMinorTicksMapper;
962 vtkNew<vtkActor> AxisMajorTicksActor, AxisMinorTicksActor;
963
964 vtkNew<vtkPolyData> Gridlines;
965 vtkNew<vtkPolyDataMapper> GridlinesMapper;
966 vtkNew<vtkActor> GridlinesActor;
967 vtkNew<vtkPolyData> InnerGridlines;
968 vtkNew<vtkPolyDataMapper> InnerGridlinesMapper;
969 vtkNew<vtkActor> InnerGridlinesActor;
970 vtkNew<vtkPolyData> Gridpolys;
971 vtkNew<vtkPolyDataMapper> GridpolysMapper;
972 vtkNew<vtkActor> GridpolysActor;
973
975 vtkTimeStamp BuildTime;
976 vtkTimeStamp BuildTickPointsTime;
977 vtkTimeStamp BoundsTime;
978 vtkTimeStamp LabelBuildTime;
979 vtkTimeStamp TitleTextTime;
980 vtkTimeStamp ExponentTextTime;
981
982 bool AxisOnOrigin = false;
983
984 bool AxisHasZeroLength = false;
985
986 bool CalculateTitleOffset = false;
987 bool CalculateLabelOffset = false;
988
992 bool Use2DMode = false;
993
998 double VerticalOffsetXTitle2D = -40;
999
1004 double HorizontalOffsetYTitle2D = -50;
1005
1012 int SaveTitlePosition = 0;
1013
1017 double TitleConstantPosition[2] = { 0.0, 0.0 };
1018
1022 bool NeedBuild2D = false;
1023
1024 double LastMinDisplayCoordinate[3] = { 0.0, 0.0, 0.0 };
1025 double LastMaxDisplayCoordinate[3] = { 0.0, 0.0, 0.0 };
1026 double TickVector[3] = { 0.0, 0.0, 0.0 };
1027
1031 double ScreenSize = 10.0;
1032
1034
1037 double LabelOffset = 30.0;
1038 double TitleOffset[2] = { 20.0, 20.0 };
1039 double ExponentOffset = 20.0;
1041};
1042
1043VTK_ABI_NAMESPACE_END
1044#endif
represents an object (geometry & properties) in a rendered scene
Definition vtkActor.h:151
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.
~vtkAxisActor() override
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
Definition vtkCamera.h:151
perform coordinate transformation, and represent position, in a variety of vtk coordinate systems
a subclass of actor that always faces the camera
Definition vtkFollower.h:92
a simple class to control print indentation
Definition vtkIndent.h:108
Allocate and hold a VTK object.
Definition vtkNew.h:167
represent and manipulate 3D points
Definition vtkPoints.h:139
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
create polygonal text
abstract specification for Viewports
Definition vtkViewport.h:65
window superclass for vtkRenderWindow
Definition vtkWindow.h:48
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_SIZEHINT(...)
#define VTK_MARSHALAUTO