Raster, Color Function as Pure FunctionI
- To: mathgroup at smc.vnet.net
- Subject: [mg81389] Raster, Color Function as Pure FunctionI
- From: lamoucheg at gmail.com
- Date: Fri, 21 Sep 2007 03:12:57 -0400 (EDT)
If "Dynamic updating" is disabled in the menu "Evaluation", the following graphic shows up: Graphics[Raster[{{0, 0.2, 0.4}, {0.6, 0.8, 1}}, ColorFunction -> Hue]] while the following two don't: Graphics[Raster[{{0, 0.2, 0.4}, {0.6, 0.8, 1}}, ColorFunction -> (Hue[#1] & )]] Graphics[Raster[{{0, 0.2, 0.4}, {0.6, 0.8, 1}}, ColorFunction -> (RGBColor[#1, #1, 1 - #1] & )]] Everything shows up finely with Dynamic Updating enabled. Obviously, the treatment is more complex when pure functions are used to specify the color scale. But why through dynamically evaluated things? Anybody can shed light on the rendering process when pure functions are used with Graphics[Raster[]]? Note that it is not the case when ArrayPlot is used, even with Dynamic Updating disabled, pure functions can be used for ColorFunction. Thanks. Guy Lamouche