]> Creatis software - bbtk.git/blobdiff - kernel/doc/bbtkUsersGuide/bbtkUsersGuide.tex
*** empty log message ***
[bbtk.git] / kernel / doc / bbtkUsersGuide / bbtkUsersGuide.tex
index 06e156ebfb51a7349bdd1a607e280552a3db6599..906cc5412e1eaf10a22bd47fe2bb69faabc83dde 100644 (file)
@@ -3,65 +3,6 @@
 \input{config.tex}
 
 
-\def\todo{\scriptsize\fbox{\bf TODO !!}\normalsize}
-\def\x{\bm{x}}
-\def\BBTK{{\xspace}The {\bf Black Box Toolkit} }
-\def\bbtk{{\xspace}$\texttt{bbtk}$ }
-\def\bbi{{\xspace}$\texttt{bbi}$ }
-\def\bbStudio{{\xspace}$\texttt{bbStudio}$ }
-\def\bbfy{{\xspace}$\texttt{bbfy}$ }
-\def\bbdoc{{\xspace}$\texttt{bbdoc}$ }
-\def\bbCreatePackage{{\xspace}$\texttt{bbCreatePackage}$ }
-
-\def\bb{{\xspace}$\texttt{bb}$ }
-%\def\bbp{{\xspace}$\texttt{bbp}$\xspace}
-
-\def\cmake{{\xspace}$\texttt{cmake}$ }
-
-\def\C{{\xspace}$\texttt{C}$ }
-\def\CPP{{\xspace}$\texttt{C++}$ }
-
-\def\xml{{\xspace}$\texttt{xml}$ }
-
-\def\itk{{\xspace}$\texttt{itk}$ }
-\def\vtk{{\xspace}$\texttt{vtk}$ }
-\def\gdcm{{\xspace}$\texttt{gdcm}$ }
-\def\gsmis{{\xspace}$\texttt{gsmis}$ }
-\def\wx{{\xspace}$\texttt{wxWidgets}$ }
-
-\def\lin{{\xspace}\textit{Linux} }
-\def\win{{\xspace}\textit{Windows} }
-
-% the same macros with no space at the end
-
-\def\BBTKns{{\xspace}The {\bf Black Box Toolkit}}
-\def\bbtkns{{\xspace}$\texttt{bbtk}$}
-\def\bbins{{\xspace}$\texttt{bbi}$}
-\def\bbfyns{{\xspace}$\texttt{bbfy}$}
-\def\bbdocns{{\xspace}$\texttt{bbdoc}$}
-\def\bbCreatePackagens{{\xspace}$\texttt{bbCreatePackage}$}
-
-\def\bbns{{\xspace}$\texttt{bb}$}
-%\def\bbp{{\xspace}$\texttt{bbp}$\xspace}
-
-\def\cmakens{{\xspace}$\texttt{cmake}$}
-
-\def\Cns{{\xspace}$\texttt{C}$}
-\def\CPPns{{\xspace}$\texttt{C++}$}
-
-\def\xmlns{{\xspace}$\texttt{xml}$}
-
-\def\itkns{{\xspace}$\texttt{itk}$}
-\def\vtkns{{\xspace}$\texttt{vtk}$}
-\def\gdcmns{{\xspace}$\texttt{gdcm}$}
-\def\gsmisns{{\xspace}$\texttt{gsmis}$}
-\def\wxns{{\xspace}$\texttt{wxWidgets}$}
-
-\def\linns{{\xspace}\textit{Linux}}
-\def\winns{{\xspace}\textit{Windows}}
-
-
-
 
 \begin{document}
 \begin{center}
 {\Huge User's Guide}
 \vspace{1cm}
 
-\bbtk version 1.0
+\bbtk version \bbtkVersion
 \vspace{0.5cm}
 
 
-Last modified on : September 16, 2008 \\
+Last modified on : October 9, 2008 \\
 Generated on : \today 
 \vspace{0.5cm}
 
@@ -219,7 +160,6 @@ have been written by different persons, using different libraries, etc.
       \item {\bf\emph{vtk}} : the basic images and surfaces processing and vizualization package, based on the \vtk library.
       \item {\bf\emph{wxvtk}} : widget boxes based on the \vtk library (2D and 3D vizualization and
       interaction).
-      \item {\bf\emph{itkvtk}} : special boxes (adaptors) to convert \itk structures into \vtk structures and conversally.
       %\item {\bf\emph{creaImageIO}} : Provides hight level widgets to read images, including DICOM.
       \item {\bf\emph{toolsbbtk}} : Tools for bbtk administration and package development..      
     \end{itemize}
@@ -250,6 +190,7 @@ have been written by different persons, using different libraries, etc.
          \end{itemize}
       \item A full {\bf\emph{documentation}} printable (pdf), browsable (html), queryable thru keywords.         
 \end{itemize}
+
 The general architecture of \BBTK 
 is shown in figure \ref{bb-architecture}.
 
@@ -321,7 +262,8 @@ Let's have a look at the resized window :
 \end{center}
 \end{figure}
 
-You can see four parts : \texttt{Files}, \texttt{Messages}, \texttt{Command}, \texttt{Help}.\\
+You can see four parts : \texttt{Files}, \texttt{Messages},
+ \texttt{Command}, \texttt{Help}.\\
 
 The stuff is written using the Advanced User Interface library of wxWidgets,
 whose 'docking manager' allows windows and toolbars to be floated/docked 
@@ -361,7 +303,8 @@ lower toolbar (see figure : \ref{lowertoolbar})
 
 Two kinds of messages will be output here:\\
 System messages : produced by the kernel, in case of a user mistyping, or an execution error\\
-Script messages : produced by the \bbtk equivalent of \texttt{printf} or \texttt{std::cout} in user programs
+Script messages : produced by the \bbtk equivalent of \texttt{printf} 
+or \texttt{std::cout} in user programs
 
 \subsubsection{'Command' part}
 \label{bbi-CommandPart}
@@ -395,10 +338,12 @@ All the entries of the starting page are self-explanatory :
    \end{itemize}
         
    \item {\bf\emph{Boxes}} : Box retrieving on various criterions :
-
-        \texttt{By name}} (Alphabetical list), 
-        \texttt{{By package}}, 
-        \texttt{{By category}}.\\ 
+   \begin{itemize} 
+    \item {\bf\emph{ \texttt{By name}}} (Alphabetical list), 
+    \item {\bf\emph{    \texttt{By package}}}, 
+     \item {\bf\emph{   \texttt{By category}}}.
+   \end{itemize} 
+   
         A special hidden Box category, called \texttt{{Adaptors}} exists. \\ 
        They are used internaly to perform type conversions. Thought there are not end user intended, an aware user may query them.     
 
