+ // ----------------------------------------------------------------
+ StartNewStep("[Station7] Limits with LeftSuperiorPulmonaryVein");
+ try {
+ MaskImagePointer LeftSuperiorPulmonaryVein = GetAFDB()->template GetImage<MaskImageType>("LeftSuperiorPulmonaryVein");
+ typedef SliceBySliceRelativePositionFilter<MaskImageType> SliceRelPosFilterType;
+ typename SliceRelPosFilterType::Pointer sliceRelPosFilter = SliceRelPosFilterType::New();
+ sliceRelPosFilter->SetInput(m_Working_Support);
+ sliceRelPosFilter->SetInputObject(LeftSuperiorPulmonaryVein);
+ sliceRelPosFilter->SetDirection(2);
+ sliceRelPosFilter->SetFuzzyThreshold(GetFuzzyThresholdForS7("LeftSuperiorPulmonaryVein"));
+ sliceRelPosFilter->AddOrientationTypeString("NotLeftTo");
+ sliceRelPosFilter->AddOrientationTypeString("NotAntTo");
+ sliceRelPosFilter->SetIntermediateSpacingFlag(true);
+ sliceRelPosFilter->SetIntermediateSpacing(3);
+ sliceRelPosFilter->SetUniqueConnectedComponentBySlice(false);
+ sliceRelPosFilter->SetAutoCropFlag(false);
+ sliceRelPosFilter->IgnoreEmptySliceObjectFlagOn();
+ sliceRelPosFilter->Update();
+ m_Working_Support = sliceRelPosFilter->GetOutput();
+ StopCurrentStep<MaskImageType>(m_Working_Support);
+ }
+ catch (clitk::ExceptionObject e) {
+ std::cout << "Not LeftSuperiorPulmonaryVein, skip" << std::endl;
+ }
+
+ // ----------------------------------------------------------------
+ StartNewStep("[Station7] Limits with RightSuperiorPulmonaryVein");
+ try {
+ MaskImagePointer RightSuperiorPulmonaryVein = GetAFDB()->template GetImage<MaskImageType>("RightSuperiorPulmonaryVein");
+ typedef SliceBySliceRelativePositionFilter<MaskImageType> SliceRelPosFilterType;
+ typename SliceRelPosFilterType::Pointer sliceRelPosFilter = SliceRelPosFilterType::New();
+ sliceRelPosFilter->SetInput(m_Working_Support);
+ sliceRelPosFilter->SetInputObject(RightSuperiorPulmonaryVein);
+ sliceRelPosFilter->SetDirection(2);
+ sliceRelPosFilter->SetFuzzyThreshold(GetFuzzyThresholdForS7("RightSuperiorPulmonaryVein"));
+ sliceRelPosFilter->AddOrientationTypeString("NotRightTo");
+ sliceRelPosFilter->AddOrientationTypeString("NotAntTo");
+ sliceRelPosFilter->AddOrientationTypeString("NotPostTo");
+ sliceRelPosFilter->SetIntermediateSpacingFlag(true);
+ sliceRelPosFilter->SetIntermediateSpacing(3);
+ sliceRelPosFilter->SetUniqueConnectedComponentBySlice(false);
+ sliceRelPosFilter->SetAutoCropFlag(false);
+ sliceRelPosFilter->IgnoreEmptySliceObjectFlagOn();
+ sliceRelPosFilter->Update();
+ m_Working_Support = sliceRelPosFilter->GetOutput();
+ StopCurrentStep<MaskImageType>(m_Working_Support);
+ }
+ catch (clitk::ExceptionObject e) {
+ std::cout << "Not RightSuperiorPulmonaryVein, skip" << std::endl;
+ }
+
+ // ----------------------------------------------------------------
+ StartNewStep("[Station7] Limits with RightPulmonaryArtery");
+ MaskImagePointer RightPulmonaryArtery = GetAFDB()->template GetImage<MaskImageType>("RightPulmonaryArtery");
+ typedef SliceBySliceRelativePositionFilter<MaskImageType> SliceRelPosFilterType;
+ typename SliceRelPosFilterType::Pointer sliceRelPosFilter = SliceRelPosFilterType::New();
+ sliceRelPosFilter->SetInput(m_Working_Support);
+ sliceRelPosFilter->SetInputObject(RightPulmonaryArtery);
+ sliceRelPosFilter->SetDirection(2);
+ sliceRelPosFilter->SetFuzzyThreshold(GetFuzzyThresholdForS7("RightPulmonaryArtery"));
+ sliceRelPosFilter->AddOrientationTypeString("NotAntTo");
+ sliceRelPosFilter->SetIntermediateSpacingFlag(true);
+ sliceRelPosFilter->SetIntermediateSpacing(3);
+ sliceRelPosFilter->SetUniqueConnectedComponentBySlice(false);
+ sliceRelPosFilter->SetAutoCropFlag(false);
+ sliceRelPosFilter->IgnoreEmptySliceObjectFlagOn();
+ sliceRelPosFilter->Update();
+ m_Working_Support = sliceRelPosFilter->GetOutput();
+ StopCurrentStep<MaskImageType>(m_Working_Support);
+
+ // ----------------------------------------------------------------
+ StartNewStep("[Station7] Limits with LeftPulmonaryArtery");
+ MaskImagePointer LeftPulmonaryArtery = GetAFDB()->template GetImage<MaskImageType>("LeftPulmonaryArtery");
+ sliceRelPosFilter = SliceRelPosFilterType::New();
+ sliceRelPosFilter->SetInput(m_Working_Support);
+ sliceRelPosFilter->SetInputObject(LeftPulmonaryArtery);
+ sliceRelPosFilter->SetDirection(2);
+ sliceRelPosFilter->SetFuzzyThreshold(GetFuzzyThresholdForS7("LeftPulmonaryArtery"));
+ sliceRelPosFilter->AddOrientationTypeString("NotAntTo");
+ sliceRelPosFilter->SetIntermediateSpacingFlag(true);
+ sliceRelPosFilter->SetIntermediateSpacing(3);
+ sliceRelPosFilter->SetUniqueConnectedComponentBySlice(false);
+ sliceRelPosFilter->SetAutoCropFlag(false);
+ sliceRelPosFilter->IgnoreEmptySliceObjectFlagOn();
+ sliceRelPosFilter->Update();
+ m_Working_Support = sliceRelPosFilter->GetOutput();
+ StopCurrentStep<MaskImageType>(m_Working_Support);
+
+ StartNewStep("[Station7] Limits with SVC");
+ MaskImagePointer SVC = GetAFDB()->template GetImage<MaskImageType>("SVC");
+ sliceRelPosFilter = SliceRelPosFilterType::New();
+ sliceRelPosFilter->SetInput(m_Working_Support);
+ sliceRelPosFilter->SetInputObject(SVC);
+ sliceRelPosFilter->SetDirection(2);
+ sliceRelPosFilter->SetFuzzyThreshold(GetFuzzyThresholdForS7("SVC"));
+ sliceRelPosFilter->AddOrientationTypeString("NotRightTo");
+ sliceRelPosFilter->AddOrientationTypeString("NotAntTo");
+ sliceRelPosFilter->SetIntermediateSpacingFlag(true);
+ sliceRelPosFilter->SetIntermediateSpacing(3);
+ sliceRelPosFilter->SetUniqueConnectedComponentBySlice(false);
+ sliceRelPosFilter->SetAutoCropFlag(true);
+ sliceRelPosFilter->IgnoreEmptySliceObjectFlagOn();
+ sliceRelPosFilter->Update();
+ m_Working_Support = sliceRelPosFilter->GetOutput();
+ StopCurrentStep<MaskImageType>(m_Working_Support);
+
+ // End
+ m_ListOfStations["7"] = m_Working_Support;