14 #include "boost/bind.hpp" 15 #include <vtkAxesActor.h> 16 #include <vtkRenderer.h> 17 #include <vtkMatrix4x4.h> 18 #include <vtkCaptionActor2D.h> 19 #include <vtkTextProperty.h> 20 #include <vtkAssembly.h> 34 mActor = vtkAxesActorPtr::New();
35 mActor->SetAxisLabels(
false);
52 for (
unsigned i=0; i<
mCaption.size(); ++i)
62 for (
unsigned i=0; i<
mCaption.size(); ++i)
90 for (
unsigned i=0; i<
mCaption.size(); ++i)
105 for (
unsigned i=0; i<
mCaption.size(); ++i)
148 double axisSize =
mSize/size;
155 mActor->SetUserMatrix(rMq.getVtkMatrix());
157 for (
unsigned i=0; i<
mCaption.size(); ++i)
160 mCaption[i]->SetAttachmentPoint(pos.begin());
168 cap->GetCaptionTextProperty()->SetColor(color.begin());
171 cap->GetCaptionTextProperty()->ShadowOff();
173 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)
Namespace for all CustusX production code.