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

Method GenerateData

Modules/AlgorithmsExt/src/mitkMaskImageFilter.cpp:107–129  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

105}
106
107void mitk::MaskImageFilter::GenerateData()
108{
109 auto input = this->GetInput();
110 auto mask = this->GetMask();
111 mitk::Image::Pointer output = this->GetOutput();
112
113 if ((output->IsInitialized() == false) || (nullptr == mask) || (mask->GetTimeGeometry()->CountTimeSteps() == 0))
114 return;
115
116 const mitk::TimeGeometry *inputTimeGeometry = input->GetTimeGeometry();
117
118 for (TimeStepType t = 0; t < inputTimeGeometry->CountTimeSteps(); ++t)
119 {
120 auto timeInMS = inputTimeGeometry->TimeStepToTimePoint(t);
121
122 m_CurrentOutputTS = t;
123 auto inputFrame = SelectImageByTimePoint(input, timeInMS);
124 auto maskFrame = SelectImageByTimePoint(mask, timeInMS);
125 AccessTwoImagesFixedDimensionByItk(inputFrame, maskFrame, InternalComputeMask, 3);
126 }
127
128 m_TimeOfHeaderInitialization.Modified();
129}

Callers

nothing calls this directly

Calls 7

GetMaskMethod · 0.95
GetInputMethod · 0.45
GetOutputMethod · 0.45
IsInitializedMethod · 0.45
CountTimeStepsMethod · 0.45
TimeStepToTimePointMethod · 0.45
ModifiedMethod · 0.45

Tested by

no test coverage detected