View Issue Details

IDProjectCategoryView StatusLast Update
0003573Slicer4Core: MRMLpublic2017-06-10 08:51
Reporterjohan.andruejol Assigned Tonicole  
PrioritynormalSeverityfeatureReproducibilityN/A
Status closedResolutionfixed 
Product Version 
Target VersionSlicer 4.4.0Fixed in VersionSlicer 4.4.0 
Summary0003573: Model scalar display: lookup table scalar range option
Description

Copy-paste from my e-mail to the developer's list:

I am currently looking at the display of scalars arrays on models. When displaying a model and its associated scalar array, I realized that the look-up table used for display is always scaled to the scalar array's range.

For example, let's say that I have a model with an array called 'Struct" that lists different anatomical structures. It ranges from 3 to 15. If I try to display my model with the array and the GenericAnatomyColors color node, all the model's point with a "Struct" value of 3 will be displayed with the GenericAnatomyColors' color of label 0. The points with "Struct" value of 15 will be displayed with the GenericAnatomyColors' color of the GenericAnatomyColors maximum label.

I think it would make sense to have an option that would prevent this sort of scaling. With this option on and my example from above, all the points with a "Struct" value of 3 would be displayed with the GenericAnatomyColors' label 3. This especially make sense when the model array's corresponds to an anatomical color table.

Additional Information

Original discussion here:
http://massmail.spl.harvard.edu/public-archives/slicer-devel/2014/014539.html

TagsNo tags attached.

Relationships

related to 0001918 closedmehrtash Color scale 
parent of 0003783 closednicole Force color to children checkbox does not work 
related to 0002947 closedalexy Color models by cell field arrays 

Activities

nicole

nicole

2014-03-03 10:30

administrator   ~0010661

Working on a github topic branch to provide more options for scalar range in color mapping.

nicole

nicole

2014-04-11 12:12

administrator   ~0011579

Working on integrating this branch:
https://github.com/naucoin/Slicer/commits/3573-model-scalar-display-rebase

nicole

nicole

2014-04-11 14:00

administrator   ~0011582

Fixed as of svn 23084:
http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=23084
http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=23083 (this one adds the ScalarRangeFlag)
http://viewvc.slicer.org/viewvc.cgi/Slicer4?view=revision&revision=23082

2014-04-16 05:51

 

3573.PNG (221,821 bytes)
3573.PNG (221,821 bytes)
johan.andruejol

johan.andruejol

2014-04-16 05:54

manager   ~0011596

It's great thanks !

I tried it with my data and I was able to change the scalar range appropriately.
However, I could only see the colors in the slices views and not in the 3D view (see enclosed screenshot).
I used this model: http://packages.kitware.com/download/item/4983/man-arm-2mm-merged-padded-tetmesh-v2.vtk. Is my data the issue ?

nicole

nicole

2014-04-16 07:41

administrator   ~0011597

I think it's the scalar overlay, the "Active Scalar Range" calculation is failing on the the MaterialId overlay. It looks like most of the other overlays are defined from 0-1 or so, and are mapping properly, but the MaterialId scalar array is different.

Digging into the .vtk, turns out that MaterialId and MaterialParameters are defined as Cell Data not Point Data. The latter is assumed for the 3D rendering of the overlays, and there is a bug open about enabling Cell Data:
http://na-mic.org/Mantis/view.php?id=2947

For now, the hint that it won't work in 3D is that the "Active Scalar Range" is blank.

johan.andruejol

johan.andruejol

2014-04-16 07:43

manager   ~0011598

Thanks for the answers. Resolving the issue.

jcfr

jcfr

2014-09-17 23:01

administrator   ~0012554

Closing resolved issues that have not been updated in more than 3 months.

Related Changesets

Import 2017-06-07 23:51:09: master a22c49ca

2014-04-11 17:44:58

naucoin

Details Diff
ENH: Expand scalar range options

Add the ScalarRangeFlag on the display node, test it, use it in the Model
display node.
Provide a GUI interface for it in the Models Scalars GUI.
Use it in the model displayable manager.
Separate out the auto scalar range setting from updating the poly data
in the model display node.

