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

Method LocalStorage

Modules/Multilabel/src/mitkMultiLabelSegmentationVtkMapper3D.cpp:501–533  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

499}
500
501mitk::MultiLabelSegmentationVtkMapper3D::LocalStorage::LocalStorage() : m_LastUpdateTimeStep(0)
502{
503 m_Actors = vtkSmartPointer<vtkPropAssembly>::New();
504
505 m_VtkLookupTable = vtkSmartPointer<vtkLookupTable>::New();
506 m_VtkLookupTable->SetNumberOfTableValues(static_cast<vtkIdType>(mitk::Label::MAX_LABEL_VALUE) + 1);
507 m_VtkLookupTable->SetTableRange(0.0, static_cast<double>(mitk::Label::MAX_LABEL_VALUE));
508 m_VtkLookupTable->IndexedLookupOff();
509 // Initialize all entries to fully transparent so unused label values do not pick up
510 // a default ramp color when referenced by surface-nets cell scalars.
511 for (vtkIdType i = 0; i <= mitk::Label::MAX_LABEL_VALUE; ++i)
512 {
513 m_VtkLookupTable->SetTableValue(i, 0.0, 0.0, 0.0, 0.0);
514 }
515 m_VtkLookupTable->Build();
516
517 m_UseFadedPipeline = false;
518
519 m_SegPreferences = nullptr;
520 m_3DRenderingPreference = true;
521 m_LastSmoothed = true;
522 m_LastOpacityFactor = 1.0f;
523
524 auto prefService = mitk::CoreServices::GetPreferencesService();
525 if (nullptr != prefService)
526 {
527 auto systemPref = prefService->GetSystemPreferences();
528 if (nullptr != systemPref)
529 {
530 m_SegPreferences = systemPref->Node("/org.mitk.views.segmentation");
531 }
532 }
533}

Callers

nothing calls this directly

Calls 4

NewFunction · 0.50
SetTableValueMethod · 0.45
GetSystemPreferencesMethod · 0.45
NodeMethod · 0.45

Tested by

no test coverage detected