Authors belong to:
- University of LYON http://www.universite-lyon.fr/
- - Léon Bérard cancer center http://oncora1.lyon.fnclcc.fr
+ - Léon Bérard cancer center http://www.centreleonberard.fr
- CREATIS CNRS laboratory http://www.creatis.insa-lyon.fr
This software is distributed WITHOUT ANY WARRANTY; without even
- BSD See included LICENSE.txt file
- CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
-======================================================================-====*/
+===========================================================================**/
// vv
#include "vvToolCropImage.h"
//------------------------------------------------------------------------------
void vvToolCropImage::closeEvent(QCloseEvent *event)
{
- // Reset extends
- for(int i=0; i<mExtentSize; i++) mReducedExtent[i] = mInitialExtent[i];
- UpdateExtent();
+ if(mCurrentSlicerManager){
+ // Reset extends
+ for(int i=0; i<mExtentSize; i++) mReducedExtent[i] = mInitialExtent[i];
+ UpdateExtent();
+ }
event->accept();
}
//------------------------------------------------------------------------------
{
xmaxSlider->setMinimum(xminSlider->value());
mReducedExtent[0] = xminSlider->value();
+ std::cout<<"new value "<<mReducedExtent[0]<<std::endl;
UpdateExtent();
}
//------------------------------------------------------------------------------
// Retrieve result and display it
vvImage::Pointer output = filter->GetOutputVVImage();
std::ostringstream osstream;
- osstream << "Croped_" << mCurrentSlicerManager->GetSlicer(0)->GetFileName() << ".mhd";
+ osstream << "Cropped_" << mCurrentSlicerManager->GetSlicer(0)->GetFileName() << ".mhd";
AddImage(output,osstream.str());
// End