]> Creatis software - bbtk.git/commitdiff
New widget pipeline : progressing ...
authorguigues <guigues>
Tue, 25 Nov 2008 11:16:51 +0000 (11:16 +0000)
committerguigues <guigues>
Tue, 25 Nov 2008 11:16:51 +0000 (11:16 +0000)
29 files changed:
kernel/appli/bbfy/bbfy.cpp
kernel/src/bbtkAtomicBlackBox.cxx
kernel/src/bbtkAtomicBlackBox.h
kernel/src/bbtkAtomicBlackBoxGetSetFunctor.h
kernel/src/bbtkAtomicBlackBoxMacros.h
kernel/src/bbtkBlackBox.cxx
kernel/src/bbtkWxBlackBox.cxx
kernel/src/bbtkWxBlackBox.h
packages/itk/src/bbitkBinaryThresholdImageFilter.h
packages/itk/src/bbitkResampleImageFilter.h
packages/itkvtk/src/bbitkvtkitkImage2vtkImageData.cxx
packages/itkvtk/src/bbitkvtkitkImage2vtkImageData.h
packages/itkvtk/src/bbitkvtkvtkImageData2itkImage.cxx
packages/itkvtk/src/bbitkvtkvtkImageData2itkImage.h
packages/std/src/bbstdASCII.cxx
packages/std/src/bbstdASCII.h
packages/vtk/src/bbvtkImagePlanes.cxx
packages/vtk/src/bbvtkImagePlanes.h
packages/vtk/src/bbvtkIsoSurfaceExtractor.cxx
packages/vtk/src/bbvtkIsoSurfaceExtractor.h
packages/vtk/src/bbvtkMIPCreator.cxx
packages/vtk/src/bbvtkMIPCreator.h
packages/vtk/src/bbvtkVecImageGaussianSmooth.cxx
packages/vtk/src/bbvtkVecImageGaussianSmooth.h
packages/vtk/src/bbvtkVecIsoSurfaceExtractor.cxx
packages/vtk/src/bbvtkVecIsoSurfaceExtractor.h
packages/wx/src/bbwxColourSelectorButton.cxx
packages/wx/src/bbwxColourSelectorButton.h
packages/wxvtk/src/bbwxvtkViewer3D.cxx

index db4161bbc8833c8806ee65370649b6b1e5a9e80c..c22be3230c127a088389c5f7c3401acecee11f9d 100644 (file)
@@ -589,7 +589,7 @@ void bbfy::CreateHeader()
 
   mFile << "virtual void bbUserConstructor();"<<std::endl;
   mFile << "/// User callback called in the box copy constructor"<<std::endl;
-  mFile << "virtual void bbUserCopyConstructor();"<<std::endl;
+  mFile << "virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);"<<std::endl;
   mFile << "/// User callback called in the box destructor"<<std::endl;
   mFile << "virtual void bbUserDestructor();"<<std::endl;
   mFile << "//=================================================================="<<std::endl; 
@@ -1052,7 +1052,8 @@ void bbfy::CreateCode()
   mFile << mUserConstructor << std::endl;
   mFile << "}" << std::endl;
 
-  mFile <<"void "<<mName<<"::bbUserCopyConstructor()"<<std::endl;
+  mFile <<"void "<<mName<<"::bbUserCopyConstructor(bbtk::BlackBox::Pointer)"
+       <<std::endl;
   mFile << "{"<<std::endl;
   //mFile<<"bbtkDebugMessage(\"Kernel\",9,\""<<mName<<::bbUserCopyConstructor()"<<std::endl);"<<std::endl;
   mFile << mUserCopyConstructor << std::endl;
index 1b11dcf7b355dd804d5e10dc9b26683aee2226f5..3ee7d62b05d0e98e685e87f7683b04fcbc9c382a 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbtkAtomicBlackBox.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/11/13 14:46:43 $
-  Version:   $Revision: 1.9 $
+  Date:      $Date: 2008/11/25 11:17:13 $
+  Version:   $Revision: 1.10 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -227,7 +227,7 @@ namespace bbtk
                 Data data, 
                 bool setModified )
   {
-    bbtkDebugMessageInc("Data",7,
+    bbtkDebugMessageInc("data",7,
             "AtomicBlackBox::bbSetInput(\""<<name<<"\",data) ["
             <<bbGetFullName()<<"]"
             <<std::endl);  
@@ -238,7 +238,7 @@ namespace bbtk
             bbSetModifiedStatus();
         }
     
-    bbtkDebugDecTab("Data",7);
+    bbtkDebugDecTab("data",7);
   }
   //=========================================================================
   
