Difference between revisions of "Documentation/4.0/Developers/Modules"

From Slicer Wiki
Jump to: navigation, search
(Created page with 'Slicer supports 3 types of modules. While the developer has to choose between one of the 3 types to implement its module, the end user won't notice a difference as they all share…')
 
Line 1: Line 1:
 
Slicer supports 3 types of modules. While the developer has to choose between one of the 3 types to implement its module, the end user won't notice a difference as they all share the look&feel. The choice for a given type of module is usually based on the type of inputs/parameters for a given module.
 
Slicer supports 3 types of modules. While the developer has to choose between one of the 3 types to implement its module, the end user won't notice a difference as they all share the look&feel. The choice for a given type of module is usually based on the type of inputs/parameters for a given module.
 
= Command Line Interface (CLI) =
 
= Command Line Interface (CLI) =
- CLIs are standalone executables with a limited input/output arguments complexity (simple argument types, no user interactions...). They are typically implemented using ITK.
+
CLIs are standalone executables with a limited input/output arguments complexity (simple argument types, no user interactions...). They are typically implemented using ITK.
 
* Shared lib or executable
 
* Shared lib or executable
 
* GUI automatically generated
 
* GUI automatically generated
* [http://www.slicer.org/slicerWiki/index.php/Slicer3:Execution_Model_Documentation|Slicer3 execution model]
+
* Links:
 +
* [http://www.slicer.org/slicerWiki/index.php/Slicer3:Execution_Model_Documentation|Slicer3 execution model] (Slicer4 is similar)
 
= Loadable Modules =
 
= Loadable Modules =
 +
Loadable modules are C++ plugins that are built against Slicer. They define custom GUIs for their specific behavior as they have full control over the application.
 
* C++ shared library
 
* C++ shared library
* Full control over the GUI (Qt) and the Slicer internals (logics, display managers...)
+
* Full control over the GUI (Qt) and Slicer internals (MRML, logics, display managers...)
 
* Optimized for heavy computations
 
* Optimized for heavy computations
 +
* Links:
 +
**[http://www.slicer.org/slicerWiki/index.php/Documentation/4.0/Developers/Tutorials/ModuleWriting|How to write Loadable Modules]
 
= Scripted Modules =
 
= Scripted Modules =
* Python
+
Scripted modules are written in Python and typically but not necessarily use the high level API of Slicer and toolkits. 
* Full access to the API: VTK, ITK, MRML, Qt, Slicer fully wrapped
+
* Python Console
 +
* Full access to the API: VTK, ITK, MRML, Qt and Slicer are fully wrapped
 
* Recommended for fast prototyping
 
* Recommended for fast prototyping
 +
* Links:
 +
* [http://www.slicer.org/slicerWiki/index.php/Documentation/4.0/Developers/Python_scripting|Python Scripting]

Revision as of 20:12, 16 December 2011

Home < Documentation < 4.0 < Developers < Modules

Slicer supports 3 types of modules. While the developer has to choose between one of the 3 types to implement its module, the end user won't notice a difference as they all share the look&feel. The choice for a given type of module is usually based on the type of inputs/parameters for a given module.

Command Line Interface (CLI)

CLIs are standalone executables with a limited input/output arguments complexity (simple argument types, no user interactions...). They are typically implemented using ITK.

  • Shared lib or executable
  • GUI automatically generated
  • Links:
  • execution model (Slicer4 is similar)

Loadable Modules

Loadable modules are C++ plugins that are built against Slicer. They define custom GUIs for their specific behavior as they have full control over the application.

  • C++ shared library
  • Full control over the GUI (Qt) and Slicer internals (MRML, logics, display managers...)
  • Optimized for heavy computations
  • Links:

Scripted Modules

Scripted modules are written in Python and typically but not necessarily use the high level API of Slicer and toolkits.

  • Python Console
  • Full access to the API: VTK, ITK, MRML, Qt and Slicer are fully wrapped
  • Recommended for fast prototyping
  • Links:
  • Scripting