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

Function from_json

Modules/Core/src/DataManagement/mitkLevelWindow.cpp:551–567  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

549 }
550
551 void from_json(const nlohmann::json& j, LevelWindow& lw)
552 {
553 lw.SetRangeMinMax(
554 j["CurrentRange"]["Min"].get<ScalarType>(),
555 j["CurrentRange"]["Max"].get<ScalarType>());
556
557 lw.SetDefaultLevelWindow(
558 j["DefaultSettings"]["Level"].get<ScalarType>(),
559 j["DefaultSettings"]["Window"].get<ScalarType>());
560
561 lw.SetLevelWindow(
562 j["CurrentSettings"]["Level"].get<ScalarType>(),
563 j["CurrentSettings"]["Window"].get<ScalarType>());
564
565 lw.SetFixed(j["Fixed"].get<bool>());
566 lw.SetFloatingValues(j["IsFloatingImage"].get<bool>());
567 }
568}

Callers

nothing calls this directly

Calls 5

SetRangeMinMaxMethod · 0.80
SetDefaultLevelWindowMethod · 0.80
SetFloatingValuesMethod · 0.80
SetLevelWindowMethod · 0.45
SetFixedMethod · 0.45

Tested by

no test coverage detected