#include <cpExtensions/cpExtensions_Export.h>
#include <cpExtensions/Interaction/BaseInteractorStyle.h>
-#include <vtkSphereWidget2.h>
+#include <vtkSphereWidget.h>
namespace cpExtensions
{
/**
*/
class cpExtensions_EXPORT SphereWidget
- : public vtkSphereWidget2
+ : public vtkSphereWidget
{
public:
typedef SphereWidget Self;
- vtkTypeMacro( SphereWidget, vtkSphereWidget2 );
+ vtkTypeMacro( SphereWidget, vtkSphereWidget );
typedef cpExtensions::Interaction::BaseInteractorStyle TBaseStyle;
typedef TBaseStyle::TMouseCommand TMouseCommand;
static Self* New( );
virtual void SetInteractor( vtkRenderWindowInteractor* rwi );
-
-
-
+ void SetCenter(double* center);
+ void SetAxis(int axis);
+ int GetAxis();
+ double * GetPosition();
protected:
SphereWidget( );
virtual ~SphereWidget( );
void* data, const TBaseStyle::ButtonID& button,
int* idx, double* pos, bool alt, bool ctr, bool sft
);
+ static void _MouseMove(
+ void* data, const TBaseStyle::ButtonID& button,
+ int* idx, double* pos, bool alt, bool ctr, bool sft
+ );
+
static void _KeyPress(void* data, const char& key);
+ static void SetCenter(void* data, double* center);
+
+ static void SetAxis(void* data, int axis);
+ static int GetAxis(void* data);
+ static double * GetPosition(void* data);
private:
+ int m_axis;
+
// Purposely not implemented
SphereWidget( const Self& );
Self& operator=( const Self& );