35 #include "boost/bind.hpp"
36 #include <vtkAxesActor.h>
37 #include <vtkRenderer.h>
38 #include <vtkMatrix4x4.h>
39 #include <vtkCaptionActor2D.h>
40 #include <vtkTextProperty.h>
41 #include <vtkAssembly.h>
55 mActor = vtkAxesActorPtr::New();
56 mActor->SetAxisLabels(
false);
73 for (
unsigned i=0; i<
mCaption.size(); ++i)
83 for (
unsigned i=0; i<
mCaption.size(); ++i)
111 for (
unsigned i=0; i<
mCaption.size(); ++i)
126 for (
unsigned i=0; i<
mCaption.size(); ++i)
169 double axisSize =
mSize/size;
176 mActor->SetUserMatrix(rMq.getVtkMatrix());
178 for (
unsigned i=0; i<
mCaption.size(); ++i)
181 mCaption[i]->SetAttachmentPoint(pos.begin());
189 cap->GetCaptionTextProperty()->SetColor(color.begin());
192 cap->GetCaptionTextProperty()->ShadowOff();
194 cap->SetVisibility(
mActor->GetVisibility());
Transform3D createTransformScale(const Vector3D &scale_)
Transform3D Transform3D
Transform3D is a representation of an affine 3D transform.
void setFontSize(double size)
cstring_cast_Placeholder cstring_cast(const T &val)
Listens to changes in viewport and camera matrix.
GraphicalAxes3D(vtkRendererPtr renderer=vtkRendererPtr())
vtkSmartPointer< class vtkRenderer > vtkRendererPtr
void setAxisLength(double length)
void addCaption(const QString &label, Vector3D pos, Vector3D color)
virtual ~GraphicalAxes3D()
std::vector< vtkCaptionActor2DPtr > mCaption
vtkSmartPointer< class vtkCaptionActor2D > vtkCaptionActor2DPtr
std::vector< Vector3D > mCaptionPos
Eigen::Vector3d Vector3D
Vector3D is a representation of a point or vector in 3D.
void setCaption(const QString &caption, const Vector3D &color)
RealScalar length() const
const double m_vtkAxisLength
ViewportListenerPtr mViewportListener
void setRenderer(vtkRendererPtr renderer=vtkRendererPtr())
void setTransform(Transform3D rMt)
void setShowAxesLabels(bool on)