POV-Ray : Newsgroups : povray.binaries.images : Unexpected black body colors from CIE.inc Server Time
2 Nov 2024 04:24:06 EDT (-0400)
  Unexpected black body colors from CIE.inc (Message 1 to 3 of 3)  
From: Cousin Ricky
Subject: Unexpected black body colors from CIE.inc
Date: 10 Oct 2011 13:25:01
Message: <web.4e9329ffeeedc00678641e0c0@news.povray.org>
I used CIE.inc from LightsysIV to display black body colors at various
temperatures.  As the temperature increased, I expected the color to become
yellower before it turned white.  Instead, I could not discern any change in
hue.

I figured that the change in hue might be too subtle for me to detect, so I
#debugged the hues.  Too my surprise, after becoming slightly yellower, the hue
doubled back on itself and got redder, then onto magenta, violet, and blue.

Is this right?  If so, why do candle flames (glowing soot particles) look
yellower than glowing coals?  Could it be a whitepoint issue?  Floating point
accuracy?  That warning that splines are an experimental feature?

The attached image shows my results, with a fully-saturated swatch to the lower
right of each sample.
________________________________________________________________________________

#version 3.7;

#declare SIDE = 8;

#include "shapes.inc"
#include "colors.inc"
#include "CIE.inc"

global_settings { assumed_gamma 1 }

camera
{  orthographic
   location <(SIDE - 1) * 2, (SIDE - 1) * 1.5, -10>
   right (4*SIDE + 0.8) * x
   up (3*SIDE + 0.6) * y
}

light_source
{  -1000 * z, rgb 1
   parallel point_at 0
}

#default { finish { ambient 0 diffuse 1 brilliance 0.5 } }

#debug "Temperature          Color            Hue\n"
#debug "-----------  ---------------------  -------\n"
#declare Coolest = ln(ln(2000));
#declare Hottest = ln(ln(50000));
#declare I = 0;
#while (I < SIDE*SIDE)
   #declare Temp = exp (exp (Coolest + (Hottest - Coolest) * I / (SIDE*SIDE -
1)));
   #declare c_Color = Blackbody(Temp);
   #declare c_Sat = c_Color - min (c_Color.red, c_Color.green, c_Color.blue);
   #declare c_Sat = c_Sat / max (c_Sat.red, c_Sat.green, c_Sat.blue);
   union
   {  sphere
      {  0, 1.2
         pigment { rgb c_Color }
      }
      box
      {  <2.0, -1.0, 0>, <1.4, -0.3, 1>
         pigment { rgb c_Sat }
      }
      object
      {  Center_Object (text { ttf "cyrvetic.ttf" str(Temp,0,0) 1, 0 }, x+y)
         scale 2/3
         translate -2*z
         pigment { rgb 0 }
      }
      translate <4 * (SIDE-1 - mod(I,SIDE)) - 0.4, 3 * floor(I/SIDE), 0>
   }
   #declare hsv_Color = CRGB2HSV (c_Color);
   #debug concat (str(Temp,8,0), "     <", vstr (3, c_Color, ", ", 0, 3), ">",
      str(hsv_Color.x,9,3), "\n")
   #declare I = I + 1;
#end
________________________________________________________________________________