This expands the options from just using the scalar range of the data
to allowing the user to select using the scalar range defined on the
display node, the range on the color node, or the range of the data
type (use this last with caution, TBD: readjusting the minimum and
maximum values allowed on the range slider). Keeps the default
behaviour of AutoScalarRange and Data. The interaction of Auto/Manual
and the range flags might need some tweaking.
Also keeps the deep copy of the color look up table in the model displayable
manager - monitor for performance issues.
Expands the model displayable manager to work with procedural color nodes,
this required copying the color transfer function to a look up table to
support setting the range. Using a table with 256 entries for now.
UI full change due to having to run dos2unix on it to get it commited
to git without whitespace errors.

Issue 0003573



git-svn-id: http://svn.slicer.org/Slicer4/trunk@23083 3bd1e089-480b-0410-8dfb-8563597acbee
mod - Libs/MRML/Core/vtkMRMLCoreTestingMacros.h Diff File
mod - Libs/MRML/Core/vtkMRMLDisplayNode.cxx Diff File
mod - Libs/MRML/Core/vtkMRMLDisplayNode.h Diff File
mod - Libs/MRML/Core/vtkMRMLModelDisplayNode.cxx Diff File
mod - Libs/MRML/DisplayableManager/vtkMRMLModelDisplayableManager.cxx Diff File
mod - Modules/Loadable/Models/Widgets/Resources/UI/qMRMLModelDisplayNodeWidget.ui Diff File
mod - Modules/Loadable/Models/Widgets/qMRMLModelDisplayNodeWidget.cxx Diff File
mod - Modules/Loadable/Models/Widgets/qMRMLModelDisplayNodeWidget.h Diff File

Import 2017-06-07 23:51:09: master 8edcb92e

2014-04-11 17:51:08

naucoin

Details Diff
ENH: Add procedural color storage node and GUI support

Add a new storage node, register it, test it.
Added support for copying procedural nodes so that users can copy
an existing one and then save it to disk.
LoadColorFile expanded to work with both color table and procedural
color node loading.
TBD: add support for .cxml
Added support in the Colors gui to display and edit color transfer
functions (Continuous frame, with a ctkVTKScalarsToColorsWidget).
As well as allowing the scalar bar widget to be set from a procedural
color node.

Issue 0003573



git-svn-id: http://svn.slicer.org/Slicer4/trunk@23084 3bd1e089-480b-0410-8dfb-8563597acbee
mod - Libs/MRML/Core/CMakeLists.txt Diff File
mod - Libs/MRML/Core/Testing/CMakeLists.txt Diff File
add - Libs/MRML/Core/Testing/vtkMRMLProceduralColorStorageNodeTest1.cxx Diff File
mod - Libs/MRML/Core/vtkMRMLColorTableStorageNode.cxx Diff File
mod - Libs/MRML/Core/vtkMRMLProceduralColorNode.cxx Diff File
mod - Libs/MRML/Core/vtkMRMLProceduralColorNode.h Diff File
add - Libs/MRML/Core/vtkMRMLProceduralColorStorageNode.cxx Diff File
add - Libs/MRML/Core/vtkMRMLProceduralColorStorageNode.h Diff File
mod - Libs/MRML/Core/vtkMRMLScene.cxx Diff File
mod - Libs/MRML/Logic/Testing/Cxx/vtkMRMLColorLogicTest1.cxx Diff File
mod - Libs/MRML/Logic/vtkMRMLColorLogic.cxx Diff File
mod - Libs/MRML/Logic/vtkMRMLColorLogic.h Diff File
mod - Modules/Loadable/Colors/Logic/vtkSlicerColorLogic.cxx Diff File
mod - Modules/Loadable/Colors/Resources/UI/qSlicerColorsModuleWidget.ui Diff File
mod - Modules/Loadable/Colors/Testing/Cxx/qSlicerColorsModuleWidgetTest1.cxx Diff File
mod - Modules/Loadable/Colors/qSlicerColorsModuleWidget.cxx Diff File
mod - Modules/Loadable/Colors/qSlicerColorsReader.cxx Diff File

Import 2017-06-07 23:51:09: master 66cbdfe1

2014-04-13 22:09:53

naucoin

Details Diff
COMP: memory allocation on windows

Issue 0003573



git-svn-id: http://svn.slicer.org/Slicer4/trunk@23094 3bd1e089-480b-0410-8dfb-8563597acbee
mod - Libs/MRML/DisplayableManager/vtkMRMLModelDisplayableManager.cxx Diff File

