| 31 | { |
| 32 | } |
| 33 | void Step7::StartRegionGrowing() |
| 34 | { |
| 35 | Step6::StartRegionGrowing(); |
| 36 | |
| 37 | std::cout << "7"; |
| 38 | if (m_ResultImage.IsNotNull()) |
| 39 | { |
| 40 | m_ResultNode->SetProperty("volumerendering", mitk::BoolProperty::New(false)); |
| 41 | |
| 42 | vtkMarchingCubes *surfaceCreator = vtkMarchingCubes::New(); |
| 43 | surfaceCreator->SetInputData(m_ResultImage->GetVtkImageData()); |
| 44 | surfaceCreator->SetValue(0, 1); |
| 45 | surfaceCreator->Update(); |
| 46 | |
| 47 | mitk::Surface::Pointer surface = mitk::Surface::New(); |
| 48 | surface->SetVtkPolyData(surfaceCreator->GetOutput()); // VTK6_TODO |
| 49 | |
| 50 | mitk::DataNode::Pointer surfaceNode = mitk::DataNode::New(); |
| 51 | surfaceNode->SetData(surface); |
| 52 | |
| 53 | m_DataStorage->Add(surfaceNode); |
| 54 | |
| 55 | mitk::RenderingManager::GetInstance()->RequestUpdateAll(); |
| 56 | std::cout << "8"; |
| 57 | surfaceCreator->Delete(); |
| 58 | } |
| 59 | |
| 60 | std::cout << "9"; |
| 61 | } |
| 62 | |
| 63 | /** |
| 64 | \example Step7.cpp |
nothing calls this directly
no test coverage detected