MCPcopy Create free account
hub / github.com/MITK/MITK / InitMembers

Method InitMembers

Modules/DataTypesExt/src/mitkAffineBaseDataInteractor3D.cpp:377–396  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

375}
376
377bool mitk::AffineBaseDataInteractor3D::InitMembers(InteractionEvent *interactionEvent)
378{
379 auto *positionEvent = dynamic_cast<InteractionPositionEvent *>(interactionEvent);
380 if (positionEvent == nullptr)
381 return false;
382
383 m_InitialPickedDisplayPoint = positionEvent->GetPointerPositionOnScreen();
384 m_InitialPickedWorldPoint = positionEvent->GetPositionInWorld();
385
386 // Get the timestep to also support 3D+t
387 int timeStep = 0;
388 if ((interactionEvent->GetSender()) != nullptr)
389 timeStep = interactionEvent->GetSender()->GetTimeStep(this->GetDataNode()->GetData());
390
391 // Make deep copy of current Geometry3D of the plane
392 this->GetDataNode()->GetData()->UpdateOutputInformation(); // make sure that the Geometry is up-to-date
393 m_OriginalGeometry =
394 static_cast<Geometry3D *>(this->GetDataNode()->GetData()->GetGeometry(timeStep)->Clone().GetPointer());
395 return true;
396}
397
398void mitk::AffineBaseDataInteractor3D::TranslateObject(StateMachineAction *, InteractionEvent *interactionEvent)
399{

Callers

nothing calls this directly

Calls 10

GetPositionInWorldMethod · 0.80
GetSenderMethod · 0.80
GetPointerMethod · 0.80
GetGeometryMethod · 0.80
GetTimeStepMethod · 0.45
GetDataMethod · 0.45
GetDataNodeMethod · 0.45
CloneMethod · 0.45

Tested by

no test coverage detected