]> Creatis software - creaMaracasVisu.git/blob - lib/maracasVisuLib/src/interface/wxWindows/include/wxMaracasQuantification.cxx
9372e82af0d134e44500df06c83385637a5d2588
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / include / wxMaracasQuantification.cxx
1 /*=========================================================================
2
3   Program:   wxMaracas
4   Module:    $RCSfile: wxMaracasQuantification.cxx,v $
5   Language:  C++
6   Date:      $Date: 2009/05/14 13:54:54 $
7   Version:   $Revision: 1.1 $
8
9   Copyright: (c) 2002, 2003
10   License:
11
12      This software is distributed WITHOUT ANY WARRANTY; without even
13      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14      PURPOSE.  See the above copyright notice for more information.
15
16 =========================================================================*/
17
18 #include "wxMaracasFrame.h"
19 #include "wxMaracasQuantification.h"
20
21
22 wxMaracasQuantification::wxMaracasQuantification( wxWindow* parent,
23                                                   marInterface* mar, wxWindowID id )
24                                                  : wxPanel( parent, id, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL)
25 {
26
27   _mar = mar;
28
29   // Create the main frame window
30   _3DQuantif = new wxQuantificationWidget( this, -1 );
31   wxBoxSizer* szTop = new wxBoxSizer( wxVERTICAL );
32   szTop->Add( _3DQuantif, 1  , wxEXPAND |  wxALL , 0 );
33   this->SetAutoLayout( true );
34   this->SetSizer( szTop );
35   szTop->Fit( this );
36   szTop->SetSizeHints( this );
37 }
38 //----------------------------------------------------------------------------
39 wxMaracasQuantification::~wxMaracasQuantification( )
40 {
41 }
42 //----------------------------------------------------------------------------
43 void wxMaracasQuantification::LoadData( ){
44   _3DQuantif->ShowMARACASData( _mar );
45 }
46 //----------------------------------------------------------------------------
47 void wxMaracasQuantification::Do_Quant( ){
48   // _3DQuantif->Do_Quant( );
49 }
50 //----------------------------------------------------------------------------
51 void wxMaracasQuantification::SetSlider_Isovalue_Opacity(int isovalue,int opacity){
52         _3DQuantif->SetSlider_Isovalue_Opacity(isovalue,opacity);
53 }
54 //----------------------------------------------------------------------------
55 void wxMaracasQuantification::RegenerateAll(bool all){
56         if (_3DQuantif!=NULL){
57                 _3DQuantif->Clean3D(true);
58                 if (all==true){
59                         _mar->_experiment->RegenerateAxis();
60                 } else {
61                         _mar->_experiment->RecalculateAxis();
62                 }
63                 _3DQuantif->AddAxisActors();    
64                 _3DQuantif->ResetAxis();        
65                 _3DQuantif->RefreshAxis();      
66         }
67 }
68 //----------------------------------------------------------------------------
69 void wxMaracasQuantification::CleanContours(){
70         if (_3DQuantif!=NULL){
71                 _3DQuantif->Clean3D(false);
72                 _mar->_experiment->ClearContours();
73                 _3DQuantif->ResetAxis();        
74                 _3DQuantif->RefreshAxis();      
75         }
76 }       
77 //----------------------------------------------------------------------------
78 void wxMaracasQuantification::RegenerateSignal(){
79         if (_3DQuantif!=NULL){
80                 _3DQuantif->Clean3D(false);
81                 _mar->_experiment->RegenerateSignal();
82                 _3DQuantif->ResetAxis();        
83                 _3DQuantif->RefreshAxis();      
84         }
85 }
86 //----------------------------------------------------------------------------
87
88 // EOF - wxMaracasQuantification.cxx
89
90
91
92