@@ -251,7 +251,7 @@ namespace bbtk
                     bool setModified
     )
   {
-    bbtkDebugMessageInc("Data",7,
+    bbtkDebugMessageInc("data",7,
             "AtomicBlackBox::bbBruteForceSetInputPointer(\""
             <<name<<"\",data) ["
             <<bbGetFullName()<<"]"
@@ -265,7 +265,7 @@ namespace bbtk
         bbSetModifiedStatus();
       }
     
-    bbtkDebugDecTab("Data",7);
+    bbtkDebugDecTab("data",7);
   }
   //=========================================================================
  
index fa311113456fe1bafff71dfe0ff41ebb6501d0f4..34d85078ccb7528fabc8e1ece6fdb693be19e22f 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbtkAtomicBlackBox.h,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:12 $
-  Version:   $Revision: 1.5 $
+  Date:      $Date: 2008/11/25 11:17:13 $
+  Version:   $Revision: 1.6 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -166,7 +166,7 @@ namespace bbtk
     /// User callback called in the box contructor
     virtual void bbUserConstructor() {}
     /// User callback called in the box copy constructor
-    virtual void bbUserCopyConstructor() {}
+    virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer) {}
     /// User callback called in the box destructor
     virtual void bbUserDestructor() {}
     //==================================================================    
