Difference between revisions of "Modules:Color-Documentation-3.4"

From Slicer Wiki
Jump to: navigation, search
 
(11 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
[[Documentation-3.4|Return to Slicer 3.4 Documentation]]
 
[[Documentation-3.4|Return to Slicer 3.4 Documentation]]
 +
 +
[[Announcements:Slicer3.4#Highlights|Gallery of New Features]]
 
__NOTOC__
 
__NOTOC__
 
===Color Module===
 
===Color Module===
Line 5: Line 7:
  
 
{|
 
{|
|[[Image:screenshotBlank.png|thumb|280px|Caption 1]]
+
|[[Image:SlicerColorDisplayWidget-3.4.jpg|thumb|280px|Color Display]]
|[[Image:screenshotBlank.png|thumb|280px|Caption 2]]
+
|[[Image:SlicerModuleSettingsColor-3.4.jpg|thumb|280px|Module Settings]]
|[[Image:screenshotBlank.png|thumb|280px|Caption 3]]
+
|[[Image:SlicerColorEditGUI-3.4.jpg|thumb|280px|Edit panel]]
 
|}
 
|}
  
Line 24: Line 26:
 
===Module Description===
 
===Module Description===
 
The Color Module manages color look up tables.
 
The Color Module manages color look up tables.
 +
 +
Look-up Tables (LUTs) are used by mappers to translate between an integer and a color value for display of models and volumes.
  
 
== Usage ==
 
== Usage ==
Line 30: Line 34:
  
 
This module is used to change the color mapping of volumes, model scalar overlays.
 
This module is used to change the color mapping of volumes, model scalar overlays.
 
+
<!--
 
* Note use cases for which this module is especially appropriate, and/or link to examples.
 
* Note use cases for which this module is especially appropriate, and/or link to examples.
 
* Link to examples of the module's use
 
* Link to examples of the module's use
 
* Link to any existing tutorials
 
* Link to any existing tutorials
 +
-->
  
 
===Quick Tour of Features and Use===
 
===Quick Tour of Features and Use===
  
* '''Load panel:''' The ''Select Color File'' button will let you choose a text color file to load.  
+
* '''Load panel:''' The ''Select Color File'' button will let you choose a text color file to load. [[Image:SlicerColorLoad-3.4.jpg]]
 
You can also specify a directory from which to read color files using the View -> Application Settings window, Module Settings frame. Click on the ''Add a preset'' button to add one or more new user color file paths. The directory will be searched for color files with names ending in .txt (for now, csv coming later). You have to restart Slicer to load the new files after setting the paths the first time.
 
You can also specify a directory from which to read color files using the View -> Application Settings window, Module Settings frame. Click on the ''Add a preset'' button to add one or more new user color file paths. The directory will be searched for color files with names ending in .txt (for now, csv coming later). You have to restart Slicer to load the new files after setting the paths the first time.
  
Line 49: Line 54:
  
 
* '''Display panel:'''
 
* '''Display panel:'''
 +
This is a stand alone widget that can be popped up by other modules, for example the Editor. Here it lets you inspect the values of the colour look up table.
 
Slicer supports three kinds of tables:
 
Slicer supports three kinds of tables:
 
# Continuous scales, like the greyscale table.
 
# Continuous scales, like the greyscale table.
 
# Parametric tables, defined by an equation, such as the FMRIPA table.
 
# Parametric tables, defined by an equation, such as the FMRIPA table.
 
# Discrete tables, such as those read in from a file.
 
# Discrete tables, such as those read in from a file.
 +
**''Color Select'': Choose from a drop down list of color nodes.
 +
[[Image:SlicerColorNodes-3.4.jpg]]
 +
**''Node Type'': a label updated to give the type of the node currently being displayed
 +
**''Total Number of Colours in Table'': a label updated to display the number of entries in the color look up table.
 +
**''Selected Color Label'': used especially in the Editor module, draw with the colour last clicked upon in the table.
 +
**List box: The contents of the colour table, the entry is the integer label value, the name will show up in the label map layer of th 22d slice windows when you mouse over voxels with the corresponding value, the Color column shows how the voxel will be rendered.
 +
**''Show Only Named Colors'': when this box is checked, the list box will only be populated by named colours. Some colour tables can have memtpy entries that have no name and default to black, this option lets you hide or show them.
 
* '''Edit panel:'''
 
* '''Edit panel:'''
 +
This panel lets users create a new colour look up table file.
 +
 +
[[Image:SlicerColorEditGUI-3.4.jpg]]
 +
 
Users are only allowed to edit User type tables. Use the Edit frame to create a new color table, and save it to a file.
 
Users are only allowed to edit User type tables. Use the Edit frame to create a new color table, and save it to a file.
 +
 +
First, give your new color table a name in the ''Name'' entry.
 +
 +
Then fill in the ''Number of Colors''. The list box will be populated with the corresponding number of entries. You can reset this to a larger number w/o losing your current settings.
 +
 +
Then click on ''Generate'' to populate a new node from the GUI contents. The color node is now available to use in the Volumes or Edit modules.
 +
 +
Then you can click on ''Save'' to write the node to a file for future loading.
  
 
== Development ==
 
== Development ==
Line 88: Line 113:
  
 
Documentation generated by doxygen.
 
Documentation generated by doxygen.
* [http://www.na-mic.org/Slicer/Documentation/Slicer3/html/classvtkSlicerColorGUI.html Color GUI]
+
* [http://www.na-mic.org/Slicer/Documentation/Slicer3-doc/html/classvtkSlicerColorGUI.html Color GUI]
* [http://www.na-mic.org/Slicer/Documentation/Slicer3/html/classvtkSlicerColorLogic.html Color Logic]
+
* [http://www.na-mic.org/Slicer/Documentation/Slicer3-doc/html/classvtkSlicerColorLogic.html Color Logic]
* [http://www.na-mic.org/Slicer/Documentation/Slicer3/html/classvtkSlicerColorDisplayWidget.html Color Display Widget]
+
* [http://www.na-mic.org/Slicer/Documentation/Slicer3-doc/html/classvtkSlicerColorDisplayWidget.html Color Display Widget]
* [http://www.na-mic.org/Slicer/Documentation/Slicer3/html/classvtkSlicerColorEditWidget.html Color Edit Widget]
+
* [http://www.na-mic.org/Slicer/Documentation/Slicer3-doc/html/classvtkSlicerColorEditWidget.html Color Edit Widget]
* [http://www.na-mic.org/Slicer/Documentation/Slicer3/html/classvtkMRMLColorNode.html MRML Color Node] (superclass from which other color nodes are derived)
+
* [http://www.na-mic.org/Slicer/Documentation/Slicer3-doc/html/classvtkMRMLColorNode.html MRML Color Node] (superclass from which other color nodes are derived)
  
 
== More Information ==  
 
== More Information ==  

Latest revision as of 21:42, 15 January 2010

Home < Modules:Color-Documentation-3.4

Return to Slicer 3.4 Documentation

Gallery of New Features

Color Module

Color

Color Display
Module Settings
Edit panel

General Information

Module Type & Category

Type: Interactive

Category: Base

Authors, Collaborators & Contact

  • Nicole Aucoin: Brigham and Women's Hospital
  • Sebastien Barre, Kitware Inc.
  • Contact: Nicole Aucoin, nicole@bwh.harvard.edu

Module Description

The Color Module manages color look up tables.

Look-up Tables (LUTs) are used by mappers to translate between an integer and a color value for display of models and volumes.

Usage

Examples, Use Cases & Tutorials

This module is used to change the color mapping of volumes, model scalar overlays.

Quick Tour of Features and Use

  • Load panel: The Select Color File button will let you choose a text color file to load. SlicerColorLoad-3.4.jpg

You can also specify a directory from which to read color files using the View -> Application Settings window, Module Settings frame. Click on the Add a preset button to add one or more new user color file paths. The directory will be searched for color files with names ending in .txt (for now, csv coming later). You have to restart Slicer to load the new files after setting the paths the first time.

Color files have one color per line:

label name R G B A

label is an integer, name a string, and RGBA are 0-255. A = 255 for opaque.

In a the binary directory of Slicer3, the default color files live in share/Slicer3/SlicerBaseLogic/Resources/ColorFiles.

  • Display panel:

This is a stand alone widget that can be popped up by other modules, for example the Editor. Here it lets you inspect the values of the colour look up table. Slicer supports three kinds of tables:

  1. Continuous scales, like the greyscale table.
  2. Parametric tables, defined by an equation, such as the FMRIPA table.
  3. Discrete tables, such as those read in from a file.
    • Color Select: Choose from a drop down list of color nodes.

SlicerColorNodes-3.4.jpg

    • Node Type: a label updated to give the type of the node currently being displayed
    • Total Number of Colours in Table: a label updated to display the number of entries in the color look up table.
    • Selected Color Label: used especially in the Editor module, draw with the colour last clicked upon in the table.
    • List box: The contents of the colour table, the entry is the integer label value, the name will show up in the label map layer of th 22d slice windows when you mouse over voxels with the corresponding value, the Color column shows how the voxel will be rendered.
    • Show Only Named Colors: when this box is checked, the list box will only be populated by named colours. Some colour tables can have memtpy entries that have no name and default to black, this option lets you hide or show them.
  • Edit panel:

This panel lets users create a new colour look up table file.

SlicerColorEditGUI-3.4.jpg

Users are only allowed to edit User type tables. Use the Edit frame to create a new color table, and save it to a file.

First, give your new color table a name in the Name entry.

Then fill in the Number of Colors. The list box will be populated with the corresponding number of entries. You can reset this to a larger number w/o losing your current settings.

Then click on Generate to populate a new node from the GUI contents. The color node is now available to use in the Volumes or Edit modules.

Then you can click on Save to write the node to a file for future loading.

Development

Dependencies

The Volumes, Editor, and Models modules require this module.

Known bugs

Follow this link to the Slicer3 bug tracker.


Usability issues

Follow this link to the Slicer3 bug tracker. Please select the usability issue category when browsing or contributing.

Source code & documentation

Source code:

Documentation generated by doxygen.

More Information

Acknowledgment

This work is part of the National Alliance for Medical Image Computing (NAMIC), funded by the National Institutes of Health through the NIH Roadmap for Medical Research, Grant U54 EB005149.

References