Import 2017-06-07 23:51:09: master a0f86c3d

2014-05-01 17:14:01

naucoin

Details Diff
BUG: disable alternate color editors

The color module was just collapsing the color table and
continuous color transfer viewer/editors when the other type
of node was active. User feedback showed this to be confusing
as valid looking data was visible if the sections were
expanded. This change disables the invalid editor on
selection of a color node.

Issue 0003573


git-svn-id: http://svn.slicer.org/Slicer4/trunk@23117 3bd1e089-480b-0410-8dfb-8563597acbee
mod - Modules/Loadable/Colors/qSlicerColorsModuleWidget.cxx Diff File

Import 2017-06-07 23:51:09: master d0bffb09

2014-05-02 17:10:43

naucoin

Details Diff
BUG: fix fiber bundle color display

Check for fiber bundle display nodes and use the old method,
igoring the new scalar range options for models. Fixes bug
introduced with issue 0003573 in svn revision 23083

Issue 0003672


git-svn-id: http://svn.slicer.org/Slicer4/trunk@23118 3bd1e089-480b-0410-8dfb-8563597acbee
mod - Libs/MRML/DisplayableManager/vtkMRMLModelDisplayableManager.cxx Diff File

Import 2017-06-07 23:51:09: master daeeacad

2014-05-21 17:21:14

naucoin

Details Diff
ENH: Update copy color icon

User feedback on the customisation of color tables suggested that
a more clear icon be used for the copy to edit functionality.

Issue 0003573


git-svn-id: http://svn.slicer.org/Slicer4/trunk@23225 3bd1e089-480b-0410-8dfb-8563597acbee
add - Modules/Loadable/Colors/Resources/Icons/SlicerCopyColor.png Diff File
mod - Modules/Loadable/Colors/Resources/qSlicerColorsModule.qrc Diff File
mod - Modules/Loadable/Colors/qSlicerColorsModuleWidget.cxx Diff File

Issue History

Date Modified Username Field Change
2014-01-29 11:58 johan.andruejol New Issue
2014-01-29 11:58 johan.andruejol Status new => assigned
2014-01-29 11:58 johan.andruejol Assigned To => alexy
2014-01-29 12:04 jcfr Assigned To alexy => nicole
2014-01-29 12:04 jcfr Target Version => Slicer 4.4.0
2014-01-29 12:05 jcfr Severity minor => feature
2014-01-29 12:05 jcfr Reproducibility have not tried => N/A
2014-03-03 10:30 nicole Relationship added related to 0001918
2014-03-03 10:30 nicole Note Added: 0010661
2014-04-11 12:12 nicole Note Added: 0011579
2014-04-11 14:00 nicole Note Added: 0011582
2014-04-11 14:00 nicole Status assigned => resolved
2014-04-11 14:00 nicole Fixed in Version => Slicer 4.4.0
2014-04-11 14:00 nicole Resolution open => fixed
2014-04-16 05:51 johan.andruejol File Added: 3573.PNG
2014-04-16 05:54 johan.andruejol Note Added: 0011596
2014-04-16 05:54 johan.andruejol Status resolved => feedback
2014-04-16 05:54 johan.andruejol Resolution fixed => reopened
2014-04-16 07:41 nicole Relationship added related to 0002947
2014-04-16 07:41 nicole Note Added: 0011597
2014-04-16 07:43 johan.andruejol Note Added: 0011598
2014-04-16 07:43 johan.andruejol Status feedback => resolved
2014-04-16 07:43 johan.andruejol Resolution reopened => fixed
2014-08-01 16:33 finetjul Relationship added parent of 0003783
2014-09-17 22:59 jcfr Status resolved => closed
2014-09-17 23:01 jcfr Note Added: 0012554
2017-06-10 08:51 Changeset attached => Slicer master daeeacad
2017-06-10 08:51 Changeset attached => Slicer master d0bffb09
2017-06-10 08:51 Changeset attached => Slicer master a0f86c3d
2017-06-10 08:51 Changeset attached => Slicer master 66cbdfe1
2017-06-10 08:51 Changeset attached => Slicer master 8edcb92e
2017-06-10 08:51 Changeset attached => Slicer master a22c49ca