From: dsarrut Date: Wed, 15 Dec 2010 08:50:49 +0000 (+0000) Subject: remove debug X-Git-Tag: v1.2.0~286 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=2891992b085ed775e4983a09baa794b1c0d3583e;p=clitk.git remove debug --- diff --git a/vv/vvImageReader.txx b/vv/vvImageReader.txx index 2ebec0e..e2e98bb 100644 --- a/vv/vvImageReader.txx +++ b/vv/vvImageReader.txx @@ -68,14 +68,12 @@ void vvImageReader::UpdateWithDim(std::string InputPixelType) template void vvImageReader::UpdateWithDimAndInputPixelType() { - - // DD(mType); - if (mType == MERGEDWITHTIME) // In this case we can load the images // one at the time to avoid excessive // memory use { mImage=vvImage::New(); + for (std::vector::const_iterator i=mInputFilenames.begin(); i!=mInputFilenames.end(); i++) { typedef itk::Image< InputPixelType, VImageDimension-1 > InputImageType; typedef itk::ImageFileReader ReaderType; diff --git a/vv/vvLandmarks.cxx b/vv/vvLandmarks.cxx index b0e228c..f092729 100644 --- a/vv/vvLandmarks.cxx +++ b/vv/vvLandmarks.cxx @@ -14,7 +14,7 @@ - BSD See included LICENSE.txt file - CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html -======================================================================-====*/ + ======================================================================-====*/ #include "vvLandmarks.h" #include @@ -68,11 +68,11 @@ void vvLandmarks::AddLandmark(float x,float y,float z,float t,double value) mPoints[int(t)]->InsertNextPoint(x,y,z); /*std::stringstream numberVal; - numberVal << (mLandmarks.size()-1); - vvLandmarksGlyph *number = vvLandmarksGlyph::New(); - number->SetText(numberVal.str().c_str()); - number->BackingOff(); - mText.push_back(number);*/ + numberVal << (mLandmarks.size()-1); + vvLandmarksGlyph *number = vvLandmarksGlyph::New(); + number->SetText(numberVal.str().c_str()); + number->BackingOff(); + mText.push_back(number);*/ mIds->InsertNextTuple1(0.55); //mIds->InsertTuple1(mLandmarks.size(),mLandmarks.size()); SetTime(int(t)); @@ -81,7 +81,7 @@ void vvLandmarks::AddLandmark(float x,float y,float z,float t,double value) void vvLandmarks::RemoveLastLandmark() { mPoints[mLandmarks.back().coordinates[3]]->SetNumberOfPoints( - mPoints[mLandmarks.back().coordinates[3]]->GetNumberOfPoints()-1); + mPoints[mLandmarks.back().coordinates[3]]->GetNumberOfPoints()-1); mPolyData->Modified(); //mText.pop_back(); mLandmarks.pop_back(); @@ -133,7 +133,6 @@ void vvLandmarks::LoadFile(std::string filename) } else mFormatVersion=0; } - DD(mFormatVersion); if (stringline.size() > 1) { vvLandmark point; int previousSpace = 0; @@ -193,7 +192,7 @@ void vvLandmarks::LoadFile(std::string filename) mLandmarks.push_back(point); mIds->InsertNextTuple1(0.55); mPoints[int(point.coordinates[3])]->InsertNextPoint( - point.coordinates[0],point.coordinates[1],point.coordinates[2]); + point.coordinates[0],point.coordinates[1],point.coordinates[2]); } } SetTime(0); diff --git a/vv/vvMaximumIntensityProjection.cxx b/vv/vvMaximumIntensityProjection.cxx index 4eb84f7..c7ffb52 100644 --- a/vv/vvMaximumIntensityProjection.cxx +++ b/vv/vvMaximumIntensityProjection.cxx @@ -29,6 +29,7 @@ void vvMaximumIntensityProjection::Compute(vvSlicerManager * slicer_manager) { + mCurrentSlicerManager = slicer_manager; mDimension = QInputDialog::getInteger(0, "MIP Axis","Choose the axis along which to perform the MIP",0,0,\ slicer_manager->GetImage()->GetNumberOfDimensions()-1,1); #define TRY_TYPE(TYPE) \ @@ -77,4 +78,7 @@ void vvMaximumIntensityProjection::Update_WithDimAndPixelType(vvImage::Pointer i filter->SetInput(input); filter->Update(); mOutputImage=vvImageFromITK(filter->GetOutput()); + // std::ostringstream osstream; + // osstream << "MIP_" << mCurrentSlicerManager->GetSlicer(0)->GetFileName() << ".mhd"; + // AddImage(mOutputImage,osstream.str()); } diff --git a/vv/vvMaximumIntensityProjection.h b/vv/vvMaximumIntensityProjection.h index 9d15164..8f37701 100644 --- a/vv/vvMaximumIntensityProjection.h +++ b/vv/vvMaximumIntensityProjection.h @@ -35,6 +35,7 @@ protected: vvImage::Pointer mOutputImage; //Dimension along which to compute the MIP unsigned int mDimension; + vvSlicerManager * mCurrentSlicerManager; }; #endif diff --git a/vv/vvSlicer.cxx b/vv/vvSlicer.cxx index 564dcf2..d1f084c 100644 --- a/vv/vvSlicer.cxx +++ b/vv/vvSlicer.cxx @@ -648,6 +648,11 @@ void vvSlicer::SetSliceOrientation(int orientation) if (range) this->Slice = static_cast((range[0] + range[1]) * 0.5); + // Go to current cursor position + // double* cursorPos = GetCursorPosition(); + // DDV(cursorPos, 3); + // SetCurrentPosition(cursorPos[0],cursorPos[1],cursorPos[2],cursorPos[3]); + this->UpdateOrientation(); this->UpdateDisplayExtent();