VTK  9.4.20250413
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
76#ifndef vtkCubeAxesActor_h
77#define vtkCubeAxesActor_h
78
79#include "vtkActor.h"
80#include "vtkNew.h" // For vtkNew
81#include "vtkRenderingAnnotationModule.h" // For export macro
82#include "vtkSmartPointer.h" // For vtkSmartPointer
83#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
84
85VTK_ABI_NAMESPACE_BEGIN
86class vtkAxisActor;
87class vtkCamera;
88class vtkTextProperty;
89class vtkStringArray;
90
91class VTKRENDERINGANNOTATION_EXPORT VTK_MARSHALAUTO vtkCubeAxesActor : public vtkActor
92{
93public:
94 vtkTypeMacro(vtkCubeAxesActor, vtkActor);
95 void PrintSelf(ostream& os, vtkIndent indent) override;
96
102
104
113
115
119 vtkSetMacro(RebuildAxes, bool);
120 vtkGetMacro(RebuildAxes, bool);
122
124
130 vtkSetVector6Macro(Bounds, double);
131 using Superclass::GetBounds;
132 double* GetBounds() VTK_SIZEHINT(6) override { return this->Bounds; }
134
136
140 virtual void GetRenderedBounds(double rBounds[6]);
141 virtual double* GetRenderedBounds();
143
145
153 vtkSetVector2Macro(XAxisRange, double);
154 vtkSetVector2Macro(YAxisRange, double);
155 vtkSetVector2Macro(ZAxisRange, double);
156 vtkGetVector2Macro(XAxisRange, double);
157 vtkGetVector2Macro(YAxisRange, double);
160
165 void SetAxisLabels(int axis, vtkStringArray* value);
167
168 vtkGetVector2Macro(ZAxisRange, double);
169
171
177 void SetScreenSize(double screenSize);
178 vtkGetMacro(ScreenSize, double);
180
182
186 void SetLabelOffset(double offset);
187 vtkGetMacro(LabelOffset, double);
189
191
195 void SetTitleOffset(double titleOffset[2]);
196 vtkGetVector2Macro(TitleOffset, double);
198
200
204 virtual void SetCamera(vtkCamera*);
207
209 {
210 VTK_FLY_OUTER_EDGES = 0,
211 VTK_FLY_CLOSEST_TRIAD = 1,
212 VTK_FLY_FURTHEST_TRIAD = 2,
213 VTK_FLY_STATIC_TRIAD = 3,
214 VTK_FLY_STATIC_EDGES = 4
215 };
216
218
224 vtkSetClampMacro(FlyMode, int, VTK_FLY_OUTER_EDGES, VTK_FLY_STATIC_EDGES);
225 vtkGetMacro(FlyMode, int);
226 void SetFlyModeToOuterEdges() { this->SetFlyMode(VTK_FLY_OUTER_EDGES); }
227 void SetFlyModeToClosestTriad() { this->SetFlyMode(VTK_FLY_CLOSEST_TRIAD); }
228 void SetFlyModeToFurthestTriad() { this->SetFlyMode(VTK_FLY_FURTHEST_TRIAD); }
229 void SetFlyModeToStaticTriad() { this->SetFlyMode(VTK_FLY_STATIC_TRIAD); }
230 void SetFlyModeToStaticEdges() { this->SetFlyMode(VTK_FLY_STATIC_EDGES); }
232
234
238 vtkSetStringMacro(XTitle);
239 vtkGetStringMacro(XTitle);
240 vtkSetStringMacro(XUnits);
241 vtkGetStringMacro(XUnits);
242 vtkSetStringMacro(YTitle);
243 vtkGetStringMacro(YTitle);
244 vtkSetStringMacro(YUnits);
245 vtkGetStringMacro(YUnits);
246 vtkSetStringMacro(ZTitle);
247 vtkGetStringMacro(ZTitle);
248 vtkSetStringMacro(ZUnits);
249 vtkGetStringMacro(ZUnits);
251
253
257 vtkSetStringMacro(XLabelFormat);
258 vtkGetStringMacro(XLabelFormat);
259 vtkSetStringMacro(YLabelFormat);
260 vtkGetStringMacro(YLabelFormat);
261 vtkSetStringMacro(ZLabelFormat);
262 vtkGetStringMacro(ZLabelFormat);
264
266
272 vtkSetClampMacro(Inertia, int, 1, VTK_INT_MAX);
273 vtkGetMacro(Inertia, int);
275
277
283 vtkSetMacro(CornerOffset, double);
284 vtkGetMacro(CornerOffset, double);
286
293
295
299 vtkSetMacro(EnableDistanceLOD, bool);
300 vtkGetMacro(EnableDistanceLOD, bool);
302
304
308 vtkSetClampMacro(DistanceLODThreshold, double, 0.0, 1.0);
309 vtkGetMacro(DistanceLODThreshold, double);
311
313
317 vtkSetMacro(EnableViewAngleLOD, bool);
318 vtkGetMacro(EnableViewAngleLOD, bool);
320
322
326 vtkSetClampMacro(ViewAngleLODThreshold, double, 0., 1.);
327 vtkGetMacro(ViewAngleLODThreshold, double);
329
331
335 vtkSetMacro(XAxisVisibility, bool);
336 vtkGetMacro(XAxisVisibility, bool);
337 vtkBooleanMacro(XAxisVisibility, bool);
338
339 vtkSetMacro(YAxisVisibility, bool);
340 vtkGetMacro(YAxisVisibility, bool);
341 vtkBooleanMacro(YAxisVisibility, bool);
342
343 vtkSetMacro(ZAxisVisibility, bool);
344 vtkGetMacro(ZAxisVisibility, bool);
345 vtkBooleanMacro(ZAxisVisibility, bool);
347
349
353 vtkSetMacro(XAxisLabelVisibility, bool);
354 vtkGetMacro(XAxisLabelVisibility, bool);
355 vtkBooleanMacro(XAxisLabelVisibility, bool);
356
357 vtkSetMacro(YAxisLabelVisibility, bool);
358 vtkGetMacro(YAxisLabelVisibility, bool);
359 vtkBooleanMacro(YAxisLabelVisibility, bool);
360
361 vtkSetMacro(ZAxisLabelVisibility, bool);
362 vtkGetMacro(ZAxisLabelVisibility, bool);
363 vtkBooleanMacro(ZAxisLabelVisibility, bool);
365
367
371 vtkSetMacro(XAxisTickVisibility, bool);
372 vtkGetMacro(XAxisTickVisibility, bool);
373 vtkBooleanMacro(XAxisTickVisibility, bool);
374
375 vtkSetMacro(YAxisTickVisibility, bool);
376 vtkGetMacro(YAxisTickVisibility, bool);
377 vtkBooleanMacro(YAxisTickVisibility, bool);
378
379 vtkSetMacro(ZAxisTickVisibility, bool);
380 vtkGetMacro(ZAxisTickVisibility, bool);
381 vtkBooleanMacro(ZAxisTickVisibility, bool);
383
385
389 vtkSetMacro(XAxisMinorTickVisibility, bool);
390 vtkGetMacro(XAxisMinorTickVisibility, bool);
391 vtkBooleanMacro(XAxisMinorTickVisibility, bool);
392
393 vtkSetMacro(YAxisMinorTickVisibility, bool);
394 vtkGetMacro(YAxisMinorTickVisibility, bool);
395 vtkBooleanMacro(YAxisMinorTickVisibility, bool);
396
397 vtkSetMacro(ZAxisMinorTickVisibility, bool);
398 vtkGetMacro(ZAxisMinorTickVisibility, bool);
399 vtkBooleanMacro(ZAxisMinorTickVisibility, bool);
401
403
407 vtkSetMacro(DrawXGridlines, bool);
408 vtkGetMacro(DrawXGridlines, bool);
409 vtkBooleanMacro(DrawXGridlines, bool);
410
411 vtkSetMacro(DrawYGridlines, bool);
412 vtkGetMacro(DrawYGridlines, bool);
413 vtkBooleanMacro(DrawYGridlines, bool);
414
415 vtkSetMacro(DrawZGridlines, bool);
416 vtkGetMacro(DrawZGridlines, bool);
417 vtkBooleanMacro(DrawZGridlines, bool);
419
421
425 vtkSetMacro(DrawXInnerGridlines, bool);
426 vtkGetMacro(DrawXInnerGridlines, bool);
427 vtkBooleanMacro(DrawXInnerGridlines, bool);
428
429 vtkSetMacro(DrawYInnerGridlines, bool);
430 vtkGetMacro(DrawYInnerGridlines, bool);
431 vtkBooleanMacro(DrawYInnerGridlines, bool);
432
433 vtkSetMacro(DrawZInnerGridlines, bool);
434 vtkGetMacro(DrawZInnerGridlines, bool);
435 vtkBooleanMacro(DrawZInnerGridlines, bool);
437
439
443 vtkSetMacro(DrawXGridpolys, bool);
444 vtkGetMacro(DrawXGridpolys, bool);
445 vtkBooleanMacro(DrawXGridpolys, bool);
446
447 vtkSetMacro(DrawYGridpolys, bool);
448 vtkGetMacro(DrawYGridpolys, bool);
449 vtkBooleanMacro(DrawYGridpolys, bool);
450
451 vtkSetMacro(DrawZGridpolys, bool);
452 vtkGetMacro(DrawZGridpolys, bool);
453 vtkBooleanMacro(DrawZGridpolys, bool);
455
457
468
470
481
483
493
495
505
507
517
519
529
531 {
532 VTK_TICKS_INSIDE = 0,
533 VTK_TICKS_OUTSIDE = 1,
534 VTK_TICKS_BOTH = 2
535 };
536
538
542 vtkSetClampMacro(TickLocation, int, VTK_TICKS_INSIDE, VTK_TICKS_BOTH);
543 vtkGetMacro(TickLocation, int);
545
546 void SetTickLocationToInside() { this->SetTickLocation(VTK_TICKS_INSIDE); }
547 void SetTickLocationToOutside() { this->SetTickLocation(VTK_TICKS_OUTSIDE); }
548 void SetTickLocationToBoth() { this->SetTickLocation(VTK_TICKS_BOTH); }
549
550 void SetLabelScaling(bool, int, int, int);
551
553
558 void SetUseTextActor3D(bool enable);
561
563
567 void SetUse2DMode(bool enable);
570
574 void SetSaveTitlePosition(int val);
575
577
581 vtkSetVector6Macro(OrientedBounds, double);
582 vtkGetVector6Macro(OrientedBounds, double);
584
586
590 vtkSetMacro(UseOrientedBounds, bool);
591 vtkGetMacro(UseOrientedBounds, bool);
593
595
599 vtkSetVector3Macro(AxisBaseForX, double);
600 vtkGetVector3Macro(AxisBaseForX, double);
602
604
608 vtkSetVector3Macro(AxisBaseForY, double);
609 vtkGetVector3Macro(AxisBaseForY, double);
611
613
617 vtkSetVector3Macro(AxisBaseForZ, double);
618 vtkGetVector3Macro(AxisBaseForZ, double);
620
622
627 vtkSetVector3Macro(AxisOrigin, double);
628 vtkGetVector3Macro(AxisOrigin, double);
630
632
636 vtkSetMacro(UseAxisOrigin, bool);
637 vtkGetMacro(UseAxisOrigin, bool);
639
641
645 vtkSetMacro(GridLineLocation, int);
646 vtkGetMacro(GridLineLocation, int);
648
650
656 vtkSetMacro(StickyAxes, bool);
657 vtkGetMacro(StickyAxes, bool);
658 vtkBooleanMacro(StickyAxes, bool);
660
662
670 vtkSetMacro(CenterStickyAxes, bool);
671 vtkGetMacro(CenterStickyAxes, bool);
672 vtkBooleanMacro(CenterStickyAxes, bool);
674
676 {
677 VTK_GRID_LINES_ALL = 0,
678 VTK_GRID_LINES_CLOSEST = 1,
679 VTK_GRID_LINES_FURTHEST = 2
680 };
681
682protected:
685
692 vtkViewport* viewport, const double bounds[6], double sphereCenter[3], double& sphereRadius);
693
697 void GetViewportLimitedBounds(vtkViewport* viewport, double bounds[6]);
698
704 unsigned int pointIndex, unsigned int& xBit, unsigned int& yBit, unsigned int& zBit);
705
709 static void GetBoundsPoint(unsigned int pointIndex, const double bounds[6], double point[3]);
710
711 int LabelExponent(double min, double max);
712
713 int Digits(double min, double max);
714
715 double MaxOf(double, double);
716 double MaxOf(double, double, double, double);
717
718 double FFix(double);
719 double FSign(double, double);
720 int FRound(double fnt);
721 int GetNumTicks(double range, double fxt);
722
723 void UpdateLabels(vtkAxisActor** axis, int index);
724
726
727 int FlyMode = VTK_FLY_CLOSEST_TRIAD;
728
729 // Expose internally closest axis index computation
730 int FindClosestAxisIndex(double pts[8][3]);
731
732 // Expose internally furthest axis index computation
733 int FindFurtherstAxisIndex(double pts[8][3]);
734
735 // Expose internally the boundary edge fly mode axis index computation
736 void FindBoundaryEdge(int& indexOfAxisX, int& indexOfAxisY, int& indexOfAxisZ, double pts[8][3]);
737
743 void UpdateGridLineVisibility(int axisIndex);
744
745 // VTK_ALL_GRID_LINES 0
746 // VTK_CLOSEST_GRID_LINES 1
747 // VTK_FURTHEST_GRID_LINES 2
748 int GridLineLocation = VTK_GRID_LINES_ALL;
749
753 bool StickyAxes = false;
754
758 bool CenterStickyAxes = true;
759
764 bool EnableDistanceLOD = true;
765
770 double DistanceLODThreshold = 0.8;
771
776 bool EnableViewAngleLOD = true;
777
782 double ViewAngleLODThreshold = 0.2;
783
785 {
786 NUMBER_OF_ALIGNED_AXIS = 4
787 };
788
790
794 vtkAxisActor* XAxes[NUMBER_OF_ALIGNED_AXIS];
795 vtkAxisActor* YAxes[NUMBER_OF_ALIGNED_AXIS];
796 vtkAxisActor* ZAxes[NUMBER_OF_ALIGNED_AXIS];
798
799 bool RebuildAxes = true;
800
801 char* XTitle = nullptr;
802 char* XUnits = nullptr;
803 char* YTitle = nullptr;
804 char* YUnits = nullptr;
805 char* ZTitle = nullptr;
806 char* ZUnits = nullptr;
807
808 char* ActualXLabel = nullptr;
809 char* ActualYLabel = nullptr;
810 char* ActualZLabel = nullptr;
811
812 int TickLocation = VTK_TICKS_INSIDE;
813
814 bool XAxisVisibility = true;
815 bool YAxisVisibility = true;
816 bool ZAxisVisibility = true;
817
818 bool XAxisTickVisibility = true;
819 bool YAxisTickVisibility = true;
820 bool ZAxisTickVisibility = true;
821
822 bool XAxisMinorTickVisibility = true;
823 bool YAxisMinorTickVisibility = true;
824 bool ZAxisMinorTickVisibility = true;
825
826 bool XAxisLabelVisibility = true;
827 bool YAxisLabelVisibility = true;
828 bool ZAxisLabelVisibility = true;
829
830 bool DrawXGridlines = false;
831 bool DrawYGridlines = false;
832 bool DrawZGridlines = false;
833
834 bool DrawXInnerGridlines = false;
835 bool DrawYInnerGridlines = false;
836 bool DrawZInnerGridlines = false;
837
838 bool DrawXGridpolys = false;
839 bool DrawYGridpolys = false;
840 bool DrawZGridpolys = false;
841
842 char* XLabelFormat = nullptr;
843 char* YLabelFormat = nullptr;
844 char* ZLabelFormat = nullptr;
845
846 double CornerOffset = 0.0;
847
848 int Inertia = 1;
849
850 int RenderCount = 0;
851
852 int InertiaLocs[3] = { -1, -1, -1 };
853
854 bool RenderSomething = false;
855
856 vtkNew<vtkTextProperty> TitleTextProperty[3];
858 vtkNew<vtkTextProperty> LabelTextProperty[3];
859
872
873 double RenderedBounds[6] = { -1.0, 1.0, -1.0, 1.0, -1.0, 1.0 };
874 double OrientedBounds[6] = { -1.0, 1.0, -1.0, 1.0, -1.0, 1.0 };
875 bool UseOrientedBounds = false;
876
877 double AxisOrigin[3] = { 0.0, 0.0, 0.0 };
878 bool UseAxisOrigin = false;
879
880 double AxisBaseForX[3] = { 1.0, 0.0, 0.0 };
881 double AxisBaseForY[3] = { 0.0, 1.0, 0.0 };
882 double AxisBaseForZ[3] = { 0.0, 0.0, 1.0 };
883
884private:
885 vtkCubeAxesActor(const vtkCubeAxesActor&) = delete;
886 void operator=(const vtkCubeAxesActor&) = delete;
887
888 vtkSetStringMacro(ActualXLabel);
889 vtkSetStringMacro(ActualYLabel);
890 vtkSetStringMacro(ActualZLabel);
891
892 vtkTimeStamp BuildTime;
893 bool LastUseOrientedBounds = false;
894 int LastXPow = 0;
895 int LastYPow = 0;
896 int LastZPow = 0;
897
898 int UserXPow = 0;
899 int UserYPow = 0;
900 int UserZPow = 0;
901
902 bool AutoLabelScaling = true;
903
904 int LastXAxisDigits = 3;
905 int LastYAxisDigits = 3;
906 int LastZAxisDigits = 3;
907
908 double LastXRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
909 double LastYRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
910 double LastZRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
913
914 int LastFlyMode = -1;
915
916 int RenderAxesX[NUMBER_OF_ALIGNED_AXIS] = { 0, 1, 2, 3 };
917 int RenderAxesY[NUMBER_OF_ALIGNED_AXIS] = { 0, 1, 2, 3 };
918 int RenderAxesZ[NUMBER_OF_ALIGNED_AXIS] = { 0, 1, 2, 3 };
919
920 int NumberOfAxesX = 1;
921 int NumberOfAxesY = 1;
922 int NumberOfAxesZ = 1;
923
924 bool MustAdjustXValue = false;
925 bool MustAdjustYValue = false;
926 bool MustAdjustZValue = false;
927
928 bool ForceXLabelReset = false;
929 bool ForceYLabelReset = false;
930 bool ForceZLabelReset = false;
931
932 double XAxisRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
933 double YAxisRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
934 double ZAxisRange[2] = { VTK_DOUBLE_MAX, VTK_DOUBLE_MAX };
935
936 double LabelScale = -1.0;
937 double TitleScale = -1.0;
938
939 double ScreenSize = 10.0;
940 double LabelOffset = 20.0;
941 double TitleOffset[2] = { 20.0, 20.0 };
942
944
948 double MajorStart[3] = { 0.0, 0.0, 0.0 };
949 double DeltaMajor[3] = { 0.0, 0.0, 0.0 };
951
952 int RenderGeometry(bool& initialRender, vtkViewport* viewport, bool checkAxisVisibility,
953 int (vtkAxisActor::*renderMethod)(vtkViewport*));
954
955 void TransformBounds(vtkViewport* viewport, const double bounds[6], double pts[8][3]);
956 void AdjustAxes(double bounds[6], double xCoords[NUMBER_OF_ALIGNED_AXIS][6],
957 double yCoords[NUMBER_OF_ALIGNED_AXIS][6], double zCoords[NUMBER_OF_ALIGNED_AXIS][6],
958 double xRange[2], double yRange[2], double zRange[2]);
959
960 bool ComputeTickSize(double bounds[6]);
961 void AdjustValues(const double xRange[2], const double yRange[2], const double zRange[2]);
962 void AdjustRange(const double bounds[6]);
963 void BuildAxes(vtkViewport*);
964 void DetermineRenderAxes(vtkViewport*);
965 void SetNonDependentAttributes();
966 void BuildLabels(vtkAxisActor* axes[NUMBER_OF_ALIGNED_AXIS]);
967 void AdjustTicksComputeRange(
968 vtkAxisActor* axes[NUMBER_OF_ALIGNED_AXIS], double rangeMin, double rangeMax);
969
970 void AutoScale(vtkViewport* viewport);
971 void AutoScale(vtkViewport* viewport, vtkAxisActor* axes[NUMBER_OF_ALIGNED_AXIS]);
972 double AutoScale(vtkViewport* viewport, double screenSize, double position[3]);
973};
974
975VTK_ABI_NAMESPACE_END
976#endif
represents an object (geometry & properties) in a rendered scene
Definition vtkActor.h:151
Create an axis with tick marks and labels.
a virtual camera for 3D rendering
Definition vtkCamera.h:151
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.
vtkCamera * GetCamera()
Set/Get the camera to perform scaling and translation of the vtkCubeAxesActor.
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 SetTitleOffset(double titleOffset[2])
Explicitly specify the offset between title and labels.
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 SetCamera(vtkCamera *)
Set/Get the camera to perform scaling and translation of the vtkCubeAxesActor.
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:108
Allocate and hold a VTK object.
Definition vtkNew.h:167
double Bounds[6]
Definition vtkProp3D.h:449
represent surface properties of a geometric object
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:66
window superclass for vtkRenderWindow
Definition vtkWindow.h:48
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_DOUBLE_MAX
Definition vtkType.h:171
#define VTK_INT_MAX
Definition vtkType.h:161
#define VTK_SIZEHINT(...)
#define VTK_MARSHALAUTO
#define max(a, b)