1 /*=========================================================================
5 Author : Joel Schaerer (joel.schaerer@insa-lyon.fr)
9 Léon Bérard cancer center http://oncora1.lyon.fnclcc.fr
10 CREATIS-LRMN http://www.creatis.insa-lyon.fr
12 This program is free software: you can redistribute it and/or modify
13 it under the terms of the GNU General Public License as published by
14 the Free Software Foundation, version 3 of the License.
16 This program is distributed in the hope that it will be useful,
17 but WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 GNU General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with this program. If not, see <http://www.gnu.org/licenses/>.
24 =========================================================================*/
25 #ifndef vvMidPosition_h
26 #define vvMidPosition_h
30 #include <QProgressDialog>
32 #include "vvSlicerManager.h"
34 class vvMidPosition : public QThread
39 ///Call this to trigger the computation in a separate thread and wait until it's done
41 vvSlicerManager * slicer_manager;
42 ///True if there is an error during the computation
44 std::string error_message;
45 vvImage::Pointer output;
46 int reference_image_index;
49 ///This is called everytime the main thread wakes up, and updates a progress bar
50 void update_progress();
51 QProgressDialog p_bar;
52 ///Counter for the progress bar. We should use a mutex, but it turns out it isn't needed