From: dsarrut Date: Tue, 22 Mar 2011 15:50:39 +0000 (+0000) Subject: Put this tool in the tools menu (remove from experimental) X-Git-Tag: v1.2.0~136 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=39897616977eaac6a2b298e8ca4dcae70845132b;p=clitk.git Put this tool in the tools menu (remove from experimental) Display an error message for 2D images --- diff --git a/vv/vvToolMIP.cxx b/vv/vvToolMIP.cxx index 970ad35..cfa338f 100644 --- a/vv/vvToolMIP.cxx +++ b/vv/vvToolMIP.cxx @@ -3,8 +3,8 @@ Program: vv Module: $RCSfile: vvToolMIP.cxx,v $ Language: C++ - Date: $Date: 2010/10/26 12:37:58 $ - Version: $Revision: 1.1 $ + Date: $Date: 2011/03/22 15:50:39 $ + Version: $Revision: 1.2 $ Author : Bharath Navalpakkam (Bharath.Navalpakkam@creatis.insa-lyon.fr) Copyright (C) 2010 @@ -68,9 +68,9 @@ void vvToolMIP::Initialize() { SetToolName("MIP"); SetToolMenuName("Maximum Intensity Projection"); - SetToolIconFilename(":common/icons/ducky.png"); + SetToolIconFilename(":common/icons/mip.png"); SetToolTip("Compute the maximum intensity projection of an image."); - SetToolExperimental(true); + SetToolExperimental(false); } //------------------------------------------------------------------------------ @@ -98,6 +98,11 @@ void vvToolMIP::apply() void vvToolMIP::InputIsSelected(vvSlicerManager *m) { mCurrentSlicerManager =m; + if (m->GetDimension() <3) { + QMessageBox::information(this, "Wrong image dimension","Sorry, only work with 3D or 4D images."); + close(); + return; + } this->dimensionSpinBox->setMaximum(m->GetDimension()-1); }