24 #include "vtkMatrix4x4.h"
25 #include "vtkLinearTransform.h"
30 : QWidget(parent, f), m_Geometry(nullptr), m_ResetGeometry(nullptr), m_Controls(nullptr)
47 m_Controls =
new Ui::QmitkInteractiveTransformationWidgetControls;
83 if (defaultValues.IsNotNull())
87 double eulerAlphaDegrees = transformConversionHelper->GetOrientation().rotation_euler_angles()[0] / vnl_math::pi * 180;
88 double eulerBetaDegrees = transformConversionHelper->GetOrientation().rotation_euler_angles()[1] / vnl_math::pi * 180;
89 double eulerGammaDegrees = transformConversionHelper->GetOrientation().rotation_euler_angles()[2] / vnl_math::pi * 180;
129 translationParams[0] = v;
130 translationParams[1] =
m_Controls->m_YTransSlider->value();
131 translationParams[2] =
m_Controls->m_ZTransSlider->value();
145 translationParams[0] =
m_Controls->m_XTransSlider->value();
146 translationParams[1] = v;
147 translationParams[2] =
m_Controls->m_ZTransSlider->value();
161 translationParams[0] =
m_Controls->m_XTransSlider->value();
162 translationParams[1] =
m_Controls->m_YTransSlider->value();
163 translationParams[2] = v;
180 translateVec[1] = translateVector[1] - m_TranslationVector[1];
181 translateVec[2] = translateVector[2] - m_TranslationVector[2];
184 m_TranslationVector[0] = translateVector[0];
185 m_TranslationVector[1] = translateVector[1];
186 m_TranslationVector[2] = translateVector[2];
189 qApp->processEvents();
196 rotationParams[0] = v;
197 rotationParams[1] =
m_Controls->m_YRotSlider->value();
198 rotationParams[2] =
m_Controls->m_ZRotSlider->value();
203 this->
Rotate(rotationParams);
209 rotationParams[0] =
m_Controls->m_XRotSlider->value();
210 rotationParams[1] = v;
211 rotationParams[2] =
m_Controls->m_ZRotSlider->value();
216 this->
Rotate(rotationParams);
222 rotationParams[0]=
m_Controls->m_XRotSlider->value();
223 rotationParams[1]=
m_Controls->m_YRotSlider->value();
228 this->
Rotate(rotationParams);
234 double radianX = rotateVector[0] * vnl_math::pi / 180;
235 double radianY = rotateVector[1] * vnl_math::pi / 180;
236 double radianZ = rotateVector[2] * vnl_math::pi / 180;
243 rotationTransform->SetOrientation(rotation);
250 oldTransform->SetOrientation(identity);
253 rotationTransform->Compose(oldTransform);
256 m_Geometry->SetIndexToWorldTransform(rotationTransform->GetAffineTransform3D());
257 qApp->processEvents();
276 qApp->processEvents();
itk::SmartPointer< Self > Pointer
static RenderingManager * GetInstance()
vnl_quaternion< ScalarType > Quaternion
void RequestUpdateAll(RequestType type=REQUEST_UPDATE_ALL)