ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
cvCustomAxisHandleRepresentation Class Reference

Handle representation with custom translation axis support. More...

#include <cvCustomAxisHandleRepresentation.h>

Inheritance diagram for cvCustomAxisHandleRepresentation:
[legend]
Collaboration diagram for cvCustomAxisHandleRepresentation:
[legend]

Public Member Functions

 vtkTypeMacro (cvCustomAxisHandleRepresentation, vtkPointHandleRepresentation3D)
 
void PrintSelf (ostream &os, vtkIndent indent) override
 
void SetCustomTranslationAxisOn ()
 Enable custom translation axis mode. More...
 
void SetCustomTranslationAxisOff ()
 Disable custom translation axis mode. More...
 
void SetCustomTranslationAxis (double axis[3])
 Set the custom translation axis vector. More...
 
void SetCustomTranslationAxis (double x, double y, double z)
 
 vtkGetVector3Macro (CustomTranslationAxis, double)
 Get the custom translation axis. More...
 
bool IsCustomAxisEnabled () const
 Check if custom translation axis is enabled. More...
 
void GetTranslationVector (const double *p1, const double *p2, double *v) const override
 Override GetTranslationVector to support custom axis. More...
 
void Translate (const double *p1, const double *p2) override
 Override Translate to support custom axis. More...
 
void Translate (const double *v) override
 

Static Public Member Functions

static cvCustomAxisHandleRepresentation * New ()
 

Protected Member Functions

 cvCustomAxisHandleRepresentation ()
 
 ~cvCustomAxisHandleRepresentation () override
 

Protected Attributes

bool CustomAxisEnabled
 
double CustomTranslationAxis [3]
 

Detailed Description

Handle representation with custom translation axis support.

This class extends vtkPointHandleRepresentation3D to add support for custom translation axes, which is available in VTK 9.3+ but not in earlier versions. It follows ParaView's implementation approach.

Constructor & Destructor Documentation

◆ cvCustomAxisHandleRepresentation()

cvCustomAxisHandleRepresentation::cvCustomAxisHandleRepresentation ( )
protected

References CustomTranslationAxis.

◆ ~cvCustomAxisHandleRepresentation()

cvCustomAxisHandleRepresentation::~cvCustomAxisHandleRepresentation ( )
overrideprotecteddefault

Member Function Documentation

◆ GetTranslationVector()

void cvCustomAxisHandleRepresentation::GetTranslationVector ( const double *  p1,
const double *  p2,
double *  v 
) const
override

Override GetTranslationVector to support custom axis.

References CustomAxisEnabled, and CustomTranslationAxis.

Referenced by Translate().

◆ IsCustomAxisEnabled()

bool cvCustomAxisHandleRepresentation::IsCustomAxisEnabled ( ) const
inline

Check if custom translation axis is enabled.

References CustomAxisEnabled.

◆ New()

static cvCustomAxisHandleRepresentation* cvCustomAxisHandleRepresentation::New ( )
static

◆ PrintSelf()

void cvCustomAxisHandleRepresentation::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
override

◆ SetCustomTranslationAxis() [1/2]

void cvCustomAxisHandleRepresentation::SetCustomTranslationAxis ( double  axis[3])

Set the custom translation axis vector.

Parameters
axisThe axis vector (will be normalized internally)

References CustomTranslationAxis.

Referenced by SetCustomTranslationAxis().

◆ SetCustomTranslationAxis() [2/2]

void cvCustomAxisHandleRepresentation::SetCustomTranslationAxis ( double  x,
double  y,
double  z 
)

References SetCustomTranslationAxis(), x, y, and z.

◆ SetCustomTranslationAxisOff()

void cvCustomAxisHandleRepresentation::SetCustomTranslationAxisOff ( )

Disable custom translation axis mode.

References CustomAxisEnabled.

Referenced by cvConstrainedDistanceWidget::ProcessKeyEvents().

◆ SetCustomTranslationAxisOn()

void cvCustomAxisHandleRepresentation::SetCustomTranslationAxisOn ( )

Enable custom translation axis mode.

References CustomAxisEnabled.

Referenced by cvConstrainedDistanceWidget::ProcessKeyEvents().

◆ Translate() [1/2]

void cvCustomAxisHandleRepresentation::Translate ( const double *  p1,
const double *  p2 
)
override

Override Translate to support custom axis.

References GetTranslationVector().

◆ Translate() [2/2]

void cvCustomAxisHandleRepresentation::Translate ( const double *  v)
override

◆ vtkGetVector3Macro()

cvCustomAxisHandleRepresentation::vtkGetVector3Macro ( CustomTranslationAxis  ,
double   
)

Get the custom translation axis.

◆ vtkTypeMacro()

cvCustomAxisHandleRepresentation::vtkTypeMacro ( cvCustomAxisHandleRepresentation  ,
vtkPointHandleRepresentation3D   
)

Member Data Documentation

◆ CustomAxisEnabled

bool cvCustomAxisHandleRepresentation::CustomAxisEnabled
protected

◆ CustomTranslationAxis

double cvCustomAxisHandleRepresentation::CustomTranslationAxis[3]
protected

The documentation for this class was generated from the following files: