]> Creatis software - bbtk.git/commitdiff
cosmetics + change ASCII imput name type->Type
authorjean-pierre roux <jean-pierre.roux@creatis.insa-lyon.fr>
Thu, 26 Jun 2008 07:55:12 +0000 (07:55 +0000)
committerjean-pierre roux <jean-pierre.roux@creatis.insa-lyon.fr>
Thu, 26 Jun 2008 07:55:12 +0000 (07:55 +0000)
packages/itk/src/bbitkImage.cxx
packages/itk/src/bbitkImageSeriesReader.cxx
packages/itk/src/bbitkImageSeriesReader.h
packages/std/bbs/appli/exampleAscii.bbs
packages/std/src/bbstdASCII.cxx
packages/std/src/bbstdASCII.h
packages/toolsbbtk/bbs/appli/GUICreatePackage.bbs
packages/wx/bbs/boxes/bbGUIdouble.bbs
packages/wxvtk/bbs/appli/ExampleSimpleSlicer.bbs
packages/wxvtk/bbs/boxes/bbBasicImageApplication.bbs

index 99417f7d425177cb841ef2cc2333e4361bf7df78..17027afb4c91c3745ce4aceb7df4a5b67ae20d97 100644 (file)
@@ -4,6 +4,7 @@
 #include "bbstdRelay.h"
 #include "bbitkPackage.h"
 
+
 namespace bbstd
 {
   
@@ -15,7 +16,9 @@ namespace bbstd
 using namespace bbstd;
 namespace bbitk
 {
+
   BBTK_ADD_TEMPLATE_BLACK_BOX_TO_PACKAGE(itk,Relay,anyImagePointer);
+
 } // namespace bbitk
 
 #endif
index 73f9ccb9bf1bafc543fe89ba33b8e5c4b9973d98..d1f32dd40b1e5f606ee314c77ef12c3bc37e27ed 100644 (file)
@@ -3,8 +3,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbitkImageSeriesReader.cxx,v $
   Language:  C++
-  Date:      $Date: 2008/05/16 14:03:19 $
-  Version:   $Revision: 1.4 $
+  Date:      $Date: 2008/06/26 07:55:12 $
+  Version:   $Revision: 1.5 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -31,9 +31,6 @@ namespace bbitk
   
   BBTK_ADD_BLACK_BOX_TO_PACKAGE(itk,ImageSeriesReader);
 
-
-
-
   void ImageSeriesReader::Read()
   {
     const std::vector<std::string>& filenames = bbGetInputFileNames();
@@ -72,8 +69,6 @@ namespace bbitk
   
   }
 
-
-
   /** 
       Template Processing 
   */
@@ -84,8 +79,6 @@ namespace bbitk
                        <<bbtk::TypeName<T>()
                        <<">::Read()"<<std::endl);
 
-
-
     typedef T itkImageType;
     typedef itk::ImageSeriesReader< itkImageType > itkReaderType;
 
index 0b4797a43257c915dabbef64e5470e5bda47d7ce..0564d568e6abb072d17a4dc08fc204cbc925e024 100644 (file)
@@ -3,8 +3,8 @@
   Program:   bbtk
   Module:    $RCSfile: bbitkImageSeriesReader.h,v $
   Language:  C++
-  Date:      $Date: 2008/04/18 12:59:50 $
-  Version:   $Revision: 1.5 $
+  Date:      $Date: 2008/06/26 07:55:12 $
+  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
@@ -65,6 +65,7 @@ namespace bbitk
   BBTK_INPUT(ImageSeriesReader,FileNames,
             "vector of file names with complete paths",vectorofstring,"file names list");
   BBTK_OUTPUT(ImageSeriesReader,Out,"Output itk::image<T,D> with type T and dimension D determined by the content of the files",anyImagePointer,"");
+  
   BBTK_END_DESCRIBE_BLACK_BOX(ImageSeriesReader);
   //=================================================================
   
index f17bd946effad27fe2f0c9a22f7812fdd309aa4d..a4cb34d0fef635e68cbb9811af6342277901a33f 100644 (file)
@@ -8,11 +8,11 @@ load wx
 new ASCII asciiA
   set asciiA.In "72 105 33"
 // --> default is 0
-//  set asciiB.type 0  
+//  set asciiB.Type 0  
 
 new ASCII asciiB
   set asciiB.In "SOS"
-  set asciiB.type 1
+  set asciiB.Type 1
 
 print $asciiA.Out$
 print $asciiB.Out$
index 55be1887d73b63bfdb3e7b962de6385524414fdf..c8255290a9032e8407eddfe580ea7298d6f2cba6 100644 (file)
@@ -12,7 +12,7 @@ namespace bbstd
     std::string result("");
     if (bbGetInputIn()!=""){
       
-      if (bbGetInputtype()==0){
+      if (bbGetInputType()==0){
        std::string commandstr(bbGetInputIn());
        bool ok=true;
        int pos1=0,pos2;
@@ -34,9 +34,9 @@ namespace bbstd
            pos1=pos2+1;
            pos2 = commandstr.find(" ",pos2+1);
          } // while
-      } // if type 0
+      } // if Type 0
       
-      if (bbGetInputtype()==1){
+      if (bbGetInputType()==1){
        int i,size=bbGetInputIn().size();
        for (i=0;i<size;i++){
          asciiValue = (int)bbGetInputIn()[i];
@@ -46,7 +46,7 @@ namespace bbstd
            result +=" ";
          } // i!=size-1
        } // for
-      } // type 1
+      } // Type 1
     }
     bbSetOutputOut( result );  
   }
