10 #ifndef VECTORFIELD3D_H
11 #define VECTORFIELD3D_H
16 #include <QVTKWidget.h>
17 #include <QtDesigner/QDesignerExportWidget>
18 #include <vtkPolyData.h>
19 #include <vtkPoints.h>
20 #include <vtkFloatArray.h>
21 #include <vtkPolyDataMapper.h>
22 #include <vtkLookupTable.h>
23 #include <vtkRenderer.h>
24 #include <vtkScalarBarActor.h>
25 #include <vtkSmartPointer.h>
26 #include <vtkOrientationMarkerWidget.h>
27 #include <base/Pose.hpp>
28 #include <base/Eigen.hpp>
35 Q_CLASSINFO(
"Author",
"Leif Christensen")
45 void setScalarBarTitle(QString title);
49 void setTitle(QString title);
54 void addVector(base::Position pos, base::Vector3d flux);
59 void addVector(
double px,
double py,
double pz,
60 double x,
double y,
double z);
63 void showScalarBar(
bool b);
66 void showOrientationMarker(
bool b);
69 vtkSmartPointer<vtkPolyData> vectorfield;
70 vtkSmartPointer<vtkPoints> points;
71 vtkSmartPointer<vtkFloatArray> vectors;
72 vtkSmartPointer<vtkPolyDataMapper> glyphMapper;
73 vtkSmartPointer<vtkLookupTable> lut;
74 vtkSmartPointer<vtkRenderer> ren;
75 vtkSmartPointer<vtkScalarBarActor> scalarBar;
76 vtkSmartPointer<vtkOrientationMarkerWidget> marker;
77 double mag_max, mag_min;
Widget to display vector (flux density) fields in Vizkit based on VTK.