Temperature          Color            Hue
-----------  ---------------------  -------
    2000     <1.000, 0.257, 0.008>   15.037
    2087     <1.000, 0.278, 0.016>   15.936
    2179     <1.000, 0.299, 0.026>   16.831
    2275     <1.000, 0.321, 0.037>   17.719
    2376     <1.000, 0.344, 0.050>   18.596
    2482     <1.000, 0.368, 0.065>   19.459
    2594     <1.000, 0.393, 0.082>   20.305
    2711     <1.000, 0.418, 0.101>   21.130
    2834     <1.000, 0.443, 0.123>   21.930
    2964     <1.000, 0.470, 0.147>   22.702
    3100     <1.000, 0.496, 0.173>   23.439
    3243     <1.000, 0.524, 0.203>   24.137
    3394     <1.000, 0.551, 0.236>   24.791
    3553     <1.000, 0.580, 0.271>   25.391
    3720     <1.000, 0.608, 0.310>   25.929
    3895     <1.000, 0.637, 0.352>   26.392
    4081     <1.000, 0.666, 0.397>   26.762
    4276     <1.000, 0.695, 0.445>   27.016
    4482     <1.000, 0.724, 0.497>   27.115
    4699     <1.000, 0.754, 0.552>   27.002
    4927     <1.000, 0.783, 0.610>   26.580
    5168     <1.000, 0.812, 0.671>   25.671
    5423     <1.000, 0.840, 0.734>   23.912
    5691     <1.000, 0.868, 0.800>   20.431
    5975     <1.000, 0.896, 0.869>   12.447
    6274     <1.000, 0.923, 0.940>  -12.742
    6590     <0.988, 0.939, 1.000>  288.151
    6924     <0.921, 0.899, 1.000>  252.974
    7277     <0.861, 0.862, 1.000>  239.451
    7650     <0.808, 0.829, 1.000>  233.440
    8044     <0.761, 0.799, 1.000>  230.519
    8461     <0.719, 0.771, 1.000>  228.882
    8902     <0.681, 0.745, 1.000>  227.893
    9369     <0.647, 0.722, 1.000>  227.273
    9864     <0.617, 0.701, 1.000>  226.879
   10387     <0.590, 0.681, 1.000>  226.631
   10941     <0.565, 0.663, 1.000>  226.481
   11528     <0.543, 0.647, 1.000>  226.398
   12150     <0.523, 0.632, 1.000>  226.361
   12810     <0.505, 0.618, 1.000>  226.358
   13509     <0.489, 0.605, 1.000>  226.378
   14251     <0.474, 0.593, 1.000>  226.414
   15038     <0.460, 0.582, 1.000>  226.462
   15874     <0.447, 0.572, 1.000>  226.517
   16760     <0.436, 0.562, 1.000>  226.576
   17702     <0.426, 0.554, 1.000>  226.639
   18703     <0.416, 0.546, 1.000>  226.703
   19766     <0.407, 0.538, 1.000>  226.767
   20896     <0.399, 0.531, 1.000>  226.830
   22098     <0.392, 0.525, 1.000>  226.892
   23376     <0.385, 0.519, 1.000>  226.952
   24735     <0.379, 0.514, 1.000>  227.010
   26182     <0.373, 0.508, 1.000>  227.066
   27723     <0.368, 0.504, 1.000>  227.120
   29364     <0.363, 0.499, 1.000>  227.171
   31112     <0.359, 0.495, 1.000>  227.219
   32975     <0.354, 0.491, 1.000>  227.266
   34960     <0.351, 0.488, 1.000>  227.310
   37078     <0.347, 0.485, 1.000>  227.351
   39336     <0.344, 0.482, 1.000>  227.391
   41746     <0.341, 0.479, 1.000>  227.428
   44319     <0.338, 0.476, 1.000>  227.463
   47066     <0.335, 0.474, 1.000>  227.496
   50000     <0.332, 0.471, 1.000>  227.528


Post a reply to this message


Attachments:
Download 'blackbodies.png' (260 KB)

Preview of image 'blackbodies.png'
blackbodies.png


 

From: "Jérôme M. Berger"
Subject: Re: Unexpected black body colors from CIE.inc
Date: 10 Oct 2011 14:12:44
Message: <4e93359c$1@news.povray.org>
Cousin Ricky wrote:
> I used CIE.inc from LightsysIV to display black body colors at various
> temperatures.  As the temperature increased, I expected the color to be
come
> yellower before it turned white.  Instead, I could not discern any chan
ge in
> hue.
> 
> I figured that the change in hue might be too subtle for me to detect, 
so I
> #debugged the hues.  Too my surprise, after becoming slightly yellower,
 the hue
> doubled back on itself and got redder, then onto magenta, violet, and b
lue.
> 
> Is this right?  If so, why do candle flames (glowing soot particles) lo
ok
> yellower than glowing coals?  Could it be a whitepoint issue?  Floating
 point
> accuracy?  That warning that splines are an experimental feature?
> 
> The attached image shows my results, with a fully-saturated swatch to t
he lower
> right of each sample.
> _______________________________________________________________________
_________
> 
	Looks right to me, the color goes from red (cool) to blue (hot),
going through yellow and magenta:
http://en.wikipedia.org/wiki/File:PlanckianLocus.png (the magenta
appears white on this image).

		Jerome
-- 
mailto:jeb### [at] freefr
http://jeberger.free.fr
Jabber: jeb### [at] jabberfr


Post a reply to this message


Attachments:
Download 'us-ascii' (1 KB)

From: Ive
Subject: Re: Unexpected black body colors from CIE.inc
Date: 10 Oct 2011 18:14:08
Message: <4e936e30$1@news.povray.org>
Am 10.10.2011 19:23, schrieb Cousin Ricky:
> I used CIE.inc from LightsysIV to display black body colors at various
> temperatures.  As the temperature increased, I expected the color to become
> yellower before it turned white.  Instead, I could not discern any change in
> hue.
>
> I figured that the change in hue might be too subtle for me to detect, so I
> #debugged the hues.  Too my surprise, after becoming slightly yellower, the hue
> doubled back on itself and got redder, then onto magenta, violet, and blue.
>
> Is this right?

Yes.

> If so, why do candle flames (glowing soot particles) look
> yellower than glowing coals?

Because the flame of a candle is far away from being a perfect blackbody 
radiator.


> Could it be a whitepoint issue?

As the whitepoint of sRGB (the default color order system from CIE.inc) 

this temperature. And only *close* because the sRGB whitepoint is 
defined as a D-illuminant (and is implemented as the Daylight macro 
within CIE.inc) and this is not quite identical to blackbody.


> Floating point
> accuracy?  That warning that splines are an experimental feature?
>
> The attached image shows my results, with a fully-saturated swatch to the lower
> right of each sample.

Looks good to me.
-Ive


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.