X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=itk%2FclitkSliceBySliceRelativePositionFilter.txx;h=16571ea7a224df6b17d87425d7cf8bde619a66b0;hb=dca456c52728e92190a48a2823c4bb9d7738c8d5;hp=e68514da031c0f6f1a6725a2df78f97d0c189fe7;hpb=417f3d00b144771686b6e4ac50bba4c6fd40097f;p=clitk.git diff --git a/itk/clitkSliceBySliceRelativePositionFilter.txx b/itk/clitkSliceBySliceRelativePositionFilter.txx index e68514d..16571ea 100644 --- a/itk/clitkSliceBySliceRelativePositionFilter.txx +++ b/itk/clitkSliceBySliceRelativePositionFilter.txx @@ -43,6 +43,7 @@ SliceBySliceRelativePositionFilter(): SetObjectCCLSelectionDirection(1); ObjectCCLSelectionIgnoreSingleCCLFlagOff(); VerboseSlicesFlagOff(); + this->SetK1(vcl_acos(-1.0)/2); } //-------------------------------------------------------------------- @@ -98,7 +99,8 @@ PrintOptions(std::ostream & os) << "ObjectCCLSelectionIgnoreSingleCCLFlag = " << this->GetObjectCCLSelectionIgnoreSingleCCLFlag() << std::endl << "IgnoreEmptySliceObjectFlag = " << this->GetIgnoreEmptySliceObjectFlag() << std::endl << "(RP) FastFlag = " << this->GetFastFlag() << std::endl - << "(RP) Radius = " << this->GetRadius() << std::endl; + << "(RP) Radius = " << this->GetRadius() << std::endl + << "(RP) K1 = " << this->GetK1() << std::endl; } //-------------------------------------------------------------------- @@ -238,6 +240,10 @@ GenerateOutputInformation() int nb=0; mObjectSlices[i] = LabelizeAndCountNumberOfObjects(mObjectSlices[i], 0, true, 1, nb); + if (GetVerboseSlicesFlag()) { + std::cout << "slice " << i << " nb = " << nb << std::endl; + } + // If no object and empty slices and if we need the full fuzzy map, create a dummy one. if ((nb==0) && (this->GetFuzzyMapOnlyFlag())) { typename FloatSliceType::Pointer one = FloatSliceType::New(); @@ -295,6 +301,7 @@ GenerateOutputInformation() if (GetVerboseSlicesFlag()) { std::cout << "Slice " << i << std::endl; relPosFilter->VerboseStepFlagOn(); + //relPosFilter->WriteStepFlagOn(); } relPosFilter->WriteStepFlagOff(); // relPosFilter->VerboseMemoryFlagOn(); @@ -319,6 +326,7 @@ GenerateOutputInformation() // relPosFilter->SetComputeFuzzyMapFlag(this->GetComputeFuzzyMapFlag()); relPosFilter->SetFastFlag(this->GetFastFlag()); relPosFilter->SetRadius(this->GetRadius()); + relPosFilter->SetK1(this->GetK1()); // Go ! relPosFilter->Update();