@@ -54,7 +54,7 @@ namespace bbstd
   void ASCII::bbUserConstructor()
   {
     bbSetInputIn("");
-    bbSetInputtype(0);
+    bbSetInputType(0);
   }
   
   void ASCII::bbUserCopyConstructor()
index 4ed04052e49acb92a911e9982ef1e09a921cbf43..7365d4391d74cf2c55849d777ba61e3f40b4f18e 100644 (file)
@@ -20,7 +20,7 @@ namespace bbstd
     virtual void bbUserDestructor();
     //==================================================================
     BBTK_DECLARE_INPUT(In,std::string);
-    BBTK_DECLARE_INPUT(type,int);
+    BBTK_DECLARE_INPUT(Type,int);
     BBTK_DECLARE_OUTPUT(Out,std::string);
     BBTK_PROCESS(Process);
     void Process();
@@ -32,9 +32,9 @@ namespace bbstd
 
   BBTK_DESCRIPTION("ascii codes sequence to string - string to ascii codes sequence");
   BBTK_CATEGORY("misc");
-  BBTK_INPUT(ASCII,In,"Input Ascii code or Ascii character",std::string,"");
-  BBTK_INPUT(ASCII,type,"type (default 0) 0=Ascii codes to string, 1=String to ascii codes",int,"");
-  BBTK_OUTPUT(ASCII,Out,"Ascii codes sequence or characters sequence",std::string,"");
+  BBTK_INPUT(ASCII,In,   "Ascii code or Ascii character",                                               std::string,"");
+  BBTK_INPUT(ASCII,Type, "Conversion type (default 0) 0=Ascii codes to string, 1=String to ascii codes",int,"");
+  BBTK_OUTPUT(ASCII,Out, "Ascii codes sequence or characters sequence",                                 std::string,"");
   BBTK_END_DESCRIBE_BLACK_BOX(ASCII);
 
 }
index 1a57bc96f5e886dc6050246a2cfb8dd7c9345b2b..896fe064f2e56a209b04724d9ec4da436b06611b 100644 (file)
@@ -100,19 +100,19 @@ new ConcatStrings concatStrCommand
     set concatStrCommand.In1 " "
     connect dquote.Out                 concatStrCommand.In2
     connect conf.BinPath               concatStrCommand.In3
-    connect conf.FileSeparator concatStrCommand.In4
-    set                                                concatStrCommand.In5  "bbCreatePackage"
+    connect conf.FileSeparator         concatStrCommand.In4
+    set                                        concatStrCommand.In5  "bbCreatePackage"
     connect dquote.Out                 concatStrCommand.In6
-    set                                                concatStrCommand.In7  " "
+    set                                        concatStrCommand.In7  " "
 
 new ConcatStrings concatStr
-    connect dquote.Out                         concatStr.In1
-    connect  concatStrCommand.Out concatStr.In2
-    connect dirStr.Out                         concatStr.In3
+    connect dquote.Out                 concatStr.In1
+    connect  concatStrCommand.Out      concatStr.In2
+    connect dirStr.Out                 concatStr.In3
     connect nameStr.Out                        concatStr.In4 
-    connect authorStr.Out                      concatStr.In5 
+    connect authorStr.Out              concatStr.In5 
     connect descriptionStr.Out         concatStr.In6
-    connect dquote.Out                         concatStr.In7
+    connect dquote.Out                 concatStr.In7
 
 
 new ExecSystemCommand command
index ce8ea56b3bbc7e9307edd347c153340cc4e221f1..cef23f403b9ff70e4e5e27cfc52d759655b6f441 100644 (file)
@@ -2,6 +2,14 @@ load std
 load wx
 define GUIdouble wx
   kind DEFAULT_GUI
+  new InputText text
+  input In text.In "Initial value"
+  input Label text.Title "Label"
+  output Out text.Out "Current value"
+  output Widget text.Widget "Widget"
+  output BoxChange text.BoxChange "BoxChange"
+/*
+//  IT IS A BAD IDEA TO USE A SLIDER : HOW TO SET THE RANGE AUTOMATICALLY ?
   new Slider slider
   set slider.Label true
 #  set slider.ReactiveOnTrack true
@@ -18,4 +26,5 @@ define GUIdouble wx
   output Out div.Out "Current position"
   output Widget slider.Widget "Widget"
   output BoxChange slider.BoxChange "BoxChange"
+*/
 endefine
index 2fe619a64f1eab0f5fa1977ef8976bb37e1648d8..f905689603fdabc312fdf1a08802435bacbb166a 100644 (file)
@@ -5,6 +5,7 @@ category "example"
 include vtk/boxes/bbLoadHola
 include wxvtk/boxes/bbSimpleSlicer
 
+
 new LoadHola image
 new SimpleSlicer viewer
 connect image.Out viewer.In
index 56dd628664d35f2e2173d032028ec0277644c644..8525fd6ad07f50d169706a026031afde2fcc2080 100644 (file)
@@ -9,7 +9,7 @@ load vtk
 define BasicImageApplication
 
 ##
-   description "Interface of a 'standard' image application. Displays two images : before/after processing; Offers buttons : open/parameters/run/save/quit. See <a href='../demo/index.html#DemoBasicImageApplication'>DemoBasicImageApplication.bbs</a>. Screenshot : <center><img src='../demo/DemoBasicImageApplication1.png' width=400></center>."
+  description "Interface of a 'standard' image application. Displays two images : before/after processing; Offers buttons : open/parameters/run/save/quit. See <a href='../demo/index.html#DemoBasicImageApplication'>DemoBasicImageApplication.bbs</a>. Screenshot : <center><img src='../demo/DemoBasicImageApplication1.png' width=400></center>."
   author "laurent.guigues@creatis.insa-lyon.fr"
   category "widget"
 ##