@@ -530,7 +475,7 @@ connect slider.BoxChange text.BoxExecute
 connect slider.Out       text.In
 \end{verbatim}
 We tell  \emph{slider} to inform \emph{text} every time it's modified.\\
-We tell  \emph{slider} to pass its output value (\texttt{Out} to \emph{text}  input value (\testtt{In})
+We tell  \emph{slider} to pass its output value (\texttt{Out} to \emph{text}  input value (\texttt{In})
 \begin{verbatim}
 exec layout
 \end{verbatim}
@@ -570,24 +515,12 @@ Both graphical pipe line (\emph{slider} and \emph{text} are embedded into \emph{
 \subsection{Online Help}
 % ==============================================
 
-TODO
+Various levels or help are suplied by \bbStudions.
 
 % ==========================================
-\subsubsection{Guides}
-% ==========================================
-TODO
-% ==========================================
-\subsubsection{Boxes Help}
+\subsubsection{Command line help}
 % ==========================================
-TODO : indexation, categories, etc
-% ==========================================
-\subsection{Creating and executing black boxes}
-% ==========================================
-TODO
-% ==============================================
-\subsection{The Menu}
-% ==============================================
-TODO
+
 
 The 'working' area (the left one, as opposed to the 'help' area, on the right side) is composed of : 
 one single line zone (Command), at the bottom in which you can enter your commands and 
@@ -731,30 +664,6 @@ Then if you type :
 
 you get something like :
 
-% std
-%   ASCII                  
-%   Add                    
-%   ConcatStrings          
-%   Configuration          
-%   Div                    
-%   ExecBbiCommand         
-%   ExecSystemCommand      
-%   GetVectorCharElement   
-%      ... 
-%   GetVectorUShortElement 
-%   MagicBox               
-%   MakeFileName           
-%   Mul                    
-%   MultipleInputs         
-%   PrependDataPath        
-%   PrependPackageDataPath 
-%   StringRelay            
-%   StringSelect           
-% user
-% 
-%   workspace
-
-
 \begin{verbatim}
 
  std
@@ -788,7 +697,7 @@ If you type :
 
 You'll get a text help, in the 'Message' part :
 \begin{verbatim}
-Black Box <std::Add>
+Black Box <std::Add>S
   Adds its inputs
   By : laurent.guigues@creatis.insa-lyon.fr
   Categories : atomic box;math;
@@ -800,10 +709,106 @@ Black Box <std::Add>
      'In1'            <Double>     []       : First number to add
      'In2'            <Double>     []       : Second number to add
   * Outputs : 
-     'BoxChange'      <bbtk::Void> [signal] : Signals modifications of the box
+     'BoxChange'      <bbtk::VoidS> [signal] : Signals modifications of the box
      'Out'            <Double>     []       : Result
 \end{verbatim}
 
+More information about what is a 'box' will be given in the 'Scriptting' part of this manual.
+
+% ==========================================
+\subsubsection{Guides}
+% ==========================================
+
+An html version of all the guides is browsable in the \texttt{Help} part of \bbStudions.
+ \begin{itemize}      
+     \item {\bf\emph{User's Guide}} : Step to step How-to for user who wants to create his own
+     application, just using already existing boxes.
+     \item {\bf\emph{Package Developper's Guide}} : Step to step How-to for programmer who wants to create his own
+     black boxes/packages.
+     \item {\bf\emph{Developper's Guide}} : For bbtk kernel developpers only. (This one is probabely not very much
+     up-to-date, since we spend more time in developping than writing documentation that's not of user concern).
+     \item {\bf\emph{Reference Manual}} : Contains a exaustive description of all the features for all the commands.
+     \item {\bf\emph{Booklet}} : Vade mecum.     
+     \item {\bf\emph{Doxygen Documentation}} : Doxygen source browser.\\ Automatically generated from source file
+     headers. Should concern only the kernel developpers (i.e. : us).
+   \end{itemize}
+        
+
+   
+% ==========================================
+\subsubsection{Boxes Help}
+% ==========================================
+ Box retrieving on various criteria :
+   \begin{itemize} 
+    \item {\bf\emph{Alphabetical list}} \\ This is the 'zero-level' of retrieving.
+    \item {\bf\emph{List by package}} \\ Several packages are supplied with bbtk :
+    \begin{itemize}
+      \item {\bf\emph{std}} : the 'standard' package including basic useful boxes.
+      \item {\bf\emph{wx}} : basic graphical interface elements (widgets : sliders, buttons, etc. based on the \texttt{wxWidgets} library).  
+      \item {\bf\emph{itk}} : the basic image processing package, based on the \itk library.
+      \item {\bf\emph{vtk}} : the basic images and surfaces processing and vizualization package, based on the \vtk library.
+      \item {\bf\emph{wxvtk}} : widget boxes based on the \vtk library (2D and 3D vizualization and
+      interaction).
+      %\item {\bf\emph{creaImageIO}} : Provides hight level widgets to read images, including DICOM.
+      \item {\bf\emph{toolsbbtk}} : Tools for bbtk administration and package development, such as :
+         \begin{itemize}
+        \item{GUICreateBlackBox} For creating the XML or C++ code for a new black box 
+        \item{GUICreatePackage} For creating a new bbtk package file structure on disk (Graphical user interface for the shell script bbCreatePackage)
+        \item{MakePackageDoc} For creating the html documentation of a package. The doc is generated at the 'canonical' location. Works both for a build tree or an installed toolkit.  
+         \end{itemize}              
+    \end{itemize}
+    \item {\bf\emph{List by category}}.
+    
+    
+    A given box may belong to more than one \texttt{category}.\\
+    You have to consider categories like keywords to index black boxes.\\
+    Some of them are mutually exclusive.
+    A black box may be :
+    \begin {itemize}
+       \item{atomic box / complex box}\\
+       Whether it's written is C++ or it's an assembly of several black boxes (atomic or complex).\\
+       Any box is either atomic ou complex.
+       \item{example / demo / application}\\
+           Theese ones are always complex black boxes. 
+          \begin {itemize}
+             \item{example}\\
+            It's just a (simple) example on how to use a given feature.
+             \item{demo}\\
+            It can be a 'good looking' (a.k.a 'sexy') example on some sophisticated work.       
+             \item{application}\\
+            It's a Final application, end user intended (e.g. Subscale a huge volume, Crop a DICOM image, etc)  
+          \end {itemize}
+        \item{widget}\\
+        Piece of graphical interface (based on \texttt{wxWidgets})
+        \item{Dicom}\\
+        Dicom medical image related box.
+        \item{viewer}\\
+        \item{read/write}
+        \item{mesh}
+        \item{3D Object creator}
+        \item{math}
+        \item{misc}              
+    \end {itemize}
+  \end {itemize}
+
+% ==============================================
+\subsection{The Menu}
+% ==============================================
+TODO
+
+
+% ==========================================
+\section{bbs scripting}
+% ==========================================
+
+% ==========================================
+\subsection{Using an already existing}
+% ==========================================
+
+% ==========================================
+\subsection{Creating and executing black boxes}
+% ==========================================
+
 You'll get as well the same information in the 'Help' Part, in html format (see figure : \ref{HelpAdd}) :
 
 \begin{figure}[!ht]
@@ -915,7 +920,7 @@ Box processing is needed if :
 \texttt{'Always'}, which forces box reprocessing. 
 \end{itemize}
 
-Note that all boxes have an input named \texttt{'BoxProcessMode'}.\\ 
+Note that all boxes have an input named \texttt{'BoxProcessMode'}.
 
 Another way to process the box \texttt{a} is to issue the command :
 \begin{verbatim}
@@ -927,7 +932,7 @@ box itself displays something in its processing).
 It just processes the box if needed. 
 This command is used to execute boxes that do not have any output,  
 such as boxes that write something to a file or, display a 
-graphical interface, and so on. \\
+graphical interface, and so on. 
 
 %To exit \bbi, type :
 %\begin{verbatim}
@@ -1881,11 +1886,11 @@ cd buildBBTK
 ccmake ../bbtk
 \end{verbatim}
 
-Don't forget to switch ON the flag \textttBBTK\_COMPILE\_DEBUG\_MESSAGE \\
+Don't forget to switch ON the flag \texttt{BBTK\_COMPILE\_DEBUG\_MESSAGE} \\
 (see figure : \ref{bb-ccmake})
 
 \begin{figure}[!ht]
-\caption{\label{bb-ccmake}\Running ccmake}
+\caption{\label{bb-ccmake}Running ccmake}
 \begin{center}
 \includegraphics[width=0.6\textwidth]{ccmake.png}
 \end{center}
@@ -1901,7 +1906,7 @@ make
 For some strange reasons (?!?), you may be warned that an error occured while documentation generation.\\
 Take it easy, \texttt{make} again!\\
 
-The dynamic libraries (\texttt{.dll} or \texttt{.so} and the executable programs will be created in the \testtt{bin}
+The dynamic libraries (\texttt{.dll} or \texttt{.so} and the executable programs will be created in the \texttt{bin}
 directory of the built tree.
 
 \item choose to install or not your own version.
@@ -2160,7 +2165,9 @@ The box \texttt{box} must already have been created in the complex box and of co
 \newpage
 
 % ==========================================
-\vspace{0.5cm}\hrule \\
+%\vspace{0.5cm}\hrule \\
+
+
 \section{The Package Browser}
 \label{Package_Browser}
 % ==========================================
@@ -2206,7 +2213,8 @@ You can get the whole description of a given box or application clicking on its
 
 
 % ==========================================
-\vspace{0.5cm}\hrule \\
+%\vspace{0.5cm}\hrule \\
+
 \section{Using third party Package}
 \label{Third_Party_Package}
 % ==========================================
@@ -2253,7 +2261,7 @@ want to use,
 If you want (and sure you will) to be able to use the Help tools as well on the features provided by this package, you must use the
 option \texttt{Generate index}  in the menu \texttt{Tools} of the \texttt{Files} part toolbar.  
 % ==========================================
-\vspace{0.5cm}\hrule \\
+%\vspace{0.5cm}\hrule \\
 \section{Using black boxes in \CPP programs}
 \label{cpp}
 % ==========================================