|
Bugzilla – Bug 384 |
LUT ignored when images have no CoordinateTransform |
Last modified: 2012-04-20 23:11:29 CDT |
| ⚠ |
NOTICE! This is a static HTML version of a legacy Fiji BugZilla bug. The Fiji project now uses GitHub Issues for issue tracking. Please file all new issues there. |
| LUT ignored when images have no CoordinateTransform | |
|
|
|
||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||
Only images that have a CoordinateTransform respect the IndexColorModel applied to the ImageProcessor. When the CoordinateTransform is removed, images are rendered using a default gray LUT. Test by applying the following Beanshell as a preprocessor script: blue.bsh byte[] r = new byte[ 256 ]; byte[] g = new byte[ 256 ]; byte[] b = new byte[ 256 ]; for ( int i = 0; i < 256; ++i ) b[ i ] = ( byte )i; imp.getProcessor().setColorModel( new java.awt.image.IndexColorModel( 8, 256, r, g, b ) ); Current workaround: Trigger the CoordinateTransform rendering mode by applying an identity transform as CoordinateTransform to all patches: for ( patch : Display.getFront().getLayerSet().getDisplayables( Patch.class) ) patch.setCoordinateTransform( new mpicbg.trakem2.transform.TranslationModel2D() ); Still, a fix would be nice :)