50 #ifndef vtkAxisActor_h 51 #define vtkAxisActor_h 54 #include "vtkRenderingAnnotationModule.h" 88 virtual void SetPoint1(
double x,
double y,
double z);
89 virtual double* GetPoint1();
98 virtual void SetPoint2(
double x,
double y,
double z);
99 virtual double* GetPoint2();
107 vtkSetVector2Macro(Range,
double);
108 vtkGetVectorMacro(Range,
double, 2);
115 void SetBounds(
const double bounds[6]);
116 void SetBounds(
double xmin,
double xmax,
double ymin,
double ymax,
double zmin,
double zmax);
125 vtkSetStringMacro(LabelFormat);
138 vtkGetMacro(UseTextActor3D,
int);
146 vtkGetMacro(MinorTicksVisible,
int);
154 void SetTitle(
const char* t);
162 void SetExponent(
const char* t);
171 vtkGetMacro(MajorTickSize,
double);
179 vtkGetMacro(MinorTickSize,
double);
184 VTK_TICKS_INSIDE = 0,
185 VTK_TICKS_OUTSIDE = 1,
195 vtkSetClampMacro(TickLocation,
int, VTK_TICKS_INSIDE, VTK_TICKS_BOTH);
196 vtkGetMacro(TickLocation,
int);
208 vtkGetMacro(AxisVisibility,
int);
217 vtkGetMacro(TickVisibility,
int);
226 vtkGetMacro(LabelVisibility,
int);
235 vtkGetMacro(TitleVisibility,
int);
244 vtkGetMacro(ExponentVisibility,
bool);
253 vtkGetMacro(LastMajorTickPointCorrection,
bool);
260 VTK_ALIGN_BOTTOM = 1,
261 VTK_ALIGN_POINT1 = 2,
270 virtual void SetTitleAlignLocation(
int location);
271 vtkGetMacro(TitleAlignLocation,
int);
279 virtual void SetExponentLocation(
int location);
280 vtkGetMacro(ExponentLocation,
int);
360 vtkGetMacro(DrawGridlines,
int);
371 vtkGetMacro(DrawGridlinesOnly,
int);
376 vtkGetMacro(DrawGridlinesLocation,
int);
383 vtkGetMacro(DrawInnerGridlines,
int);
392 vtkGetMacro(GridlineXLength,
double);
394 vtkGetMacro(GridlineYLength,
double);
396 vtkGetMacro(GridlineZLength,
double);
404 vtkGetMacro(DrawGridpolys,
int);
419 vtkSetClampMacro(AxisType,
int, VTK_AXIS_TYPE_X, VTK_AXIS_TYPE_Z);
420 vtkGetMacro(AxisType,
int);
428 VTK_AXIS_POS_MINMIN = 0,
429 VTK_AXIS_POS_MINMAX = 1,
430 VTK_AXIS_POS_MAXMAX = 2,
431 VTK_AXIS_POS_MAXMIN = 3
439 vtkGetMacro(Log,
bool);
451 vtkSetClampMacro(AxisPosition,
int, VTK_AXIS_POS_MINMIN, VTK_AXIS_POS_MAXMIN);
452 vtkGetMacro(AxisPosition,
int);
474 virtual int RenderTranslucentGeometry(
vtkViewport* viewport);
485 void ReleaseGraphicsResources(
vtkWindow*) VTK_OVERRIDE;
487 double ComputeMaxLabelLength(const
double[3]);
488 double ComputeTitleLength(const
double[3]);
490 void SetLabelScale(const
double scale);
491 void SetLabelScale(
int labelIndex, const
double scale);
492 void SetTitleScale(const
double scale);
500 vtkGetMacro(MinorStart,
double);
501 double GetMajorStart(
int axis);
502 void SetMajorStart(
int axis,
double value);
506 vtkGetMacro(DeltaMinor,
double);
507 double GetDeltaMajor(
int axis);
508 void SetDeltaMajor(
int axis,
double value);
521 vtkGetMacro(MinorRangeStart,
double);
523 vtkGetMacro(MajorRangeStart,
double);
525 vtkGetMacro(DeltaRangeMinor,
double);
527 vtkGetMacro(DeltaRangeMajor,
double);
580 vtkGetMacro(NumberOfLabelsBuilt,
int);
589 vtkGetMacro(CalculateTitleOffset,
int);
599 vtkGetMacro(CalculateLabelOffset,
int);
608 vtkGetMacro(Use2DMode,
int);
616 vtkGetMacro(VerticalOffsetXTitle2D,
double);
624 vtkGetMacro(HorizontalOffsetYTitle2D,
double);
632 vtkGetMacro(SaveTitlePosition,
int);
639 vtkSetVector3Macro(AxisBaseForX,
double);
640 vtkGetVector3Macro(AxisBaseForX,
double);
647 vtkSetVector3Macro(AxisBaseForY,
double);
648 vtkGetVector3Macro(AxisBaseForY,
double);
655 vtkSetVector3Macro(AxisBaseForZ,
double);
656 vtkGetVector3Macro(AxisBaseForZ,
double);
664 vtkGetMacro(AxisOnOrigin,
int);
672 vtkGetMacro(LabelOffset,
double);
674 vtkGetMacro(TitleOffset,
double);
676 vtkGetMacro(ExponentOffset,
double);
678 vtkGetMacro(ScreenSize,
double);
691 int NumberOfLabelsBuilt;
692 int MinorTicksVisible;
693 int LastMinorTicksVisible;
706 int TitleAlignLocation;
712 int ExponentLocation;
715 int DrawGridlinesOnly;
716 int LastDrawGridlines;
717 int DrawGridlinesLocation;
718 int LastDrawGridlinesLocation;
719 double GridlineXLength;
720 double GridlineYLength;
721 double GridlineZLength;
723 int DrawInnerGridlines;
724 int LastDrawInnerGridlines;
727 int LastDrawGridpolys;
731 int LastTickVisibility;
734 bool ExponentVisibility;
735 bool LastMajorTickPointCorrection;
743 double AxisBaseForX[3];
744 double AxisBaseForY[3];
745 double AxisBaseForZ[3];
749 void operator=(const
vtkAxisActor&) VTK_DELETE_FUNCTION;
751 void TransformBounds(
vtkViewport*,
double bnds[6]);
762 void RotateActor2DFromAxisProjection(
vtkTextActor* pActor2D);
780 void BuildTitle(
bool);
786 void BuildExponent(
bool force);
788 void BuildExponent2D(
vtkViewport* viewport,
bool force);
792 void SetAxisPointsAndLines(
void);
794 bool BuildTickPoints(
double p1[3],
double p2[3],
bool force);
797 void BuildMajorTicks(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
800 void BuildMajorTicksLog(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
803 void BuildMinorTicks(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
806 void BuildMinorTicksLog(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
808 void BuildAxisGridLines(
double p1[3],
double p2[3],
double localCoordSys[3][3]);
810 bool TickVisibilityChanged(
void);
815 bool BoundsDisplayCoordinateChanged(
vtkViewport* viewport);
820 double MajorTickSize;
821 double MinorTickSize;
824 double MajorStart[3];
825 double DeltaMajor[3];
830 double MajorRangeStart;
831 double MinorRangeStart;
836 double DeltaRangeMinor;
841 double DeltaRangeMajor;
843 int LastAxisPosition;
845 int LastTickLocation;
846 double LastLabelStart;
890 vtkActor *AxisMajorTicksActor, *AxisMinorTicksActor;
912 int AxisHasZeroLength;
914 int CalculateTitleOffset;
915 int CalculateLabelOffset;
926 double VerticalOffsetXTitle2D;
932 double HorizontalOffsetYTitle2D;
940 int SaveTitlePosition;
945 double TitleConstantPosition[2];
952 double LastMinDisplayCoordinate[3];
953 double LastMaxDisplayCoordinate[3];
954 double TickVector[3];
963 double ExponentOffset;
virtual void SetPoint1(double x[3])
Specify the position of the first point defining the axis.
represents an object (geometry & properties) in a rendered scene
void SetAxisTypeToY(void)
Set/Get the type of this axis.
abstract specification for Viewports
represent surface properties of a geometric object
virtual void SetPoint2(double x[3])
Specify the position of the second point defining the axis.
virtual int RenderOverlay(vtkViewport *)
int HasTranslucentPolygonalGeometry() override
Does this prop have some translucent polygonal geometry?
record modification and/or execution time
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.
vtkProp3DAxisFollower ** GetLabelProps3D()
Get label actors responsigle for drawing label text.
a vtkAbstractArray subclass for strings
void SetTickLocationToInside(void)
concrete dataset represents vertices, lines, polygons, and triangle strips
static vtkActor * New()
Creates an actor with the following defaults: origin(0,0,0) position=(0,0,0) scale=(1,1,1) visibility=1 pickable=1 dragable=1 orientation=(0,0,0).
void SetAxisPositionToMaxMin(void)
window superclass for vtkRenderWindow
void SetAxisTypeToX(void)
Set/Get the type of this axis.
An actor that displays text.
a simple class to control print indentation
a virtual camera for 3D rendering
void SetAxisPositionToMaxMax(void)
void SetTickLocationToBoth(void)
vtkGetStringMacro(ExtensionsString)
Returns a string listing all available extensions.
An actor that displays text.
double * GetBounds() override
Return a reference to the Prop3D's composite transform.
represent text properties.
perform coordinate transformation, and represent position, in a variety of vtk coordinate systems ...
a subclass of vtkFollower that ensures that data is always parallel to the axis defined by a vtkAxisA...
vtkSetMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
void SetAxisPositionToMinMax(void)
map vtkPolyData to graphics primitives
void SetAxisPositionToMinMin(void)
a subclass of actor that always faces the camera
a subclass of vtkProp3DFollower that ensures that data is always parallel to the axis defined by a vt...
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
Support the standard render methods.
represent surface properties of a 2D image
void SetAxisTypeToZ(void)
Set/Get the type of this axis.
vtkBooleanMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
void SetTickLocationToOutside(void)
int RenderOpaqueGeometry(vtkViewport *viewport) override
Support the standard render methods.
represent and manipulate 3D points