31 #ifndef vtkCameraOrientationRepresentation_h
32 #define vtkCameraOrientationRepresentation_h
34 #include "vtkInteractionWidgetsModule.h"
70 void ApplyInteractionState(
const InteractionStateType& state);
71 void ApplyInteractionState(
const int& state);
81 this->InteractionState =
82 this->InteractionState < 0 ? 0 : (this->InteractionState > 2 ? 2 : this->
InteractionState);
91 vtkSetVector2Macro(Size,
int);
92 vtkGetVector2Macro(Size,
int);
99 vtkSetVector2Macro(Padding,
int);
100 vtkGetVector2Macro(Padding,
int);
118 this->AnchorPosition = AnchorType::LowerLeft;
123 this->AnchorPosition = AnchorType::UpperLeft;
128 this->AnchorPosition = AnchorType::LowerRight;
133 this->AnchorPosition = AnchorType::UpperRight;
143 vtkSetMacro(TotalLength,
double);
144 vtkGetMacro(TotalLength,
double);
152 vtkSetMacro(NormalizedHandleDia,
double);
153 vtkGetMacro(NormalizedHandleDia,
double);
160 vtkGetMacro(Azimuth,
double);
161 vtkGetVector3Macro(Back,
double);
162 vtkGetMacro(Elevation,
double);
163 vtkGetVector3Macro(Up,
double);
170 vtkSetClampMacro(ShaftResolution,
int, 3, 256);
171 vtkGetMacro(ShaftResolution,
int);
178 vtkSetClampMacro(HandleCircumferentialResolution,
int, 3, 256);
179 vtkGetMacro(HandleCircumferentialResolution,
int);
186 vtkSetClampMacro(ContainerCircumferentialResolution,
int, 3, 256);
187 vtkGetMacro(ContainerCircumferentialResolution,
int);
194 vtkSetClampMacro(ContainerRadialResolution,
int, 3, 256);
195 vtkGetMacro(ContainerRadialResolution,
int);
202 vtkGetMacro(PickedAxis,
int);
203 vtkGetMacro(PickedDir,
int);
233 void SetContainerVisibility(
bool state);
234 vtkBooleanMacro(ContainerVisibility,
bool);
235 bool GetContainerVisibility();
267 void ReleaseGraphicsResources(
vtkWindow*) override;
269 int RenderTranslucentPolygonalGeometry(
vtkViewport*) override;
270 vtkTypeBool HasTranslucentPolygonalGeometry() override;
276 void ShallowCopy(
vtkProp* prop) override;
281 bool IsAnyHandleSelected() {
return (this->PickedAxis != -1) && (this->PickedDir != -1); }
287 virtual void CreateDefaultGeometry();
288 virtual void CreateDefaultProperties();
289 virtual void PositionHandles();
290 virtual void HighlightHandle();
291 virtual void Rotate(
double newEventPos[2]);
293 void FinalizeHandlePicks();
324 int Padding[2] = { 10, 10 };
325 int Size[2] = { 120, 120 };
328 const char* AxisLabelsText[3][2] = { {
"X",
"-X" }, {
"Y",
"-Y" }, {
"Z",
"-Z" } };
330 double Back[3] = { 0., 0., -1. };
331 double Bounds[6] = {};
332 double Elevation = 0.;
333 double MotionFactor = 1.;
334 double NormalizedHandleDia = 0.4;
335 double TotalLength = 1.;
336 double Up[3] = { 0., 1., 0. };
337 int ContainerCircumferentialResolution = 32;
338 int ContainerRadialResolution = 1;
339 int HandleCircumferentialResolution = 32;
340 int ShaftResolution = 10;
344 int LastPickedAx = -1;
346 int LastPickedDir = -1;
349 double LastEventPosition[3] = {};
vtkNew< vtkDoubleArray > AxesColors
abstract superclass for all actors, volumes and annotations
represents an object (geometry & properties) in a rendered scene
pick an actor/prop using graphics hardware
abstract specification for Viewports
represent surface properties of a geometric object
vtkNew< vtkTubeFilter > ShaftGlyphs
vtkNew< vtkDiskSource > ContainerSource
vtkNew< vtkActor > Shafts
concrete dataset represents vertices, lines, polygons, and triangle strips
void PlaceWidget(double *) override
These are methods that satisfy vtkWidgetRepresentation's API.
void AnchorToLowerLeft()
Get/Set the widget anchor type.
vtkNew< vtkActor > Container
dynamic, self-adjusting array of double
window superclass for vtkRenderWindow
filter that generates tubes around lines
vtkNew< vtkPoints > Points
a simple class to control print indentation
vtkNew< vtkPropPicker > HandlePicker
topologically and geometrically regular array of data
handles properties associated with a texture map
virtual void Modified()
Update the modification time for this object.
#define VTK_SIZEHINT(...)
represent text properties.
AnchorType GetAnchorPosition()
Get/Set the widget anchor type.
void AnchorToUpperRight()
Get/Set the widget anchor type.
vtkNew< vtkPolyData > Skeleton
InteractionStateType GetInteractionStateAsEnum() noexcept
Convenient method to get InteractionState as enum.
create a disk with hole in center
vtkNew< vtkTransform > Transform
A 3D representation for vtkCameraOrientationWidget.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
represent and manipulate 3D points
void AnchorToLowerRight()
Get/Set the widget anchor type.
void AnchorToUpperLeft()
Get/Set the widget anchor type.