index f480c6118a90fd7dbbb539edc1ea1d2b54108bfc..ecc56802713bc0f4f3f99c3fb7e9b65c61603980 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbtkAtomicBlackBoxGetSetFunctor.h,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:12 $
-  Version:   $Revision: 1.4 $
+  Date:      $Date: 2008/11/25 11:17:13 $
+  Version:   $Revision: 1.5 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -123,7 +123,7 @@ namespace bbtk
     AtomicBlackBoxTGetFunctor(GetMethodPointerType g) :
       mGetMethodPointer(g)
       {
-       bbtkDebugMessage("Data",9,"AtomicBlackBoxTGetFunctor<"<<
+       bbtkDebugMessage("data",9,"AtomicBlackBoxTGetFunctor<"<<
                         TypeName<UBB>()<<","<<
                         TypeName<T>()<<","<<
                         TypeName<TRETURN>()<<
@@ -133,7 +133,7 @@ namespace bbtk
     /// Concrete application of the Get method of object o
     Data Get(AtomicBlackBox* o) 
     {
-      bbtkDebugMessage("Data",9,"AtomicBlackBoxTGetFunctor<"<<
+      bbtkDebugMessage("data",9,"AtomicBlackBoxTGetFunctor<"<<
                       TypeName<UBB>()<<","<<
                       TypeName<T>()<<","<<
                       TypeName<TRETURN>()<<
@@ -170,7 +170,7 @@ namespace bbtk
     AtomicBlackBoxTSetFunctor(SetMethodPointerType s) :
       mSetMethodPointer(s) 
       {
-       bbtkDebugMessage("Data",9,"AtomicBlackBoxTSetFunctor<"<<
+       bbtkDebugMessage("data",9,"AtomicBlackBoxTSetFunctor<"<<
                        TypeName<UBB>()<<","<<
                        TypeName<T>()<<","<<
                        TypeName<TACCESS>()<<
@@ -180,7 +180,7 @@ namespace bbtk
     /// Concrete application of the Set method of object o
     void Set(AtomicBlackBox* o, const Data& d)
     { 
-      bbtkDebugMessage("Data",9,"AtomicBlackBoxTSetfunctor<"<<
+      bbtkDebugMessage("data",9,"AtomicBlackBoxTSetfunctor<"<<
                        TypeName<UBB>()<<","<<
                        TypeName<T>()<<","<<
                        TypeName<TACCESS>()<<
@@ -231,7 +231,7 @@ namespace bbtk
     AtomicBlackBoxTSetFunctor(SetMethodPointerType s) :
       mSetMethodPointer(s) 
     {
-      bbtkDebugMessage("Data",9,"AtomicBlackBoxTSetFunctor<"<<
+      bbtkDebugMessage("data",9,"AtomicBlackBoxTSetFunctor<"<<
                       TypeName<UBB>()<<","<<
                       TypeName<T*>()<<","<<
                       TypeName<TACCESS*>()<<
@@ -241,7 +241,7 @@ namespace bbtk
     /// Concrete application of the Set method of object o
     void Set(AtomicBlackBox* o, const Data& d)
     { 
-      bbtkDebugMessage("Data",9,"AtomicBlackBoxTSetfunctor<"<<
+      bbtkDebugMessage("data",9,"AtomicBlackBoxTSetfunctor<"<<
                       TypeName<UBB>()<<","<<
                       TypeName<T*>()<<","<<
                       TypeName<TACCESS*>()<<
@@ -260,7 +260,7 @@ namespace bbtk
  
     virtual void BruteForceSetPointer(AtomicBlackBox* o, void* p) 
     {  
-      bbtkDebugMessage("Data",9,"AtomicBlackBoxTSetFunctor<"
+      bbtkDebugMessage("data",9,"AtomicBlackBoxTSetFunctor<"
                       <<TypeName<UBB>()<<","
                       <<TypeName<T*>()<<","
                       <<TypeName<TACCESS*>()
index 8c026f2e1757f7d14b9b0e9cc043ba72f345d24b..69bcc7c5bbae88b923c4d0d4a2e9cc0b9fd23548 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbtkAtomicBlackBoxMacros.h,v $
   Language:  C++
-  Date:      $Date: 2008/11/13 14:46:43 $
-  Version:   $Revision: 1.12 $
+  Date:      $Date: 2008/11/25 11:17:13 $
+  Version:   $Revision: 1.13 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
     : PARENT(from,name,false)                                          \
   {                                                                    \
     BBTK_BEGIN_BLACK_BOX_COPY_CONSTRUCTOR(CLASS,from,allocate_connectors); \
-    CLASS::bbUserCopyConstructor();                                    \
+    CLASS::bbUserCopyConstructor(from.GetThisPointer<bbtk::BlackBox>()); \
     BBTK_END_BLACK_BOX_COPY_CONSTRUCTOR(CLASS,from);                   \
   }                                                                    \
   CLASS::~CLASS()                                                      \
     : PARENT(from,name,false)                                          \
   {                                                                    \
     BBTK_BEGIN_BLACK_BOX_COPY_CONSTRUCTOR(CLASS,from,allocate_connectors); \
-    CLASS<T>::bbUserCopyConstructor();                                 \
+    CLASS<T>::bbUserCopyConstructor(from.GetThisPointer<bbtk::BlackBox>()); \
     BBTK_END_BLACK_BOX_COPY_CONSTRUCTOR(CLASS,from);                   \
   }                                                                    \
   template <class T>                                                   \
     : PARENT(from,name,false)                                          \
   {                                                                    \
     BBTK_BEGIN_BLACK_BOX_COPY_CONSTRUCTOR(CLASS,from,allocate_connectors); \
-    CLASS<T1,T2>::bbUserCopyConstructor();                             \
+    CLASS<T1,T2>::bbUserCopyConstructor(from.GetThisPointer<bbtk::BlackBox>());        \
     BBTK_END_BLACK_BOX_COPY_CONSTRUCTOR(CLASS,from);                   \
   }                                                                    \
   template <class T1, class T2>                                                \
index 3b3955622d59b996fb88bcd0989b5b2923b99b4b..ddfc3ed9576598ad5b150716c67dbec7ccafe65e 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbtkBlackBox.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/11/13 14:46:43 $
-  Version:   $Revision: 1.28 $
+  Date:      $Date: 2008/11/25 11:17:13 $
+  Version:   $Revision: 1.29 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -343,7 +343,7 @@ namespace bbtk
   /// Copies the input / output values from another box
   void BlackBox::bbCopyIOValues(BlackBox& from)
   {
-    bbtkDebugMessageInc("Kernel",9,
+    bbtkDebugMessageInc("Kernel",1,
                        "BlackBox::bbCopyIOValues("
                        <<from.bbGetFullName()<<") ["
                        <<bbGetFullName()<<"]"<<std::endl);
@@ -355,6 +355,7 @@ namespace bbtk
       {                
        if (! i->second->GetCopyConstruct() ) continue;
        std::string input = i->second->GetName();
+       bbtkDebugMessage("Kernel",2,"* Copying input "<<input<<std::endl);
        this->bbSetInput(input, from.bbGetInput(input) );
       }                                                                        
     // copies the output values
@@ -365,6 +366,7 @@ namespace bbtk
       {                                                        
        if (! o->second->GetCopyConstruct() ) continue;
        std::string output = o->second->GetName();
+       bbtkDebugMessage("Kernel",2,"* Copying output "<<output<<std::endl);
        this->bbSetOutput(output, from.bbGetOutput(output) );
       }
 
index a5f2ce099e3fd2a2047c1ff4465b041797284812..01ee4712626af54419e49df5e12a8f8e631fbaa1 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbtkWxBlackBox.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/11/24 15:45:48 $
-  Version:   $Revision: 1.30 $
+  Date:      $Date: 2008/11/25 11:17:13 $
+  Version:   $Revision: 1.31 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -357,7 +357,7 @@ namespace bbtk
   //=========================================================================
 
   //=========================================================================
-  void WxBlackBox::bbUserCopyConstructor()
+  void WxBlackBox::bbUserCopyConstructor(bbtk::BlackBox::Pointer)
   {
     bbtkDebugMessage("Kernel",9,"WxBlackBox::bbUserCopyConstructor()"
                     <<std::endl);
index e8acc44ab0c7cb55b56128cea2a06b3cc715ddc9..e2857e0d47c57d0f87ce4d0b548272b77bbb138a 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbtkWxBlackBox.h,v $
   Language:  C++
-  Date:      $Date: 2008/11/24 15:45:48 $
-  Version:   $Revision: 1.20 $
+  Date:      $Date: 2008/11/25 11:17:13 $
+  Version:   $Revision: 1.21 $
 ========================================================================*/
 
 
@@ -136,7 +136,7 @@ namespace bbtk
     /// User callback called in the box contructor
     virtual void bbUserConstructor();
     /// User callback called in the box copy constructor
-    virtual void bbUserCopyConstructor();
+    virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
     /// User callback called in the box destructor
     virtual void bbUserDestructor();
     //==================================================================    
index 066f6028abab4fe98e89f4553d4b7f6fd4a817f3..eb26cab1f340a7aaf62e3b45984748f45aa43373 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbitkBinaryThresholdImageFilter.h,v $
   Language:  C++
-  Date:      $Date: 2008/11/12 12:47:03 $
-  Version:   $Revision: 1.9 $
+  Date:      $Date: 2008/11/25 11:17:15 $
+  Version:   $Revision: 1.10 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -58,7 +58,7 @@ namespace bbitk
     BBTK_ITK_DELETE();
 
     void bbUserConstructor() { Init(); }
-    void bbUserCopyConstructor() { Init(); }
+    void bbUserCopyConstructor(bbtk::BlackBox::Pointer) { Init(); }
     void Init();
 
   };
@@ -102,7 +102,7 @@ namespace bbitk
     inline void ProcessSwitch();
     template <class T> void Process();
     void bbUserConstructor() { Init(); }
-    void bbUserCopyConstructor() { Init(); }
+    void bbUserCopyConstructor(bbtk::BlackBox::Pointer) { Init(); }
     void Init();
   };
   
index 127e22954768f2f22746752f824837d15478c7f4..0dae92d7b8a9a0ca6e3d4e190f7a849b9eb945d3 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbitkResampleImageFilter.h,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:21 $
-  Version:   $Revision: 1.7 $
+  Date:      $Date: 2008/11/25 11:17:15 $
+  Version:   $Revision: 1.8 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -58,7 +58,7 @@ namespace bbitk
     inline void ProcessSwitch();
     template <class T> void Process();
     void bbUserConstructor() { Init(); }
-    void bbUserCopyConstructor() { Init(); }
+    void bbUserCopyConstructor(bbtk::BlackBox::Pointer) { Init(); }
     void Init();
     itk::Object* mOutput;
   };
index ac14914ac16b05e28f335702f2167fb14ae13e5f..e3a46313c24142846caca6d1ccea18810fabe9ae 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbitkvtkitkImage2vtkImageData.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/11/12 12:47:05 $
-  Version:   $Revision: 1.6 $
+  Date:      $Date: 2008/11/25 11:17:17 $
+  Version:   $Revision: 1.7 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -138,7 +138,7 @@ namespace bbitkvtk
     bbSetOutputOut(NULL);
     mConverter = 0;
   }
-  void itkImage2vtkImageData::bbUserCopyConstructor()
+  void itkImage2vtkImageData::bbUserCopyConstructor(bbtk::BlackBox::Pointer)
   {
     bbSetOutputOut(NULL);
     mConverter = 0;
index 476cddc8241fb0afac25704153c258e1095b5d29..8e52ec69e114be3d143a979e19e6f2a23d887c97 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbitkvtkitkImage2vtkImageData.h,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:24 $
-  Version:   $Revision: 1.7 $
+  Date:      $Date: 2008/11/25 11:17:18 $
+  Version:   $Revision: 1.8 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -60,7 +60,7 @@ namespace bbitkvtk
     BBTK_PROCESS(Convert);
     void Convert();
     void bbUserConstructor();
-    void bbUserCopyConstructor();
+    void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
     void bbUserDestructor();
   private:
     // Convert method template on type of the itk image 
index d8cde9dc038f0490ac9a9c58856290b6d26a77b5..a378afea06d396cfb407e3c5ad69e4fb226d4f80 100644 (file)
@@ -3,8 +3,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbitkvtkvtkImageData2itkImage.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/05/14 07:01:00 $
-  Version:   $Revision: 1.3 $
+  Date:      $Date: 2008/11/25 11:17:18 $
+  Version:   $Revision: 1.4 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -137,7 +137,7 @@ namespace bbitkvtk
     mConverter = 0;
   }
   
-  void vtkImageData2itkImage::bbUserCopyConstructor()
+  void vtkImageData2itkImage::bbUserCopyConstructor(bbtk::BlackBox::Pointer)
   {
     //    bbSetOutputOut(NULL);
     mConverter = 0;
index 1ee762bd9c7ab7d3336d2f59985688ed82a647e3..2af1182873f70f3be9d21387a1775fce20e050a7 100644 (file)
@@ -3,8 +3,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbitkvtkvtkImageData2itkImage.h,v $
   Language:  C++
-  Date:      $Date: 2008/07/23 12:02:15 $
-  Version:   $Revision: 1.5 $
+  Date:      $Date: 2008/11/25 11:17:18 $
+  Version:   $Revision: 1.6 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -48,7 +48,7 @@ namespace bbitkvtk
     BBTK_PROCESS(Convert);
     void Convert();
     void bbUserConstructor();
-    void bbUserCopyConstructor();
+    void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
     void bbUserDestructor();
 
   private:
index 69b504745dc246fceec5e2677d64470818dc9f7f..10e630fc6c66899443f58d3f14e7ff479ac6c372 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbstdASCII.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:26 $
-  Version:   $Revision: 1.5 $
+  Date:      $Date: 2008/11/25 11:17:20 $
+  Version:   $Revision: 1.6 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -88,7 +88,7 @@ namespace bbstd
     bbSetInputType(0);
   }
   
-  void ASCII::bbUserCopyConstructor()
+  void ASCII::bbUserCopyConstructor(bbtk::BlackBox::Pointer)
   {    
   }
   
index a76b0349500b20a1aa6b5b8570c5759353c185c6..cd28637f58210fc5afea4e34c8afbf62c02bcb0a 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbstdASCII.h,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:26 $
-  Version:   $Revision: 1.7 $
+  Date:      $Date: 2008/11/25 11:17:20 $
+  Version:   $Revision: 1.8 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -46,7 +46,7 @@ namespace bbstd
     /// User callback called in the box contructor
     virtual void bbUserConstructor();
     /// User callback called in the box copy constructor
-    virtual void bbUserCopyConstructor();
+    virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
     /// User callback called in the box destructor
     virtual void bbUserDestructor();
     //==================================================================
index 0f5e34b66c4ab462c9fb74165f0ba7d7908936c3..191fcfa426eca62c0f869e548e2d1f94a45431bb 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbvtkImagePlanes.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:30 $
-  Version:   $Revision: 1.9 $
+  Date:      $Date: 2008/11/25 11:17:23 $
+  Version:   $Revision: 1.10 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -77,7 +77,7 @@ namespace bbvtk
      bbSetInputWindowLevel (vect);
    }
    
-   void ImagePlanes::bbUserCopyConstructor() 
+   void ImagePlanes::bbUserCopyConstructor(bbtk::BlackBox::Pointer
    { 
      planeWidgetX = planeWidgetY = planeWidgetZ = 0;
    }
index c12a49c7079ba2e42777081e3939920ac0b0f088..3121529f9ac08027bf436dbd355869d13b475d68 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbvtkImagePlanes.h,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:30 $
-  Version:   $Revision: 1.6 $
+  Date:      $Date: 2008/11/25 11:17:23 $
+  Version:   $Revision: 1.7 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -85,7 +85,7 @@ namespace bbvtk
     
   protected:
     virtual void bbUserConstructor();
-    virtual void bbUserCopyConstructor();
+    virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
     virtual void bbUserDestructor();
     void Init();
   private:
index 6db46979d3377815d00da38eb6d1d1ae7725ff6b..3aa3a37c952c53945af51ea34ae9ac0072e6e2cf 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbvtkIsoSurfaceExtractor.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/11/21 12:25:42 $
-  Version:   $Revision: 1.9 $
+  Date:      $Date: 2008/11/25 11:17:23 $
+  Version:   $Revision: 1.10 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -55,9 +55,8 @@ namespace bbvtk
      colour.push_back(1.0);
      colour.push_back(0.5);
      bbSetInputColour(colour);
-        bbSetInputTransform(NULL);
    }
-   void IsoSurfaceExtractor::bbUserCopyConstructor() 
+   void IsoSurfaceExtractor::bbUserCopyConstructor(bbtk::BlackBox::Pointer from
    { 
      Init();
    }
@@ -76,6 +75,7 @@ namespace bbvtk
      bbSetInputIn(NULL);
      //     bbSetInputInVtkObject(NULL);
      bbSetInputRenderer(NULL);
+     bbSetInputTransform(NULL);
      bbSetInputIsovalue(400);
      bbSetInputOpacity(1);
         
@@ -94,8 +94,6 @@ namespace bbvtk
 
    void IsoSurfaceExtractor::DoProcess()
    {
-     //   bbGetInputIn()->Print(std::cout);
-     // Visualisation - result volume
      marchingcubes->SetInput( bbGetInputIn() );
      marchingcubes->SetValue(0,  bbGetInputIsovalue() );
      marchingcubes->Update();
@@ -106,19 +104,19 @@ namespace bbvtk
      
      
      vtkactor->GetProperty()->SetOpacity( bbGetInputOpacity() );
-       
-        if ( bbGetInputTransform()!=NULL )
-        {
-                vtkactor->SetUserTransform( bbGetInputTransform() );
-        }
+     
+     if ( bbGetInputTransform()!=NULL )
+       {
+        vtkactor->SetUserTransform( bbGetInputTransform() );
+       }
 
      bbSetOutputOut( vtkactor );
-     
+
      // Interface Update
      if ((firsttime==true) && (bbGetInputRenderer()!=NULL ))
      {
-               firsttime=false;
-           bbGetInputRenderer()->AddActor( vtkactor );
+       firsttime=false;
+       bbGetInputRenderer()->AddActor( vtkactor );
      }
    }
 } // EO namespace bbtk
index 805292767ff329703674dafc91ca36cac1b709cb..554ca8cc5cc1a7011596353d4637a4224f4bca1f 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbvtkIsoSurfaceExtractor.h,v $
   Language:  C++
-  Date:      $Date: 2008/11/20 17:41:48 $
-  Version:   $Revision: 1.10 $
+  Date:      $Date: 2008/11/25 11:17:23 $
+  Version:   $Revision: 1.11 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -90,7 +90,7 @@ namespace bbvtk
     
   protected:
     virtual void bbUserConstructor();
-    virtual void bbUserCopyConstructor();
+    virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
     virtual void bbUserDestructor();
     void Init();
   };
index c4a04b87fd53180391e47c9cbe4b11066734929f..a398952569dd1540f40619886e4926da3c9fc138 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbvtkMIPCreator.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:30 $
-  Version:   $Revision: 1.4 $
+  Date:      $Date: 2008/11/25 11:17:23 $
+  Version:   $Revision: 1.5 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -58,7 +58,7 @@ namespace bbvtk
      bbSetInputShift(0);
      bbSetInputScale(1.);
    }
-   void MIPCreator::bbUserCopyConstructor() 
+   void MIPCreator::bbUserCopyConstructor(bbtk::BlackBox::Pointer
    { 
      Init();
    }
index acf229a3cd4a230e674ee3b1b2ee1c08898448f7..6481ef862c89095475dde78a60d1e1fff740b570 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbvtkMIPCreator.h,v $
   Language:  C++
-  Date:      $Date: 2008/10/17 08:18:30 $
-  Version:   $Revision: 1.5 $
+  Date:      $Date: 2008/11/25 11:17:23 $
+  Version:   $Revision: 1.6 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -80,7 +80,7 @@ namespace bbvtk
     
   protected:
     virtual void bbUserConstructor();
-    virtual void bbUserCopyConstructor();
+    virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
     virtual void bbUserDestructor();
     void Init();
   private:
index 3a634ebaf891a63f751be9fd8df3191491b799d2..01b9019499783226c8d9f32c25cc346fbce099d0 100644 (file)
@@ -54,7 +54,7 @@ void VecImageGaussianSmooth::bbUserConstructor()
 
 }
 
-void VecImageGaussianSmooth::bbUserCopyConstructor()
+void VecImageGaussianSmooth::bbUserCopyConstructor(bbtk::BlackBox::Pointer)
 { 
 }
 
index 1acb573b323811a70cca56a051432a50b9e439ea..d5fc22608175cca18e14cb26f22f981a7291c546 100644 (file)
@@ -19,7 +19,7 @@ class /*BBTK_EXPORT*/ VecImageGaussianSmooth
 /// User callback called in the box contructor
 virtual void bbUserConstructor();
 /// User callback called in the box copy constructor
-virtual void bbUserCopyConstructor();
+virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
 /// User callback called in the box destructor
 virtual void bbUserDestructor();
 //==================================================================
index 4ba55a191ca3def1c45dca89a2d6fc1924eaa315..f4575b522ede64bb3daa152a9e85013aea1dcdf5 100644 (file)
@@ -126,7 +126,7 @@ void VecIsoSurfaceExtractor::bbUserConstructor()
         bbSetInputTransform(NULL);
 }
 
-void VecIsoSurfaceExtractor::bbUserCopyConstructor()
+void VecIsoSurfaceExtractor::bbUserCopyConstructor(bbtk::BlackBox::Pointer)
 {
        Init();
 }
index e0e4b84e5508c638c2c3883ed5f9051734577476..060eb1493bce22ddd631f182bbcc09689c3c2908 100644 (file)
@@ -24,7 +24,7 @@ class /*BBTK_EXPORT*/ VecIsoSurfaceExtractor
 /// User callback called in the box contructor
 virtual void bbUserConstructor();
 /// User callback called in the box copy constructor
-virtual void bbUserCopyConstructor();
+virtual void bbUserCopyConstructor(bbtk::BlackBox::Pointer);
 /// User callback called in the box destructor
 virtual void bbUserDestructor();
 //==================================================================
index 9328d6ae5405c86ce1d40c7fa8261d40448fc882..9a4cafd2bc5a913cc45d76f719222763db40a42c 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbwxColourSelectorButton.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/11/24 15:45:51 $
-  Version:   $Revision: 1.6 $
+  Date:      $Date: 2008/11/25 11:17:25 $
+  Version:   $Revision: 1.7 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -119,14 +119,22 @@ void wxColourPickerCtrlWidget::UpdateBox()
   void ColourSelectorButton::bbUserConstructor() 
   { 
     bbSetInputIn("1 1 1");
+    bbSetOutputOut("1 1 1");
+    bbSetOutputWidget(0);
   }
 
 
   void ColourSelectorButton::Process() 
   { 
-    bbtkDebugMessageInc("Process",9,"ColourSelectorButton::Process()"<<std::endl);
-      pickerWidget->UpdateBox();
-    bbtkDebugDecTab("Process",9);
+    wxColourPickerCtrlWidget* w = ( wxColourPickerCtrlWidget* )bbGetOutputWidget();
+    if (w) 
+      {
+       w->UpdateBox();
+      }
+    else 
+      {
+       bbSetOutputOut(bbGetInputIn());
+      }
   }
 
 
@@ -137,7 +145,6 @@ void wxColourPickerCtrlWidget::UpdateBox()
    */
   void ColourSelectorButton::CreateWidget(wxWindow* parent)
   {
-    bbtkDebugMessage("Process",9,"=> ColourSelectorButton::CreateWidget()"<<std::endl);
     
     float r,g,b;
     sscanf( bbGetInputIn().c_str(), "%f %f %f", &r, &g ,&b);
@@ -146,13 +153,11 @@ void wxColourPickerCtrlWidget::UpdateBox()
     cg = (unsigned char)(255.*g);
     cb = (unsigned char)(255.*b);
 
-    pickerWidget = new wxColourPickerCtrlWidget(this, //bbGetWxParent() , 
+    wxColourPickerCtrlWidget* w = new wxColourPickerCtrlWidget(this, //bbGetWxParent() , 
                                                                                                parent,
                                                                                                cr , cg , cb );    
     
-    bbtkDebugMessage("Process",9,"<= ColourSelectorButton::CreateWidget()"<<std::endl);
-
-    bbSetOutputWidget( pickerWidget );
+    bbSetOutputWidget( w );
   }
 
 
index c8deb653a65021913537900427758acdef764f53..aef50a25df702588980f645ca9c26ac4db8e04de 100644 (file)
@@ -2,8 +2,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbwxColourSelectorButton.h,v $
   Language:  C++
-  Date:      $Date: 2008/11/24 15:45:51 $
-  Version:   $Revision: 1.8 $
+  Date:      $Date: 2008/11/25 11:17:25 $
+  Version:   $Revision: 1.9 $
 =========================================================================*/
 
 /* ---------------------------------------------------------------------
@@ -99,9 +99,10 @@ private:
 
   protected:
     virtual void bbUserConstructor();
-
+    /*
   private:
      wxColourPickerCtrlWidget* pickerWidget;
+    */
   };
 
   //=================================================================
index 228e9a4f261988d228dfd2e70470c75fccf827bf..41e76ab2e2b0a92e3b479e84962af7fd683480aa 100644 (file)
@@ -3,8 +3,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbwxvtkViewer3D.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/11/24 15:45:54 $
-  Version:   $Revision: 1.10 $
+  Date:      $Date: 2008/11/25 11:17:28 $
+  Version:   $Revision: 1.11 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -147,12 +147,14 @@ void Viewer3DWidget::Refresh(bool eraseBackground , const wxRect* rect )
     bbSetInputStereo(false);
     bbSetOutputRenderer( NULL );
     bbSetOutputInteractor( NULL );
+    bbSetOutputWidget(NULL);
   }
 
 
   void Viewer3D::Process() 
   { 
-    ((Viewer3DWidget*)bbGetOutputWidget())->Update();
+    Viewer3DWidget* w = (Viewer3DWidget*)bbGetOutputWidget();
+    if (w) w->Update();
   }
   
 
@@ -225,7 +227,8 @@ void Viewer3DWidget::Refresh(bool eraseBackground , const wxRect* rect )
   // when window is shown
   void  Viewer3D::OnShowWidget()
   {
-    ((Viewer3DWidget*)bbGetOutputWidget())->Update();
+    Viewer3DWidget* w = (Viewer3DWidget*)bbGetOutputWidget();
+    if (w) w->Update();
   }