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

Function GetPositionInWorld

Modules/Core/src/Interactions/mitkEventFactory.cpp:213–223  ·  view source on GitHub ↗

* @brief GetPosition Return World Position as String * @param event * @return */

Source from the content-addressed store, hash-verified

211 * @return
212 */
213static std::string GetPositionInWorld(mitk::InteractionEvent *event)
214{
215 std::stringstream ss;
216 auto *pe = dynamic_cast<mitk::InteractionPositionEvent *>(event);
217 if (pe != nullptr)
218 {
219 mitk::Point3D p = pe->GetPositionInWorld();
220 ss << p[0] << "," << p[1] << "," << p[2];
221 }
222 return ss.str();
223}
224
225/**
226 * @brief GetPositionOnScreen Return PositionOnScreen as String

Callers 1

EventToXMLMethod · 0.85

Calls 1

GetPositionInWorldMethod · 0.80

Tested by

no test coverage detected