VTK  9.4.20251203
vtkCubeAxesActor.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
47#ifndef vtkCubeAxesActor_h
48#define vtkCubeAxesActor_h
49
50#include "vtkActor.h"
51#include "vtkDeprecation.h" // For deprecation macro
52#include "vtkNew.h" // For vtkNew
53#include "vtkRenderingAnnotationModule.h" // For export macro
54#include "vtkSmartPointer.h" // For vtkSmartPointer
55#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
56
57VTK_ABI_NAMESPACE_BEGIN
58class vtkAxisActor;
59class vtkCamera;
60class vtkTextProperty;
61class vtkStringArray;
62
63class VTKRENDERINGANNOTATION_EXPORT VTK_MARSHALAUTO vtkCubeAxesActor : public vtkActor
64{
65public:
66 vtkTypeMacro(vtkCubeAxesActor, vtkActor);
67 void PrintSelf(ostream& os, vtkIndent indent) override;
68
74
76
82 int RenderOverlay(vtkViewport*) override;
85
87
91 vtkSetMacro(RebuildAxes, bool);
92 vtkGetMacro(RebuildAxes, bool);
94
96
102 vtkSetVector6Macro(Bounds, double);
103 using Superclass::GetBounds;
104 double* GetBounds() VTK_SIZEHINT(6) override { return this->Bounds; }
106
108
112 virtual void GetRenderedBounds(double rBounds[6]);
113 virtual double* GetRenderedBounds();
115
117
125 vtkSetVector2Macro(XAxisRange, double);
126 vtkSetVector2Macro(YAxisRange, double);
127 vtkSetVector2Macro(ZAxisRange, double);
128 vtkGetVector2Macro(XAxisRange, double);
129 vtkGetVector2Macro(YAxisRange, double);
132
137 void SetAxisLabels(int axis, vtkStringArray* value);
139
140 vtkGetVector2Macro(ZAxisRange, double);
141
143
149 void SetScreenSize(double screenSize);
150 vtkGetMacro(ScreenSize, double);
152
154
158 void SetLabelOffset(double offset);
159 vtkGetMacro(LabelOffset, double);
161
163
167 VTK_DEPRECATED_IN_9_3_0("Use the new setters as it's now a 2d vector")
168 void SetTitleOffset(double titleOffsetY);
169 VTK_DEPRECATED_IN_9_3_0("Use the new getter as it's now a 2d vector")
170 double GetTitleOffset();
171 void SetTitleOffset(double titleOffset[2]);
172 // TODO: Replace getter with macro once deprecated one is removed
173 void GetTitleOffset(double& titleOffsetX, double& titleOffsetY);
175
177
181 virtual void SetCamera(vtkCamera*);
182 vtkCamera* GetCamera();
184
186 {
187 VTK_FLY_OUTER_EDGES = 0,
188 VTK_FLY_CLOSEST_TRIAD = 1,
189 VTK_FLY_FURTHEST_TRIAD = 2,
190 VTK_FLY_STATIC_TRIAD = 3,
191 VTK_FLY_STATIC_EDGES = 4
192 };
193
195
201 vtkSetClampMacro(FlyMode, int, VTK_FLY_OUTER_EDGES, VTK_FLY_STATIC_EDGES);
202 vtkGetMacro(FlyMode, int);
203 void SetFlyModeToOuterEdges() { this->SetFlyMode(VTK_FLY_OUTER_EDGES); }
204 void SetFlyModeToClosestTriad() { this->SetFlyMode(VTK_FLY_CLOSEST_TRIAD); }
205 void SetFlyModeToFurthestTriad() { this->SetFlyMode(VTK_FLY_FURTHEST_TRIAD); }
206 void SetFlyModeToStaticTriad() { this->SetFlyMode(VTK_FLY_STATIC_TRIAD); }
207 void SetFlyModeToStaticEdges() { this->SetFlyMode(VTK_FLY_STATIC_EDGES); }
209
211
215 vtkSetStringMacro(XTitle);
216 vtkGetStringMacro(XTitle);
217 vtkSetStringMacro(XUnits);
218 vtkGetStringMacro(XUnits);
219 vtkSetStringMacro(YTitle);
220 vtkGetStringMacro(YTitle);
221 vtkSetStringMacro(YUnits);
222 vtkGetStringMacro(YUnits);
223 vtkSetStringMacro(ZTitle);
224 vtkGetStringMacro(ZTitle);
225 vtkSetStringMacro(ZUnits);
226 vtkGetStringMacro(ZUnits);
228
230
234 vtkSetStringMacro(XLabelFormat);
235 vtkGetStringMacro(XLabelFormat);
236 vtkSetStringMacro(YLabelFormat);
237 vtkGetStringMacro(YLabelFormat);
238 vtkSetStringMacro(ZLabelFormat);
239 vtkGetStringMacro(ZLabelFormat);
241
243
249 vtkSetClampMacro(Inertia, int, 1, VTK_INT_MAX);
250 vtkGetMacro(Inertia, int);
252
254
260 vtkSetMacro(CornerOffset, double);
261 vtkGetMacro(CornerOffset, double);
263
270
272
276 vtkSetMacro(EnableDistanceLOD, bool);
277 vtkGetMacro(EnableDistanceLOD, bool);
279
281
285 vtkSetClampMacro(DistanceLODThreshold, double, 0.0, 1.0);
286 vtkGetMacro(DistanceLODThreshold, double);
288
290
294 vtkSetMacro(EnableViewAngleLOD, bool);
295 vtkGetMacro(EnableViewAngleLOD, bool);
297
299
303 vtkSetClampMacro(ViewAngleLODThreshold, double, 0., 1.);
304 vtkGetMacro(ViewAngleLODThreshold, double);
306
308
312 vtkSetMacro(XAxisVisibility, bool);
313 vtkGetMacro(XAxisVisibility, bool);
314 vtkBooleanMacro(XAxisVisibility, bool);
315
316 vtkSetMacro(YAxisVisibility, bool);
317 vtkGetMacro(YAxisVisibility, bool);
318 vtkBooleanMacro(YAxisVisibility, bool);
319
320 vtkSetMacro(ZAxisVisibility, bool);
321 vtkGetMacro(ZAxisVisibility, bool);
322 vtkBooleanMacro(ZAxisVisibility, bool);
324
326
330 vtkSetMacro(XAxisLabelVisibility, bool);
331 vtkGetMacro(XAxisLabelVisibility, bool);
332 vtkBooleanMacro(XAxisLabelVisibility, bool);
333
334 vtkSetMacro(YAxisLabelVisibility, bool);
335 vtkGetMacro(YAxisLabelVisibility, bool);
336 vtkBooleanMacro(YAxisLabelVisibility, bool);
337
338 vtkSetMacro(ZAxisLabelVisibility, bool);
339 vtkGetMacro(ZAxisLabelVisibility, bool);
340 vtkBooleanMacro(ZAxisLabelVisibility, bool);
342
344
348 vtkSetMacro(XAxisTickVisibility, bool);
349 vtkGetMacro(XAxisTickVisibility, bool);
350 vtkBooleanMacro(XAxisTickVisibility, bool);
351
352 vtkSetMacro(YAxisTickVisibility, bool);
353 vtkGetMacro(YAxisTickVisibility, bool);
354 vtkBooleanMacro(YAxisTickVisibility, bool);
355
356 vtkSetMacro(ZAxisTickVisibility, bool);
357 vtkGetMacro(ZAxisTickVisibility, bool);
358 vtkBooleanMacro(ZAxisTickVisibility, bool);
360
362
366 vtkSetMacro(XAxisMinorTickVisibility, bool);
367 vtkGetMacro(XAxisMinorTickVisibility, bool);
368 vtkBooleanMacro(XAxisMinorTickVisibility, bool);
369
370 vtkSetMacro(YAxisMinorTickVisibility, bool);
371 vtkGetMacro(YAxisMinorTickVisibility, bool);
372 vtkBooleanMacro(YAxisMinorTickVisibility, bool);
373
374 vtkSetMacro(ZAxisMinorTickVisibility, bool);
375 vtkGetMacro(ZAxisMinorTickVisibility, bool);
376 vtkBooleanMacro(ZAxisMinorTickVisibility, bool);
378
380
384 vtkSetMacro(DrawXGridlines, bool);
385 vtkGetMacro(DrawXGridlines, bool);
386 vtkBooleanMacro(DrawXGridlines, bool);
387
388 vtkSetMacro(DrawYGridlines, bool);
389 vtkGetMacro(DrawYGridlines, bool);
390 vtkBooleanMacro(DrawYGridlines, bool);
391
392 vtkSetMacro(DrawZGridlines, bool);
393 vtkGetMacro(DrawZGridlines, bool);
394 vtkBooleanMacro(DrawZGridlines, bool);
396
398
402 vtkSetMacro(DrawXInnerGridlines, bool);
403 vtkGetMacro(DrawXInnerGridlines, bool);
404 vtkBooleanMacro(DrawXInnerGridlines, bool);
405
406 vtkSetMacro(DrawYInnerGridlines, bool);
407 vtkGetMacro(DrawYInnerGridlines, bool);
408 vtkBooleanMacro(DrawYInnerGridlines, bool);
409
410 vtkSetMacro(DrawZInnerGridlines, bool);
411 vtkGetMacro(DrawZInnerGridlines, bool);
412 vtkBooleanMacro(DrawZInnerGridlines, bool);
414
416
420 vtkSetMacro(DrawXGridpolys, bool);
421 vtkGetMacro(DrawXGridpolys, bool);
422 vtkBooleanMacro(DrawXGridpolys, bool);
423
424 vtkSetMacro(DrawYGridpolys, bool);
425 vtkGetMacro(DrawYGridpolys, bool);
426 vtkBooleanMacro(DrawYGridpolys, bool);
427
428 vtkSetMacro(DrawZGridpolys, bool);
429 vtkGetMacro(DrawZGridpolys, bool);
430 vtkBooleanMacro(DrawZGridpolys, bool);
432
434
445
447
458
460
470
472
482
484
494
496
506
508 {
509 VTK_TICKS_INSIDE = 0,
510 VTK_TICKS_OUTSIDE = 1,
511 VTK_TICKS_BOTH = 2
512 };
513
515
519 vtkSetClampMacro(TickLocation, int, VTK_TICKS_INSIDE, VTK_TICKS_BOTH);
520 vtkGetMacro(TickLocation, int);
522
523 void SetTickLocationToInside() { this->SetTickLocation(VTK_TICKS_INSIDE); }
524 void SetTickLocationToOutside() { this->SetTickLocation(VTK_TICKS_OUTSIDE); }
525 void SetTickLocationToBoth() { this->SetTickLocation(VTK_TICKS_BOTH); }
526
527 void SetLabelScaling(bool, int, int, int);
528
530
535 void SetUseTextActor3D(bool enable);
538
540
544 void SetUse2DMode(bool enable);
547
551 void SetSaveTitlePosition(int val);
552
554
558 vtkSetVector6Macro(OrientedBounds, double);
559 vtkGetVector6Macro(OrientedBounds, double);
561
563
567 vtkSetMacro(UseOrientedBounds, bool);
568 vtkGetMacro(UseOrientedBounds, bool);
570
572
576 vtkSetVector3Macro(AxisBaseForX, double);
577 vtkGetVector3Macro(AxisBaseForX, double);
579
581
585 vtkSetVector3Macro(AxisBaseForY, double);
586 vtkGetVector3Macro(AxisBaseForY, double);
588
590
594 vtkSetVector3Macro(AxisBaseForZ, double);
595 vtkGetVector3Macro(AxisBaseForZ, double);
597
599
604 vtkSetVector3Macro(AxisOrigin, double);
605 vtkGetVector3Macro(AxisOrigin, double);
607
609
613 vtkSetMacro(UseAxisOrigin, bool);
614 vtkGetMacro(UseAxisOrigin, bool);
616
618
622 vtkSetMacro(GridLineLocation, int);
623 vtkGetMacro(GridLineLocation, int);
625
627
633 vtkSetMacro(StickyAxes, bool);
634 vtkGetMacro(StickyAxes, bool);
635 vtkBooleanMacro(StickyAxes, bool);
637
639
647 vtkSetMacro(CenterStickyAxes, bool);
648 vtkGetMacro(CenterStickyAxes, bool);
649 vtkBooleanMacro(CenterStickyAxes, bool);
651
653 {
654 VTK_GRID_LINES_ALL = 0,
655 VTK_GRID_LINES_CLOSEST = 1,
656 VTK_GRID_LINES_FURTHEST = 2
657 };
658
659protected:
662
669 vtkViewport* viewport, const double bounds[6], double sphereCenter[3], double& sphereRadius);
670
674 void GetViewportLimitedBounds(vtkViewport* viewport, double bounds[6]);
675
681 unsigned int pointIndex, unsigned int& xBit, unsigned int& yBit, unsigned int& zBit);
682
686 static void GetBoundsPoint(unsigned int pointIndex, const double bounds[6], double point[3]);
687
688 int LabelExponent(double min, double max);
689
690 int Digits(double min, double max);
691
692 double MaxOf(double, double);
693 double MaxOf(double, double, double, double);
694
695 double FFix(double);
696 double FSign(double, double);
697 int FRound(double fnt);
698 int GetNumTicks(double range, double fxt);
699
700 void UpdateLabels(vtkAxisActor** axis, int index);
701
703
704 int FlyMode = VTK_FLY_CLOSEST_TRIAD;
705
706 // Expose internally closest axis index computation
707 int FindClosestAxisIndex(double pts[8][3]);
708
709 // Expose internally furthest axis index computation
710 int FindFurtherstAxisIndex(double pts[8][3]);
711
712 // Expose internally the boundary edge fly mode axis index computation
713 void FindBoundaryEdge(int& indexOfAxisX, int& indexOfAxisY, int& indexOfAxisZ, double pts[8][3]);
714
720 void UpdateGridLineVisibility(int axisIndex);
721
722 // VTK_ALL_GRID_LINES 0
723 // VTK_CLOSEST_GRID_LINES 1
724 // VTK_FURTHEST_GRID_LINES 2
725 int GridLineLocation = VTK_GRID_LINES_ALL;
726
730 bool StickyAxes = false;
731
735 bool CenterStickyAxes = true;
736
741 bool EnableDistanceLOD = true;
742
747 double DistanceLODThreshold = 0.8;
748
753 bool EnableViewAngleLOD = true;
754
759 double ViewAngleLODThreshold = 0.2;
760
762 {
763 NUMBER_OF_ALIGNED_AXIS = 4
764 };
765
767
771 vtkAxisActor* XAxes[NUMBER_OF_ALIGNED_AXIS];
772 vtkAxisActor* YAxes[NUMBER_OF_ALIGNED_AXIS];
773 vtkAxisActor* ZAxes[NUMBER_OF_ALIGNED_AXIS];
775
776 bool RebuildAxes = true;
777
778 char* XTitle = nullptr;
779 char* XUnits = nullptr;
780 char* YTitle = nullptr;
781 char* YUnits = nullptr;
782 char* ZTitle = nullptr;
783 char* ZUnits = nullptr;
784
785 char* ActualXLabel = nullptr;
786 char* ActualYLabel = nullptr;
787 char* ActualZLabel = nullptr;
788
789 int TickLocation = VTK_TICKS_INSIDE;
790
791 bool XAxisVisibility = true;
792 bool YAxisVisibility = true;
793 bool ZAxisVisibility = true;
794
795 bool XAxisTickVisibility = true;
796 bool YAxisTickVisibility = true;
797 bool ZAxisTickVisibility = true;
798
799 bool XAxisMinorTickVisibility = true;
800 bool YAxisMinorTickVisibility = true;
801 bool ZAxisMinorTickVisibility = true;
802
803 bool XAxisLabelVisibility = true;
804 bool YAxisLabelVisibility = true;
805 bool ZAxisLabelVisibility = true;
806
807 bool DrawXGridlines = false;
808 bool DrawYGridlines = false;
809 bool DrawZGridlines = false;
810
811 bool DrawXInnerGridlines = false;
812 bool DrawYInnerGridlines = false;
813 bool DrawZInnerGridlines = false;
814
815 bool DrawXGridpolys = false;
816 bool DrawYGridpolys = false;
817 bool DrawZGridpolys = false;
818
819 char* XLabelFormat = nullptr;
820 char* YLabelFormat = nullptr;
821 char* ZLabelFormat = nullptr;
822
823 double CornerOffset = 0.0;
824
825 int Inertia = 1;
826
827 int RenderCount = 0;
828
829 int InertiaLocs[3] = { -1, -1, -1 };
830
831 bool RenderSomething = false;
832
833 vtkNew<vtkTextProperty> TitleTextProperty[3];
835 vtkNew<vtkTextProperty> LabelTextProperty[3];
836
849
850 double RenderedBounds[6] = { -1.0, 1.0, -1.0, 1.0, -1.0, 1.0 };
851 double OrientedBounds[6] = { -1.0, 1.0, -1.0, 1.0, -1.0, 1.0 };
852 bool UseOrientedBounds = false;
853
854 double AxisOrigin[3] = { 0.0, 0.0, 0.0 };
855 bool UseAxisOrigin = false;
856
857 double AxisBaseForX[3] = { 1.0, 0.0, 0.0 };
858 double AxisBaseForY[3] = { 0.0, 1.0, 0.0 };
859 double AxisBaseForZ[3] = { 0.0, 0.0, 1.0 };
860
861private:
862 vtkCubeAxesActor(const vtkCubeAxesActor&) = delete;
863 void operator=(const vtkCubeAxesActor&) = delete;
864
865 vtkSetStringMacro(ActualXLabel);
866 vtkSetStringMacro(ActualYLabel);
867 vtkSetStringMacro(ActualZLabel);
868
869 vtkTimeStamp BuildTime;
870 bool LastUseOrientedBounds = false;
871 int LastXPow = 0;
872 int LastYPow = 0;
873 int LastZPow = 0;
874
875 int UserXPow = 0;
876 int UserYPow = 0;
877 int UserZPow = 0;
878
879 bool AutoLabelScaling = true;
880
881 int LastXAxisDigits = 3;
882 int LastYAxisDigits = 3;
883 int LastZAxisDigits = 3;
884
885 double LastXRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
886 double LastYRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
887 double LastZRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
890
891 int LastFlyMode = -1;
892
893 int RenderAxesX[NUMBER_OF_ALIGNED_AXIS] = { 0, 1, 2, 3 };
894 int RenderAxesY[NUMBER_OF_ALIGNED_AXIS] = { 0, 1, 2, 3 };
895 int RenderAxesZ[NUMBER_OF_ALIGNED_AXIS] = { 0, 1, 2, 3 };
896
897 int NumberOfAxesX = 1;
898 int NumberOfAxesY = 1;
899 int NumberOfAxesZ = 1;
900
901 bool MustAdjustXValue = false;
902 bool MustAdjustYValue = false;
903 bool MustAdjustZValue = false;
904
905 bool ForceXLabelReset = false;
906 bool ForceYLabelReset = false;
907 bool ForceZLabelReset = false;
908
909 double XAxisRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
910 double YAxisRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
911 double ZAxisRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
912
913 double LabelScale = -1.0;
914 double TitleScale = -1.0;
915
916 double ScreenSize = 10.0;
917 double LabelOffset = 20.0;
918 double TitleOffset[2] = { 20.0, 20.0 };
919
921
925 double MajorStart[3] = { 0.0, 0.0, 0.0 };
926 double DeltaMajor[3] = { 0.0, 0.0, 0.0 };
928
929 int RenderGeometry(bool& initialRender, vtkViewport* viewport, bool checkAxisVisibility,
930 int (vtkAxisActor::*renderMethod)(vtkViewport*));
931
932 void TransformBounds(vtkViewport* viewport, const double bounds[6], double pts[8][3]);
933 void AdjustAxes(double bounds[6], double xCoords[NUMBER_OF_ALIGNED_AXIS][6],
934 double yCoords[NUMBER_OF_ALIGNED_AXIS][6], double zCoords[NUMBER_OF_ALIGNED_AXIS][6],
935 double xRange[2], double yRange[2], double zRange[2]);
936
937 bool ComputeTickSize(double bounds[6]);
938 void AdjustValues(const double xRange[2], const double yRange[2], const double zRange[2]);
939 void AdjustRange(const double bounds[6]);
940 void BuildAxes(vtkViewport*);
941 void DetermineRenderAxes(vtkViewport*);
942 void SetNonDependentAttributes();
943 void BuildLabels(vtkAxisActor* axes[NUMBER_OF_ALIGNED_AXIS]);
944 void AdjustTicksComputeRange(
945 vtkAxisActor* axes[NUMBER_OF_ALIGNED_AXIS], double rangeMin, double rangeMax);
946
947 void AutoScale(vtkViewport* viewport);
948 void AutoScale(vtkViewport* viewport, vtkAxisActor* axes[NUMBER_OF_ALIGNED_AXIS]);
949 double AutoScale(vtkViewport* viewport, double screenSize, double position[3]);
950};
951
952VTK_ABI_NAMESPACE_END
953#endif
represents an object (geometry & properties) in a rendered scene
Definition vtkActor.h:42
Create an axis with tick marks and labels.
a virtual camera for 3D rendering
Definition vtkCamera.h:42
create a plot of a bounding box edges - used for navigation
void FindBoundaryEdge(int &indexOfAxisX, int &indexOfAxisY, int &indexOfAxisZ, double pts[8][3])
vtkProperty * GetZAxesGridpolysProperty()
Get/Set axes gridPolys actors properties.
void SetYAxesTitleProperty(vtkTextProperty *)
Returns the text property for the title on an axis.
bool GetUseTextActor3D()
Use or not vtkTextActor3D for titles and labels.
void SetXAxesGridlinesProperty(vtkProperty *)
Get/Set axes (outer) gridlines actors properties.
void GetViewportLimitedBounds(vtkViewport *viewport, double bounds[6])
Get bounds such that the axes are entirely within a viewport.
void UpdateGridLineVisibility(int axisIndex)
This will Update AxisActors with GridVisibility when those should be dynamaic regarding the viewport.
void SetScreenSize(double screenSize)
Explicitly specify the screen size of title and label text.
int RenderOverlay(vtkViewport *) override
Draw the axes as per the vtkProp superclass' API.
vtkNew< vtkProperty > ZAxesGridlinesProperty
virtual int RenderTranslucentGeometry(vtkViewport *)
Draw the axes as per the vtkProp superclass' API.
double FSign(double, double)
vtkTextProperty * GetXAxesLabelProperty()
Returns the text property for the labels on an axis.
void SetYAxesInnerGridlinesProperty(vtkProperty *)
Get/Set axes inner gridlines actors properties.
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this actor.
vtkSmartPointer< vtkCamera > Camera
void SetZAxesLabelProperty(vtkTextProperty *)
Returns the text property for the labels on an axis.
vtkProperty * GetZAxesGridlinesProperty()
Get/Set axes (outer) gridlines actors properties.
void SetFlyModeToOuterEdges()
Specify a mode to control how the axes are drawn: either static, closest triad, furthest triad or out...
vtkTypeBool HasTranslucentPolygonalGeometry() override
Draw the axes as per the vtkProp superclass' API.
vtkProperty * GetXAxesLinesProperty()
Get/Set axes actors properties.
vtkTextProperty * GetYAxesLabelProperty()
Returns the text property for the labels on an axis.
vtkProperty * GetXAxesInnerGridlinesProperty()
Get/Set axes inner gridlines actors properties.
void SetXAxesGridpolysProperty(vtkProperty *)
Get/Set axes gridPolys actors properties.
vtkNew< vtkProperty > ZAxesInnerGridlinesProperty
void SetZAxesGridpolysProperty(vtkProperty *)
Get/Set axes gridPolys actors properties.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetYAxesLabelProperty(vtkTextProperty *)
Returns the text property for the labels on an axis.
void SetUse2DMode(bool enable)
Get/Set 2D mode NB: Use vtkTextActor for titles in 2D instead of vtkAxisFollower.
vtkNew< vtkProperty > YAxesGridpolysProperty
vtkTextProperty * GetZAxesLabelProperty()
Returns the text property for the labels on an axis.
double * GetBounds() override
Explicitly specify the region in space around which to draw the bounds.
void SetFlyModeToClosestTriad()
Specify a mode to control how the axes are drawn: either static, closest triad, furthest triad or out...
void SetYAxesGridpolysProperty(vtkProperty *)
Get/Set axes gridPolys actors properties.
vtkNew< vtkProperty > XAxesGridlinesProperty
void SetZAxesInnerGridlinesProperty(vtkProperty *)
Get/Set axes inner gridlines actors properties.
void SetZAxesGridlinesProperty(vtkProperty *)
Get/Set axes (outer) gridlines actors properties.
~vtkCubeAxesActor() override
void SetAxisLabels(int axis, vtkStringArray *value)
Explicitly specify the axis labels along an axis as an array of strings instead of using the values.
vtkNew< vtkProperty > YAxesGridlinesProperty
static vtkCubeAxesActor * New()
Instantiate object with label format "6.3g" and the number of labels per axis set to 3.
int FRound(double fnt)
int FindClosestAxisIndex(double pts[8][3])
int RenderOpaqueGeometry(vtkViewport *) override
Draw the axes as per the vtkProp superclass' API.
void ComputeStickyAxesBoundingSphere(vtkViewport *viewport, const double bounds[6], double sphereCenter[3], double &sphereRadius)
Computes a bounding sphere used to determine the sticky bounding box.
vtkTextProperty * GetZAxesTitleProperty()
Returns the text property for the title on an axis.
static void GetBoundsPoint(unsigned int pointIndex, const double bounds[6], double point[3])
Get a point on the bounding box by point index.
vtkTextProperty * GetYAxesTitleProperty()
Returns the text property for the title on an axis.
void SetLabelOffset(double offset)
Explicitly specify the offset between labels and the axis.
bool GetUse2DMode()
Get/Set 2D mode NB: Use vtkTextActor for titles in 2D instead of vtkAxisFollower.
void SetUseTextActor3D(bool enable)
Use or not vtkTextActor3D for titles and labels.
vtkProperty * GetXAxesGridlinesProperty()
Get/Set axes (outer) gridlines actors properties.
vtkTextProperty * GetLabelTextProperty(int)
Returns the text property for the labels on an axis.
void SetZAxesLinesProperty(vtkProperty *)
Get/Set axes actors properties.
void SetFlyModeToStaticEdges()
Specify a mode to control how the axes are drawn: either static, closest triad, furthest triad or out...
void SetFlyModeToStaticTriad()
Specify a mode to control how the axes are drawn: either static, closest triad, furthest triad or out...
void SetYAxesLinesProperty(vtkProperty *)
Get/Set axes actors properties.
vtkStringArray * GetAxisLabels(int axis)
Explicitly specify the axis labels along an axis as an array of strings instead of using the values.
vtkNew< vtkProperty > XAxesGridpolysProperty
virtual double * GetRenderedBounds()
Method used to properly return the bounds of the cube axis itself with all its labels.
vtkProperty * GetYAxesGridlinesProperty()
Get/Set axes (outer) gridlines actors properties.
vtkProperty * GetZAxesLinesProperty()
Get/Set axes actors properties.
vtkNew< vtkProperty > YAxesInnerGridlinesProperty
void SetSaveTitlePosition(int val)
For 2D mode only: save axis title positions for later use.
vtkNew< vtkProperty > ZAxesLinesProperty
vtkTextProperty * GetTitleTextProperty(int)
Returns the text property for the title on an axis.
static void GetBoundsPointBits(unsigned int pointIndex, unsigned int &xBit, unsigned int &yBit, unsigned int &zBit)
Get the bits for a bounds point.
void SetXAxesInnerGridlinesProperty(vtkProperty *)
Get/Set axes inner gridlines actors properties.
void SetLabelScaling(bool, int, int, int)
vtkNew< vtkProperty > YAxesLinesProperty
vtkTextProperty * GetXAxesTitleProperty()
Returns the text property for the title on an axis.
vtkNew< vtkProperty > XAxesLinesProperty
double FFix(double)
int FindFurtherstAxisIndex(double pts[8][3])
vtkNew< vtkProperty > XAxesInnerGridlinesProperty
vtkProperty * GetXAxesGridpolysProperty()
Get/Set axes gridPolys actors properties.
void SetXAxesTitleProperty(vtkTextProperty *)
Returns the text property for the title on an axis.
vtkNew< vtkProperty > ZAxesGridpolysProperty
double MaxOf(double, double, double, double)
int GetNumTicks(double range, double fxt)
void SetXAxesLabelProperty(vtkTextProperty *)
Returns the text property for the labels on an axis.
void UpdateLabels(vtkAxisActor **axis, int index)
vtkProperty * GetYAxesInnerGridlinesProperty()
Get/Set axes inner gridlines actors properties.
int Digits(double min, double max)
int RenderTranslucentPolygonalGeometry(vtkViewport *) override
Draw the axes as per the vtkProp superclass' API.
vtkProperty * GetZAxesInnerGridlinesProperty()
Get/Set axes inner gridlines actors properties.
virtual void GetRenderedBounds(double rBounds[6])
Method used to properly return the bounds of the cube axis itself with all its labels.
double MaxOf(double, double)
vtkProperty * GetYAxesLinesProperty()
Get/Set axes actors properties.
int LabelExponent(double min, double max)
void SetXAxesLinesProperty(vtkProperty *)
Get/Set axes actors properties.
void SetYAxesGridlinesProperty(vtkProperty *)
Get/Set axes (outer) gridlines actors properties.
vtkProperty * GetYAxesGridpolysProperty()
Get/Set axes gridPolys actors properties.
void SetZAxesTitleProperty(vtkTextProperty *)
Returns the text property for the title on an axis.
void SetFlyModeToFurthestTriad()
Specify a mode to control how the axes are drawn: either static, closest triad, furthest triad or out...
a simple class to control print indentation
Definition vtkIndent.h:29
Allocate and hold a VTK object.
Definition vtkNew.h:58
double Bounds[6]
Definition vtkProp3D.h:400
represent surface properties of a geometric object
Definition vtkProperty.h:60
Hold a reference to a vtkObjectBase instance.
a vtkAbstractArray subclass for strings
represent text properties.
record modification and/or execution time
abstract specification for Viewports
Definition vtkViewport.h:46
window superclass for vtkRenderWindow
Definition vtkWindow.h:29
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_DEPRECATED_IN_9_3_0(reason)
#define VTK_DOUBLE_MAX
Definition vtkType.h:154
#define VTK_INT_MAX
Definition vtkType.h:144
#define VTK_SIZEHINT(...)
#define VTK_MARSHALAUTO
#define max(a, b)