1 % ==========================================
2 \documentclass[11pt,final,a4paper]{article}
6 \def\todo{\scriptsize\fbox{\bf TODO !!}\normalsize}
8 \def\BBTK{{\xspace}The {\bf Reference Manual} }
9 \def\bbtk{{\xspace}$\texttt{bbtk}$ }
10 \def\bbi{{\xspace}$\texttt{bbi}$ }
11 \def\bbStudio{{\xspace}$\texttt{bbStudio}$ }
12 \def\bbfy{{\xspace}$\texttt{bbfy}$ }
13 \def\bbdoc{{\xspace}$\texttt{bbdoc}$ }
14 \def\bbCreatePackage{{\xspace}$\texttt{bbCreatePackage}$ }
16 \def\bb{{\xspace}$\texttt{bb}$ }
17 %\def\bbp{{\xspace}$\texttt{bbp}$\xspace}
19 \def\cmake{{\xspace}$\texttt{cmake}$ }
21 \def\C{{\xspace}$\texttt{C}$ }
22 \def\CPP{{\xspace}$\texttt{C++}$ }
24 \def\xml{{\xspace}$\texttt{xml}$ }
26 \def\itk{{\xspace}$\texttt{itk}$ }
27 \def\vtk{{\xspace}$\texttt{vtk}$ }
28 \def\gdcm{{\xspace}$\texttt{gdcm}$ }
29 \def\gsmis{{\xspace}$\texttt{gsmis}$ }
30 \def\wx{{\xspace}$\texttt{wxWidgets}$ }
32 \def\lin{{\xspace}\textit{Linux} }
33 \def\win{{\xspace}\textit{Windows} }
35 % the same macros with no space at the end
37 \def\BBTKns{{\xspace}The {\bf Black Box Toolkit}}
38 \def\bbtkns{{\xspace}$\texttt{bbtk}$}
39 \def\bbins{{\xspace}$\texttt{bbi}$}
40 \def\bbfyns{{\xspace}$\texttt{bbfy}$}
41 \def\bbdocns{{\xspace}$\texttt{bbdoc}$}
42 \def\bbCreatePackagens{{\xspace}$\texttt{bbCreatePackage}$}
44 \def\bbns{{\xspace}$\texttt{bb}$}
45 %\def\bbp{{\xspace}$\texttt{bbp}$\xspace}
47 \def\cmakens{{\xspace}$\texttt{cmake}$}
49 \def\Cns{{\xspace}$\texttt{C}$}
50 \def\CPPns{{\xspace}$\texttt{C++}$}
52 \def\xmlns{{\xspace}$\texttt{xml}$}
54 \def\itkns{{\xspace}$\texttt{itk}$}
55 \def\vtkns{{\xspace}$\texttt{vtk}$}
56 \def\gdcmns{{\xspace}$\texttt{gdcm}$}
57 \def\gsmisns{{\xspace}$\texttt{gsmis}$}
58 \def\wxns{{\xspace}$\texttt{wxWidgets}$}
60 \def\linns{{\xspace}\textit{Linux}}
61 \def\winns{{\xspace}\textit{Windows}}
72 {\Huge Reference Manual}
79 Last modified on : September 20, 2008 \\
86 % ==========================================
88 % ==========================================
96 % ==========================================
98 % ==========================================
100 % ==========================================
105 ---> Should be moved in a 'Reference Manual' ?\\
106 ---> Any suggestion welcome!
113 \caption{\label{kinds} \texttt{Black Box} kinds}
115 \begin{tabular}{|ll|}
117 \texttt{Kind name} & : Meaning \\ \hline \\ \hline
118 \texttt{ADAPTOR} & : Adaptor Box \\ \hline
119 \texttt{DEFAULT\_ADAPTOR} & : \\ \hline
120 \texttt{WIDGET\_ADAPTOR} & : \\ \hline
121 \texttt{DEFAULT\_WIDGET\_ADAPTOR} & : \\ \hline
122 \texttt{GUI} & : \\ \hline
123 \texttt{DEFAULT\_GUI} & : \\ \hline
124 \texttt{ALL} & : If kind='ALL' then sets the level for all kinds \\ \hline
131 \bf\emph{Boxes} : Box retrieving on various criterions :
133 \item {\bf\emph{By name}} (Alphabetical list)
134 \item {\bf\emph{By package}} (see table : \ref{bbi-list_of_packages})
135 \item {\bf\emph{By category}} (see table : \ref{categories})
136 \item {\bf\emph{Adaptors}} Used internaly to perform type conversions (not end user intended)
141 % ==========================================
143 \caption{\label{bbi-list_of_packages} List of bbtk supplied packages.}
145 \begin{tabular}{|lp{10cm}|}
147 Package & What it's used for \\ \hline
148 \texttt{std} & : the 'standard' package including basic useful boxes \\ \hline
149 \texttt{wx} & : basic graphical interface elements (widgets : sliders, buttons, etc.) based on the \texttt{wxWidgets} library \\ \hline
150 \itk & : the basic image processing package, based on the \itk library. (without description)\\ \hline
151 \vtk & : prints help on the package \texttt{package-name} and its boxes (with brief description). The package must have been previously loaded\\ \hline
152 \texttt{wxvtk} & : widget boxes based on the \vtk library.\\ \hline
153 \texttt{itkvtk} & : adaptors to convert \itk structures into \vtk structures and conversally.\\ \hline
154 %\texttt{creaImageIO} & : provides high level widgets to read images including DICOM.\\ \hline
155 \texttt{toolsbbtk} & : Tools for bbtk administration and package development.\\ \hline
159 % ==========================================
163 % ==========================================
165 \caption{\label{categories} \texttt{Black Box} categories}
167 \begin{tabular}{|lp{10cm}|}
169 \texttt{Category name} & : Meaning \\ \hline \\ \hline
170 \texttt{adaptor} & : Adaptor box \\ \hline
171 \texttt{application} & : Final application, end user intended \\ \hline
172 \texttt{atomic box} & : System category.
173 Automatically assigned to Atomic Black Boxes (c++ defined) \\ \hline
174 \texttt{complex box} & : System category.
175 Automatically assigned to Complex Black Boxes (script defined) \\ \hline
176 \texttt{command line} & : Script which defines a command line application \\
177 & :(no embedded GUI, but command line imput parameters) \\ \hline
178 \texttt{demo} & : Demonstration \\ \hline
179 \texttt{devel} & : Developer tool (bbCreatePackage.bbs, ...) \\ \hline
180 \texttt{dicom} & : DICOM aware box \\ \hline
181 \texttt{example} & : Example script showing a box use-case \\ \hline
182 \texttt{filter} & : Image processing box \\ \hline
183 \texttt{image} & : Image processing related box \\ \hline
184 \texttt{interaction} & : \\ \hline
185 \texttt{math} & : Mathematical operations \\ \hline
186 \texttt{mesh} & : Mesh processing related box \\ \hline
187 \texttt{misc} & : Box that cannot be put in any other category ! \\ \hline
188 \texttt{read/write} & : Box that read or write data from or to disk \\ \hline
189 \texttt{viewer} & : Box which displays some data \\ \hline
190 \texttt{widget} & : Piece of graphical interface \\ \hline
191 \texttt{3D object creator} & : Sophisticated 3D widget \\ \hline
192 \texttt{toolsbbtk} & : Component of bbStudio \\ \hline
196 % ==========================================
205 ---> Should be moved in a 'Reference Manual' ?\\
206 ---> Any suggestion welcome!
209 % ==========================================
210 \subsubsection{Black box packages}
211 \label{bbi-more-on-packages}
212 % ==========================================
214 There are various others user-intended packages :
217 It contains some vtk based image processing filters :
220 \paragraph{AppendPolyData}
221 Appends one of more polygonal datasets into a single polygonal dataset
223 \paragraph{ConeSource}
226 \paragraph{ImageAnisotropicDiffusion3D}
227 vtk\-Image\-Anisotropic\-Diffusion\-3D dif\-fuses a volume iteratively. \\
228 The neighborhood of the diffusion is determined by the instance flags. \\
229 if 'Faces' is on, the 6 voxels adjoined by faces are included in the neighborhood. \\
230 If 'Edges' is on the 12 edge connected voxels are included, and if 'Corners' is on, the 8 corner connected voxels are included. \\
231 'DiffusionFactor' determines how far a pixel value moves toward its neighbors, and is insensitive to the number of neighbors chosen.\\
232 The diffusion is anisotropic because it only occurs when a gradient measure is below 'GradientThreshold'. \\
233 Two gradient measures exist and are toggled by the 'GradientMagnitudeThreshold' flag. \\
234 When 'GradientMagnitudeThreshold' is on, the magnitude of the gradient, computed by central differences, above 'DiffusionThreshold' a voxel is not
236 The alternative measure examines each neighbor independently.\\
237 The gradient between the voxel and the neighbor must be below the 'DiffusionThreshold' for diffusion to occur with THAT neighbor.\\
239 - In : an image (vtkImageData*)\\
240 - Diffusion : Difference threshold that stops the diffusion\\
242 - Out : the isosurface mesh (vtkPolyData*)
244 \paragraph{ImageCharacteristics}
245 Exports objet sizes, and Spacings
247 \paragraph{ImageDilateErode3D}
249 Dilates one value and erodes another.\\
250 vtkImageDilateErode3D will dilate one value and erode another. \\
251 It uses an elliptical foot print, and only erodes/dilates on the boundary of the two values. \\
252 The filter is restricted to the X, Y, and Z axes for now.\\
253 It can degenerate to a 2 or 1 dimensional filter by setting the kernel size to 1 for a specific axis. \\
254 (bbfication of vtkImageDilateErode3D) \\
256 - In : an image (vtkImageData*)\\
257 - DilateValue : The dilatation value\\
258 - ErodeValue : The erosion value\\
260 - Out : the isosurface mesh (vtkPolyData*)
262 \paragraph{ImageGaussianSmooth}
263 Performs a gaussian convolution of the input image\\
265 - In : an image (vtkImageData*)\\
266 - StdDevX : Standard deviation in X direction\\
267 - StdDevY : Standard deviation in Y direction\\
269 - Out : the isosurface mesh (vtkPolyData*)
271 \paragraph{ImagePlanes}
272 Creates three 3D planes with the input image mapped onto with which the user can interact; \\
273 The output vtkImagePlaneWidget objects are to be inserted into a 3D scene (e.g. a Viewer3D)
275 - In : an image (vtkImageData*)\\
277 - PlaneX : the image plane in X direction (vtkImagePlaneWidget*)\\
278 - PlaneY : the image plane in Y direction (vtkImagePlaneWidget*)\\
279 - PlaneY : the image plane in Z direction (vtkImagePlaneWidget*)\\
282 - Out : the isosurface mesh (vtkPolyData*)
284 \paragraph{IsoSurfaceExtractor}
285 Extracts an iso-surface of a 3D image and creates a vtkProp3D object to insert into a 3D scene (e.g. a Viewer3D)
287 - In : an image (vtkImageData*)\\
288 - Isovalue : the isosurface value (double)\\
289 - Colour : Surface colour (vector of 3 doubles)
291 - Out : the isosurface (vtkProp3D**)
293 \paragraph{MIPCreator}
294 Creates a Maximum Intensity Projection (MIP) view of a 3D image.\\
296 - In : an image (vtkImageData*)\\
297 - Scale : the Gray scale scaling (float) \\
298 - Shift : the Gray scale shift (float) \\
300 - Out : The MIP object (vtkProp3D*) to be plugged into a 3D Viever
302 \paragraph{MarchingCubes}
303 Extracts an iso-surface of an image using the marching cubes algorithm (bbfication of vtkMarchingCubes)\\
305 - In : an image (vtkImageData*)\\
306 - Value : the isosurface value (double)\\
308 - Out : the isosurface mesh (vtkPolyData*)
310 \paragraph{MetaImageReader}
311 Reads .mhd / .mhd image formats (bbfication of vtkMetaImageReader) \\
313 - In : the name of the file to be read (std::string)
315 - Out : The image (vtkImageData*)
317 \paragraph{SegmentationConnectivity}
318 Segmentation with min max threshold and connectivity \\
320 - In : an image (vtkImageData*)\\
321 - PositionXYZ : initial position (std::vector<int>) \\
322 - ThresholdMinMax : min, max threshold values (std::vector<int>) \\
324 - Out : The image (vtkImageData*)
326 \paragraph{SphereSource}
331 It contains some itk based image processing filters :
333 \paragraph{BinaryThresholdImageFilter}
334 Binarizes an image by thresholding (generic bbification of itk::BinaryThresholdImageFilter)
337 - In : Input image. Can be any itk::Image<T,D>* \\
338 - InsideValue : Output value for pixels inside thresholds (Double) \\
339 - LowerThreshold : Lower threshold(Double) \\
340 - OutsideValue : Output value for pixels outside thresholds (Double) \\
341 - UpperThreshold : Upper threshold (Double) \\
343 - Out' : Output image. Of the same type and dimension than the input image
345 \paragraph{DICOMSeriesFileNames}
346 Reads a series from a DICOM directory as a 3D itk image
348 \paragraph{ExtractImageFilter}
349 Decrease the image size by cropping the image to the selected region bounds (bbification of itk::ExtractImageFilter)
351 \paragraph{ImageProperties}
352 Outputs different properties of an image (type, dimension, size, spacing, ...)
354 \paragraph{ImageRegion}
355 Creates a generic ImageRegion (bbtk::any) from two vectors providing the index and size of the region.
356 The dimension D of the actual itk::ImageRegion created is the max of the sizes of Index and Size
357 (the smallest vector is padded by zeros)
359 \paragraph{ImageReader}
360 Generic itk image reader
362 \paragraph{ImageWriter}
363 Generic itk image writer
365 \paragraph{ImageSeriesReader}
366 Generic itk image series reader.
368 \paragraph{ResampleImageFilter}
372 It doesn't contain any end user intended box, only adaptors : to convert a generic itkImage to a vtkImageData, and vtkImageData* to a generic itkImage pointer
374 Sorry nothing is done, right now for meshes.
378 It contains two atomic black boxes.
382 - a \textless vtkImageData* \textgreater (In),\\
383 - an Orientation(0:yz / 1:xz / 2:xy),\\
384 - an initial slice number (Slice).\\
386 - a \textless vtkRenderer* \textgreater (Renderer)
390 - up to 5 Input Actors (\textless vtkProp3D* \textgreater),\\
391 - up to 5 Input Observers (\textless vtkInteractorObserver* \textgreater), \\
392 - a boolean 'Stereo' option, to use Red-Blue filter
394 - an Interactor (\textless wxVTKRenderWindowInteractor* \textgreater) with which vtk widgets can interact, \\
395 - a Renderer (\textless vtkRenderer* \textgreater) to which actors can be added.
397 It contains too some sophisticated complex black boxes :
399 \paragraph{IsoSurfaceWithControls}
400 Image iso-surface extractor (vtk::IsoSurfaceExtractor) with associated control panel (isovalue, opacity and colour)\\
402 - an initial isovalue (Isovalue)
403 - an initial opacity (Opacity)
404 - an initial colour (Colour)
406 \textless vtkProp3D* \textgreater (In)\\
408 \paragraph{MIPWithControls}
409 Maximum Intensity Projection (MIP) creator (vtk::MIPCreator) with associated control panel (shift and scale) \\
411 - an initial scale (Scale)
412 - an initial shift (Shift)
414 \textless vtkProp3D* \textgreater (In)\\
418 Some boxes are the bbfication of usefull xwWidgets, some other ones are more
421 \paragraph{ColourSelector} Colour Selector dialog (bbfication of wxColourSelector) \\
423 \texttt{Out} : Colour choosen in format '[0,1] [0,1] [0,1]'
426 \paragraph{ColourSelectorButton} A button which displays a colour picker dialog when clicked \\
428 \texttt{In} :Initial colour \\
429 \texttt{Out} : Colour choosen in format '[0,1] [0,1] [0,1]'
432 \paragraph{CommandButton} Button which executes bbi commands \\
434 \texttt{In} : Commands to be executed separated by commas (;). Each single quote (') is replaced by a double quote ("). \\
435 \texttt{Label} : Label of the button \\
436 \texttt{Widget} : Output widget \\
439 \paragraph{DirectorySelector} Pops up a directory selection dialog (wxDirDialog)\\
441 \texttt{DefaultDir} : The default directory\\
442 \texttt{Message} : Message to show on the dialog \\
443 \texttt{Title} : Title of the dialog \\
444 \texttt{Out} : The directory selected by the user\\
447 \paragraph{FileSelector} Pops up a file selection dialog for reading or saving (wxFileDialog)\\
449 \texttt{DefaultDir} : The default directory \\
450 \texttt{DefaultFile} : The default filename \\
451 \texttt{Message} : Message to show on the dialog \\
452 \texttt{OpenSave} : Open for an open dialog (default) / Save for a save dialog\\
453 \texttt{Title} : Title of the dialog \\
454 \texttt{Wildcard} : A wildcard, such as "*.*" or "BMP files (*.bmp)|*.bmp|GIF files (*.gif)|*.gif" \\
455 \texttt{Out} : The file selected by the user \\
458 \paragraph{InputText} A zone in which the user can enter a text (wxTextCtrl)\\
460 \texttt{In} : Initial text (default '')\\
461 \texttt{Title} : Title of the input zone (default '')\\
462 \texttt{WinTitle} : Title of the window (*)\\
463 \texttt{Out} :Current text\\
466 \paragraph{LayoutLine} LayoutLine widget (wxBoxSizer)\\
468 \texttt{Orientation} Orientation (default V), 0=H=HORIZONTAL , 1=V=VERTICAL \\
469 \texttt{Widget}1 widget 1 \\
470 \texttt{Widget2} widget 2 \\
471 \texttt{Widget3} widget 3 \\
472 \texttt{Widget4} widget 4 \\
473 \texttt{Widget5} widget 5 \\
474 \texttt{Widget6} widget 6 \\
475 \texttt{Widget7} widget 7 \\
476 \texttt{Widget8} widget 8 \\
477 \texttt{Widget9} widget 9\\
480 \paragraph{LayoutSplit} Widget which splits a window in two fixed size parts (wxSplitterWindow)\\
482 \texttt{Orientation} : Orientation (default H), 0=H=HORIZONTAL , 1=V=VERTICAL\\
483 \texttt{Proportion} : Proportion (in percent) of the first children in the window\\
484 \texttt{Widget1} : Upper or left widget\\
485 \texttt{Widget2} : Lower or right widget\\
488 \paragraph{LayoutTDown} Creates a 'T like' complex container : Down {UpLeft, UpRight} \\
490 \texttt{Widget1} : UpLeft container\\
491 \texttt{Widget2} : UpRight container\\
492 \texttt{Widget3} : Down container\\
503 \paragraph{LayoutTLeft} Creates a 'T like' complex container : Left {RigthUp, RightDown}\\
505 \texttt{input} Widget1 : "UpLeft container" \\
506 \texttt{input} Widget2 : "UpRight container" \\
507 \texttt{input} Wigdet3 : "Down container" \\
518 \paragraph{LayoutTRight} Creates a 'T like' complex container : Right {LeftUp, LeftDown}\\
520 \texttt{input} Widget1 currentBox.Widget1 "Up container" \\
521 \texttt{input} Widget2 down.Widget1 "DownLeft container" \\
522 \texttt{input} Widget3 down.Widget2 "DownRight container"\\
533 \paragraph{LayoutTUp} Creates a 'T like' complex container : Up {DownLeft, DownRight} as w1{w2,w3}\\
535 \texttt{ input} Widget1 currentBox.Widget1 "Up" \\
536 \texttt{input} Widget2 down.Widget1 "DownLeft" \\
537 \texttt{input} Widget3 down.Widget2 "DownRight"\\
549 \paragraph{LayoutTab} LayoutTab widget (wxNotebook)\\
551 \texttt{Orientation} Orientation (default T), 0=T=TOP , 1=R=RIGHT , 2=B=BOTTON , 3=L=LEFT \\
552 \texttt{Widget1} widget 1 \\
553 \texttt{Widget2} widget 2 \\
554 \texttt{Widget3} widget 3 \\
555 \texttt{Widget4} widget 4 \\
556 \texttt{Widget5} widget 5 \\
557 \texttt{Widget6} widget 6 \\
558 \texttt{Widget7} widget 7 \\
559 \texttt{Widget8} widget 8 \\
560 \texttt{Widget9} widget 9 \\
563 \paragraph{OutputText} Text zone to be inserted into a window (wxStaticText)\\
566 \texttt{Title} Title prepended to the text\\
569 \paragraph{RadioButton} RadioButton group widget 0-9 entries\\
571 \texttt{In} Set initial item \\
572 \texttt{In0} option 0\\
573 \texttt{In1} option 1\\
574 \texttt{In2} option 2\\
575 \texttt{In3} option 3\\
576 \texttt{In4} option 4\\
577 \texttt{In5} option 5 \\
578 \texttt{In6} option 6 \\
579 \texttt{In7} option 7 \\
580 \texttt{In8} option 8 \\
581 \texttt{In9} option 9 \\
582 \texttt{Title} Title of the widget (default '')\\
583 \texttt{Out} Number of the selected Item
586 \paragraph{Slider} Slider widget (wxSlider)\\
588 \texttt{ChangeResolution} Enables the user to change the slider resolution (default FALSE) \\
589 \texttt{In} Initial slider position(default 0) \\
590 \texttt{Label} Show slider labels ? (default FALSE) \\
591 \texttt{Max} Maximum value of the slider (default 500)\\
592 \texttt{Min} Minimum value of the slider (default 0)\\
593 \texttt{Orientation} Orientation : (default H) 0=H=HORIZONTAL, 1=V=VERTICAL\\
594 \texttt{ReactiveOnTrack} Slider sends info when track moves (default 0 = no)\\
595 \texttt{Title} Title shown above the slider (default '')\\
604 %\section{Conclusion}