/* * Check whether the DataNode contains a pointset, if not create one and add it. */ void mitk::SinglePointDataInteractor::DataNodeChanged() { if (GetDataNode() != nullptr) { PointSet *points = dynamic_cast<PointSet *>(GetDataNode()->GetData()); if (points == NULL) { m_PointSet = PointSet::New(); GetDataNode()->SetData(m_PointSet); } else { points->Clear(); m_PointSet = points; } } }