Commit 82101124 authored by Sebastien Barre's avatar Sebastien Barre

FIX/ENH: cleanup

parent 4443b4bb
This diff is collapsed.
......@@ -88,12 +88,14 @@
#define VTKIS_START 0
#define VTKIS_NONE 0
#define VTKIS_ROTATE 1
#define VTKIS_ZOOM 2
#define VTKIS_PAN 3
#define VTKIS_SPIN 4
#define VTKIS_DOLLY 5
#define VTKIS_PAN 2
#define VTKIS_SPIN 3
#define VTKIS_DOLLY 4
#define VTKIS_ZOOM 5
#define VTKIS_USCALE 6
#define VTKIS_TIMER 7
#define VTKIS_ANIM_OFF 0
......@@ -136,9 +138,9 @@ public:
// come very close. If AutoAdjustCameraClippingRange is off, no adjustment
// will be made per render, but the camera clipping range will still
// be reset when the camera is reset.
vtkSetClampMacro( AutoAdjustCameraClippingRange, int, 0, 1 );
vtkGetMacro( AutoAdjustCameraClippingRange, int );
vtkBooleanMacro( AutoAdjustCameraClippingRange, int );
vtkSetClampMacro(AutoAdjustCameraClippingRange, int, 0, 1 );
vtkGetMacro(AutoAdjustCameraClippingRange, int );
vtkBooleanMacro(AutoAdjustCameraClippingRange, int );
// Description:
// When an event occurs, we must determine which Renderer the event
......@@ -193,7 +195,7 @@ public:
virtual void OnLeave (int x, int y);
// Description:
// OnTimer calls RotateCamera, RotateActor etc which should be overridden by
// OnTimer calls Rotate, Rotate etc which should be overridden by
// style subclasses.
virtual void OnTimer();
......@@ -216,15 +218,22 @@ public:
// Some useful information for interaction
vtkGetMacro(State,int);
protected:
vtkInteractorStyle();
~vtkInteractorStyle();
// Description:
// Set/Get timer hint
vtkGetMacro(UseTimers,int);
vtkSetMacro(UseTimers,int);
vtkBooleanMacro(UseTimers,int);
// does ProcessEvents handle observers on this class or not
// Description:
// Does ProcessEvents handle observers on this class or not
vtkSetMacro(HandleObservers,int);
vtkGetMacro(HandleObservers,int);
vtkBooleanMacro(HandleObservers,int);
protected:
vtkInteractorStyle();
~vtkInteractorStyle();
// Will the clipping range be automatically adjust before each render?
int AutoAdjustCameraClippingRange;
void ResetCameraClippingRange();
......@@ -232,13 +241,15 @@ protected:
virtual void UpdateInternalState(int ctrl, int shift, int x, int y);
// These methods for the different interactions in different modes
// are overridden in subclasses to perform the correct motion
// This class provides a default implementation.
virtual void RotateCamera(int x, int y);
virtual void SpinCamera(int x, int y);
virtual void PanCamera(int x, int y);
virtual void DollyCamera(int x, int y);
// are overridden in subclasses to perform the correct motion. Since
// they might be called from OnTimer, they do not have mouse coord parameters
// (use GetLastPos and interactor GetEventPosition)
virtual void Rotate() {};
virtual void Spin() {};
virtual void Pan() {};
virtual void Dolly() {};
virtual void Zoom() {};
virtual void UniformScale() {};
// utility routines used by state changes below
virtual void StartState(int newstate);
......@@ -270,12 +281,16 @@ protected:
float Center[2];
float DeltaAzimuth;
float DeltaElevation;
int CtrlKey;
int ShiftKey;
int LastPos[2];
int State;
int AnimState;
float FocalDepth;
int HandleObservers; // bool: should observers be handled here
int UseTimers; // bool: should we fire timers
vtkLight *CurrentLight;
......@@ -287,11 +302,8 @@ protected:
vtkRenderer *PickedRenderer;
vtkProp *CurrentProp;
vtkActor2D *PickedActor2D;
int PropPicked; // bool: prop picked?
float PickColor[3]; // support 2D picking
int HandleObservers; // bool: should observers be handled here
int NoTimerInStartState; // bool: should StartState use timer
unsigned long LeftButtonPressTag;
unsigned long LeftButtonReleaseTag;
......
......@@ -21,7 +21,7 @@
#include "vtkRenderWindowInteractor.h"
#include "vtkObjectFactory.h"
vtkCxxRevisionMacro(vtkInteractorStyleFlight, "1.18");
vtkCxxRevisionMacro(vtkInteractorStyleFlight, "1.19");
vtkStandardNewMacro(vtkInteractorStyleFlight);
//---------------------------------------------------------------------------
......@@ -39,9 +39,6 @@ vtkInteractorStyleFlight::vtkInteractorStyleFlight()
this->AngleStepSize = 1.0;
this->AngleAccelerationFactor = 5.0;
this->OldX = 0.0;
this->OldY = 0.0;
this->AzimuthScanning = 0;
this->DisableMotion = 0;
this->FixUpVector = 0;
......@@ -49,15 +46,17 @@ vtkInteractorStyleFlight::vtkInteractorStyleFlight()
this->FixedUpVector[1] = 0;
this->FixedUpVector[2] = 1;
}
//---------------------------------------------------------------------------
vtkInteractorStyleFlight::~vtkInteractorStyleFlight()
{
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::DoTimerStart(void)
{
if (this->TimerRunning)
if (!this->UseTimers || this->TimerRunning)
{
return;
}
......@@ -65,10 +64,11 @@ void vtkInteractorStyleFlight::DoTimerStart(void)
rwi->CreateTimer(VTKI_TIMER_FIRST);
this->TimerRunning = 1;
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::DoTimerStop(void)
{
if (!this->TimerRunning)
if (!this->UseTimers || !this->TimerRunning)
{
return;
}
......@@ -76,6 +76,7 @@ void vtkInteractorStyleFlight::DoTimerStop(void)
rwi->DestroyTimer();
this->TimerRunning = 0;
}
//---------------------------------------------------------------------------
// All actual motion is performed in the timer
//---------------------------------------------------------------------------
......@@ -93,8 +94,7 @@ void vtkInteractorStyleFlight::OnTimer(void)
else
{
// Make sure CurrentCamera variable is initialized
this->FindPokedCamera(static_cast<int>(this->OldX),
static_cast<int>(this->OldY));
this->FindPokedCamera(this->LastPos[0], this->LastPos[1]);
this->SetupMotionVars();
// What sort of motion do we want
if (this->AzimuthScanning)
......@@ -126,9 +126,13 @@ void vtkInteractorStyleFlight::OnTimer(void)
this->CurrentLight->SetFocalPoint(this->CurrentCamera->GetFocalPoint());
}
rwi->Render();
rwi->CreateTimer(VTKI_TIMER_UPDATE);
if (this->UseTimers)
{
rwi->CreateTimer(VTKI_TIMER_UPDATE);
}
}
}
//---------------------------------------------------------------------------
// Mouse event handlers
//---------------------------------------------------------------------------
......@@ -147,6 +151,7 @@ void vtkInteractorStyleFlight::OnMouseMove(int vtkNotUsed(ctrl),
this->UpdateMouseSteering(x, y);
}
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::OnLeftButtonDown(int vtkNotUsed(ctrl),
int vtkNotUsed(shift),
......@@ -159,14 +164,15 @@ void vtkInteractorStyleFlight::OnLeftButtonDown(int vtkNotUsed(ctrl),
}
if (!this->Reversing)
{
this->OldX = this->X2 = x;
this->OldY = this->Y2 = y;
this->LastPos[0] = this->X2 = x;
this->LastPos[1] = this->Y2 = y;
this->YawAngle = 0;
this->PitchAngle = 0;
this->DoTimerStart();
}
this->Flying = 1;
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::OnLeftButtonUp(int vtkNotUsed(ctrl),
int vtkNotUsed(shift),
......@@ -175,6 +181,7 @@ void vtkInteractorStyleFlight::OnLeftButtonUp(int vtkNotUsed(ctrl),
{
this->Flying = 0;
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::OnMiddleButtonDown(int vtkNotUsed(ctrl),
int vtkNotUsed(shift),
......@@ -188,6 +195,7 @@ void vtkInteractorStyleFlight::OnMiddleButtonDown(int vtkNotUsed(ctrl),
// want to add some more functions???
// I've got no middle mouse button :(
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::OnMiddleButtonUp(int vtkNotUsed(ctrl),
int vtkNotUsed(shift),
......@@ -195,6 +203,7 @@ void vtkInteractorStyleFlight::OnMiddleButtonUp(int vtkNotUsed(ctrl),
int vtkNotUsed(y))
{
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::OnRightButtonDown(int vtkNotUsed(ctrl),
int vtkNotUsed(shift),
......@@ -207,14 +216,15 @@ void vtkInteractorStyleFlight::OnRightButtonDown(int vtkNotUsed(ctrl),
}
if (!this->Flying)
{
this->OldX = this->X2 = x;
this->OldY = this->Y2 = y;
this->LastPos[0] = this->X2 = x;
this->LastPos[1] = this->Y2 = y;
this->YawAngle = 0;
this->PitchAngle = 0;
this->DoTimerStart();
}
this->Reversing = 1;
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::OnRightButtonUp(int vtkNotUsed(ctrl),
int vtkNotUsed(shift),
......@@ -223,6 +233,7 @@ void vtkInteractorStyleFlight::OnRightButtonUp(int vtkNotUsed(ctrl),
{
this->Reversing = 0;
}
//---------------------------------------------------------------------------
// Keyboard event handlers
// Note, OnChar is a key press down and then up event
......@@ -293,6 +304,7 @@ void vtkInteractorStyleFlight::OnKeyUp(int vtkNotUsed(ctrl),
}
#endif
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::OnChar(int ctrl,
int shift,
......@@ -316,6 +328,7 @@ void vtkInteractorStyleFlight::OnChar(int ctrl,
break;
}
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::JumpTo(double campos[3], double focpos[3])
{
......@@ -337,6 +350,7 @@ void vtkInteractorStyleFlight::JumpTo(double campos[3], double focpos[3])
}
rwi->Render();
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::PerformAzimuthalScan(int numsteps)
{
......@@ -347,6 +361,7 @@ void vtkInteractorStyleFlight::PerformAzimuthalScan(int numsteps)
this->AzimuthStepSize = 360.0/numsteps;
this->DoTimerStart();
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::AzimuthScan(void)
{
......@@ -359,6 +374,7 @@ void vtkInteractorStyleFlight::AzimuthScan(void)
this->DoTimerStop();
}
}
//---------------------------------------------------------------------------
// Calculate angles for next redraw in timer event
//---------------------------------------------------------------------------
......@@ -370,13 +386,14 @@ void vtkInteractorStyleFlight::UpdateMouseSteering(int x, int y)
vtkRenderWindowInteractor *rwi = this->Interactor;
int *size = rwi->GetSize();
double scalefactor = 5.0*this->CurrentCamera->GetViewAngle()/(double)size[0];
double dx = - (x - this->OldX)*scalefactor;
double dy = (y - this->OldY)*scalefactor;
double dx = - (x - this->LastPos[0])*scalefactor;
double dy = (y - this->LastPos[1])*scalefactor;
this->YawAngle = dx*aspeed;
this->PitchAngle = dy*aspeed;
this->X2 = x;
this->Y2 = y;
}
//---------------------------------------------------------------------------
// useful utility functions
//---------------------------------------------------------------------------
......@@ -396,6 +413,7 @@ void vtkInteractorStyleFlight::SetupMotionVars(void)
(bounds[4] - bounds[5]) * (bounds[4] - bounds[5]) );
}
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::MotionAlongVector(double vector[3], double amount)
{
......@@ -413,6 +431,7 @@ void vtkInteractorStyleFlight::MotionAlongVector(double vector[3], double amount
oldcamfoc[1] - amount * vector[1],
oldcamfoc[2] - amount * vector[2]);
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::ComputeLRVector(double vector[3])
{
......@@ -427,6 +446,7 @@ void vtkInteractorStyleFlight::ComputeLRVector(double vector[3])
vector[2] = (viewplanenormal[0] * viewup[1] -
viewplanenormal[1] * viewup[0]);
}
//---------------------------------------------------------------------------
// Perform the motion
//---------------------------------------------------------------------------
......@@ -459,8 +479,8 @@ void vtkInteractorStyleFlight::FlyByMouse(void)
this->CurrentCamera->Yaw(this->YawAngle);
this->CurrentCamera->Pitch(this->PitchAngle);
}
this->OldX = this->X2;
this->OldY = this->Y2;
this->LastPos[0] = this->X2;
this->LastPos[1] = this->Y2;
this->YawAngle = 0;
this->PitchAngle = 0;
//
......@@ -477,8 +497,7 @@ void vtkInteractorStyleFlight::FlyByMouse(void)
}
}
}
//---------------------------------------------------------------------------
// Perform the motion
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::FlyByKey(void)
{
......@@ -553,6 +572,7 @@ void vtkInteractorStyleFlight::FlyByKey(void)
this->MotionAlongVector(a_vector,-speed);
}
}
//---------------------------------------------------------------------------
void vtkInteractorStyleFlight::PrintSelf(ostream& os, vtkIndent indent)
{
......
......@@ -141,10 +141,8 @@ protected:
int AzimuthScanning;
int DisableMotion;
int FixUpVector;
double OldX;
double OldY;
double X2;
double Y2;
int X2;
int Y2;
double DiagonalLength;
double MotionStepSize;
double MotionUserScale;
......
......@@ -58,27 +58,29 @@ public:
virtual void OnRightButtonDown (int ctrl, int shift, int x, int y);
virtual void OnRightButtonUp (int ctrl, int shift, int x, int y);
virtual void OnTimer(void);
protected:
vtkInteractorStyleJoystickActor();
~vtkInteractorStyleJoystickActor();
void RotateXY(int x, int y);
void PanXY(int x, int y);
void DollyXY(int x, int y);
void SpinXY(int x, int y);
void ScaleXY(int x, int y);
// These methods for the different interactions in different modes
// are overridden in subclasses to perform the correct motion. Since
// they might be called from OnTimer, they do not have mouse coord parameters
// (use GetLastPos and interactor GetEventPosition)
virtual void Rotate();
virtual void Spin();
virtual void Pan();
virtual void Dolly();
virtual void UniformScale();
void FindPickedActor(int x, int y);
void Prop3DTransform(vtkProp3D *prop3D, double *boxCenter,
int numRotation, double **rotate,
double *scale);
int numRotation, double **rotate,
double *scale);
void Prop3DTransform(vtkProp3D *prop3D,float *boxCenter,
int NumRotation,double **rotate,
double *scale);
int NumRotation,double **rotate,
double *scale);
float MotionFactor;
float RadianToDegree; // constant: for conv from deg to rad
......
......@@ -19,7 +19,7 @@
#include "vtkObjectFactory.h"
#include "vtkCommand.h"
vtkCxxRevisionMacro(vtkInteractorStyleJoystickCamera, "1.17");
vtkCxxRevisionMacro(vtkInteractorStyleJoystickCamera, "1.18");
vtkStandardNewMacro(vtkInteractorStyleJoystickCamera);
//----------------------------------------------------------------------------
......@@ -32,21 +32,35 @@ vtkInteractorStyleJoystickCamera::~vtkInteractorStyleJoystickCamera()
{
}
//----------------------------------------------------------------------------
void vtkInteractorStyleJoystickCamera::OnTimer(void)
{
// Mouse events
//----------------------------------------------------------------------------
void vtkInteractorStyleJoystickCamera::OnMouseMove(int vtkNotUsed(ctrl),
int vtkNotUsed(shift),
int x,
int y)
{
switch (this->State)
{
case VTKIS_ROTATE:
this->FindPokedCamera(x, y);
break;
case VTKIS_PAN:
case VTKIS_ZOOM:
this->FindPokedCamera(x, y);
break;
case VTKIS_DOLLY:
this->FindPokedCamera(x, y);
break;
case VTKIS_SPIN:
this->FindPokedCamera(this->LastPos[0], this->LastPos[1]);
this->FindPokedCamera(x, y);
break;
}
this->Superclass::OnTimer();
this->LastPos[0] = x;
this->LastPos[1] = y;
}
//----------------------------------------------------------------------------
......@@ -125,6 +139,7 @@ void vtkInteractorStyleJoystickCamera::OnMiddleButtonDown(int vtkNotUsed(ctrl),
this->StartPan();
}
//----------------------------------------------------------------------------
void vtkInteractorStyleJoystickCamera::OnMiddleButtonUp(int vtkNotUsed(ctrl),
int vtkNotUsed(shift),
......@@ -151,7 +166,7 @@ void vtkInteractorStyleJoystickCamera::OnRightButtonDown(int vtkNotUsed(ctrl),
return;
}
this->StartZoom();
this->StartDolly();
}
//----------------------------------------------------------------------------
......@@ -162,11 +177,160 @@ void vtkInteractorStyleJoystickCamera::OnRightButtonUp(int vtkNotUsed(ctrl),
{
switch (this->State)
{
case VTKIS_ZOOM:
this->EndZoom();
case VTKIS_DOLLY:
this->EndDolly();
break;
}
}
//----------------------------------------------------------------------------
void vtkInteractorStyleJoystickCamera::Rotate()
{
if (this->CurrentRenderer == NULL)
{
return;
}
vtkRenderWindowInteractor *rwi = this->Interactor;
double rxf = ((double)(this->LastPos[0]) - (double)(this->Center[0])) * this->DeltaAzimuth;
double ryf = ((double)(this->LastPos[1]) - (double)(this->Center[1])) * this->DeltaElevation;
this->CurrentCamera->Azimuth(rxf);
this->CurrentCamera->Elevation(ryf);
this->CurrentCamera->OrthogonalizeViewUp();
this->ResetCameraClippingRange();
if (rwi->GetLightFollowCamera())
{
this->CurrentLight->SetPosition(this->CurrentCamera->GetPosition());
this->CurrentLight->SetFocalPoint(this->CurrentCamera->GetFocalPoint());
}
rwi->Render();
}
//----------------------------------------------------------------------------
void vtkInteractorStyleJoystickCamera::Spin()
{
if (this->CurrentRenderer == NULL)
{
return;
}
vtkRenderWindowInteractor *rwi = this->Interactor;
// spin is based on y value
double yf = ((double)(this->LastPos[1]) - (double)(this->Center[1])) /
(double)(this->Center[1]);
if (yf > 1)
{
yf = 1;
}
else if (yf < -1)
{
yf = -1;
}
double newAngle = asin(yf) * 180.0 / 3.1415926;
this->CurrentCamera->Roll(newAngle);
this->CurrentCamera->OrthogonalizeViewUp();
rwi->Render();
}
//----------------------------------------------------------------------------
void vtkInteractorStyleJoystickCamera::Pan()
{
if (this->CurrentRenderer == NULL)
{
return;
}
vtkRenderWindowInteractor *rwi = this->Interactor;
double ViewFocus[4];
// calculate the focal depth since we'll be using it a lot
this->CurrentCamera->GetFocalPoint(ViewFocus);
this->ComputeWorldToDisplay(ViewFocus[0], ViewFocus[1],
ViewFocus[2], ViewFocus);
double focalDepth = ViewFocus[2];
double NewPickPoint[4];
this->ComputeDisplayToWorld((float)this->LastPos[0], (float)this->LastPos[1],
focalDepth, NewPickPoint);
// get the current focal point and position
this->CurrentCamera->GetFocalPoint(ViewFocus);
double *ViewPoint = this->CurrentCamera->GetPosition();
/*
* Compute a translation vector, moving everything 1/10
* the distance to the cursor. (Arbitrary scale factor)
*/
double MotionVector[3];
MotionVector[0] = 0.1*(ViewFocus[0] - NewPickPoint[0]);
MotionVector[1] = 0.1*(ViewFocus[1] - NewPickPoint[1]);
MotionVector[2] = 0.1*(ViewFocus[2] - NewPickPoint[2]);
this->CurrentCamera->SetFocalPoint(MotionVector[0] + ViewFocus[0],
MotionVector[1] + ViewFocus[1],
MotionVector[2] + ViewFocus[2]);
this->CurrentCamera->SetPosition(MotionVector[0] + ViewPoint[0],
MotionVector[1] + ViewPoint[1],
MotionVector[2] + ViewPoint[2]);
if (rwi->GetLightFollowCamera())
{
this->CurrentLight->SetPosition(this->CurrentCamera->GetPosition());
this->CurrentLight->SetFocalPoint(this->CurrentCamera->GetFocalPoint());
}
rwi->Render();
}
//----------------------------------------------------------------------------
void vtkInteractorStyleJoystickCamera::Dolly()
{
if (this->CurrentRenderer == NULL)
{
return;
}
vtkRenderWindowInteractor *rwi = this->Interactor;
double dyf = 0.5 * ((double)(this->LastPos[1]) - (double)(this->Center[1])) /
(double)(this->Center[1]);
double zoomFactor = pow((double)1.1, dyf);
if (zoomFactor < 0.5 || zoomFactor > 1.5)
{
vtkErrorMacro("Bad zoom factor encountered");
}
if (this->CurrentCamera->GetParallelProjection())
{
this->CurrentCamera->
SetParallelScale(this->CurrentCamera->GetParallelScale()/zoomFactor);
}
else
{
this->CurrentCamera->Dolly(zoomFactor);
this->ResetCameraClippingRange();
}
if (rwi->GetLightFollowCamera())
{
this->CurrentLight->SetPosition(this->CurrentCamera->GetPosition());
this->CurrentLight->SetFocalPoint(this->CurrentCamera->GetFocalPoint());
}
rwi->Render();
}
//----------------------------------------------------------------------------
void vtkInteractorStyleJoystickCamera::PrintSelf(ostream& os, vtkIndent indent)
{
......
......@@ -48,6 +48,7 @@ public:
// Description:
// Event bindings controlling the effects of pressing mouse buttons
// or moving the mouse.
virtual void OnMouseMove (int ctrl, int shift, int x, int y);
virtual void OnLeftButtonDown (int ctrl, int shift, int x, int y);
virtual void OnLeftButtonUp (int ctrl, int shift, int x, int y);
virtual void OnMiddleButtonDown(int ctrl, int shift, int x, int y);
......@@ -55,12 +56,19 @@ public:
virtual void OnRightButtonDown (int ctrl, int shift, int x, int y);
virtual void OnRightButtonUp (int ctrl, int shift, int x, int y);
virtual void OnTimer(void);
protected:
vtkInteractorStyleJoystickCamera();
~vtkInteractorStyleJoystickCamera();
// These methods for the different interactions in different modes
// are overridden in subclasses to perform the correct motion. Since
// they are called by OnTimer, they do not have mouse coord parameters
// (use GetLastPos and interactor GetEventPosition)
virtual void Rotate();
virtual void Spin();
virtual void Pan();
virtual void Dolly();
private:
vtkInteractorStyleJoystickCamera(const vtkInteractorStyleJoystickCamera&); // Not implemented.
void operator=(const vtkInteractorStyleJoystickCamera&); // Not implemented.
......
......@@ -24,7 +24,7 @@
#include "vtkInteractorStyleTrackballActor.h"
#include "vtkInteractorStyleTrackballCamera.h"
vtkCxxRevisionMacro(vtkInteractorStyleSwitch, "1.15");
vtkCxxRevisionMacro(vtkInteractorStyleSwitch, "1.16");
vtkStandardNewMacro(vtkInteractorStyleSwitch);
//----------------------------------------------------------------------------
......@@ -55,6 +55,7 @@ vtkInteractorStyleSwitch::~vtkInteractorStyleSwitch()
this->TrackballCamera = NULL;
}
//----------------------------------------------------------------------------
void vtkInteractorStyleSwitch::SetAutoAdjustCameraClippingRange( int value )
{
if ( value == this->AutoAdjustCameraClippingRange )
......@@ -78,6 +79,7 @@ void vtkInteractorStyleSwitch::SetAutoAdjustCameraClippingRange( int value )
this->Modified();
}
//----------------------------------------------------------------------------
void vtkInteractorStyleSwitch::SetCurrentStyleToJoystickActor()
{
this->JoystickOrTrackball = VTKIS_JOYSTICK;
......@@ -85,6 +87,7 @@ void vtkInteractorStyleSwitch::SetCurrentStyleToJoystickActor()
this->SetCurrentStyle();
}
//----------------------------------------------------------------------------
void vtkInteractorStyleSwitch::SetCurrentStyleToJoystickCamera()
{
this->JoystickOrTrackball = VTKIS_JOYSTICK;
......@@ -92,6 +95,7 @@ void vtkInteractorStyleSwitch::SetCurrentStyleToJoystickCamera()
this->SetCurrentStyle();