POV-Ray : Newsgroups : povray.off-topic : Spectral locus Server Time
28 Jun 2024 23:07:47 EDT (-0400)
  Spectral locus (Message 11 to 20 of 25)  
<<< Previous 10 Messages Goto Latest 10 Messages Next 5 Messages >>>
From: Mike Horvath
Subject: Re: Spectral locus
Date: 13 Mar 2017 15:12:33
Message: <58c6ef21$1@news.povray.org>
On 3/13/2017 3:06 PM, Mike Horvath wrote:
> So, I want to plot this locus.
>
> This site says it has 4400 data points.
>
> "This data set gives wavelengths every 1.0 nm, along with the associated
> CIE xyz values for the spectral locus of the 1931 CIE chromaticity
> diagram. They are called xyz values here as they are called that in the
> original source, but they are also known as xyY or XYZ values."
>
> https://rdrr.io/cran/SpecHelpers/man/CIExyz.html
>
> I can't figure out how to download them from that site, however. Is
> there another source I can get them from?
>
> Also, I'm guessing the data set will allow me to plot a bunch of points,
> which is great. But how do I create a smooth surface from those points?
>
> Thanks!
>
>
> Mike

I'm also assuming the data set will produce a 3D shape. Is that right?


Mike


Post a reply to this message

From: clipka
Subject: Re: Spectral locus
Date: 13 Mar 2017 16:23:31
Message: <58c6ffc3$1@news.povray.org>
Am 13.03.2017 um 20:09 schrieb Mike Horvath:
> Translator needed:
> 
> https://en.wikipedia.org/wiki/Talk:Lab_color_space#CIELAB_images_in_article
> 
> The guy I'm talking to here is German, and I don't understand what he's
> talking about. Would someone care to translate for me? Thanks.

Unfortunately he's trying to write English, so I'd have to guess as well
-- even though I'm also German.

BTW, his use of the word "remission" actually seems to be closer to the
English use than to the German one:

https://en.wikipedia.org/wiki/Remission_(spectroscopy)

Whereas (according to Wikipedia) the English spectroscopy term
encompasses both diffuse /and/ specular reflection, the corresponding
German term ("Remission") seems to refer only to the diffuse component.


Post a reply to this message

From: clipka
Subject: Re: Spectral locus
Date: 13 Mar 2017 16:50:51
Message: <58c7062b$1@news.povray.org>
Am 13.03.2017 um 20:06 schrieb Mike Horvath:
> So, I want to plot this locus.
> 
> This site says it has 4400 data points.
> 
> "This data set gives wavelengths every 1.0 nm, along with the associated
> CIE xyz values for the spectral locus of the 1931 CIE chromaticity
> diagram. They are called xyz values here as they are called that in the
> original source, but they are also known as xyY or XYZ values."
> 
> https://rdrr.io/cran/SpecHelpers/man/CIExyz.html
> 
> I can't figure out how to download them from that site, however.

To me this looks like the /documentation/ of some spectroscopy-related
maths package (which inevitably needs to include data tables like this one).

> Is there another source I can get them from?

You could get the CIE XYZ tristimulus data directly from the
International Commission on Illumination, aka Commission Internationale
de l'Eclairage, aka CIE, and compute xyY data from them "on the fly":

http://www.cie.co.at/

see the "Downloads" section, most notably "Selected Colorimetric Tables".


There's also the Colour & Vision Research Laboratory, which has an
extensive set of colorimetric data tables for download in various formats:

http://cvrl.ioo.ucl.ac.uk/


> Also, I'm guessing the data set will allow me to plot a bunch of points,
> which is great. But how do I create a smooth surface from those points?

Iterate over them to generate a mesh?


Post a reply to this message

From: clipka
Subject: Re: Spectral locus
Date: 13 Mar 2017 17:19:47
Message: <58c70cf3$1@news.povray.org>
Am 13.03.2017 um 20:12 schrieb Mike Horvath:

>> "This data set gives wavelengths every 1.0 nm, along with the associated
>> CIE xyz values for the spectral locus of the 1931 CIE chromaticity
>> diagram. They are called xyz values here as they are called that in the
>> original source, but they are also known as xyY or XYZ values."
...
> I'm also assuming the data set will produce a 3D shape. Is that right?

Not really.

What the data set will give you (if you connect the dots) is a line in
2D space, namely the famous CIE "horseshoe".

To get a 3D shape from that, you'll first have to identify what you
really want to plot.

For example, the entire CIExyY colour space would be just an extrusion
of that horseshoe along the Y axis, stretching to positive infinity, as
there is no theoretical limit on brightness (for practical purposes at
any rate): The extruded horseshoe itself would represent the locus of
all theoretically possible monochromatic colours (i.e. colours comprised
of only a single wavelength of light), while the volume it encompasses
would represent the locus of all theoretically possible polychromatic
colours.


On the other hand, the locus of all theoretially possible pigment
colours as illuminated by a particular light source is a much more
complex construct, and creating its shape requires some smart ideas, as
the volume of that shape is effectively a projection from
infinite-dimensional space (each dimension corresponding to the
pigment's reflectivity at a particular wavelength) to 3-dimensional
CIExyY space.

That locus may even differ between light sources with identical CIExyY
whitepoint coordinates, as it depends on the spectrum of the light
source, and different spectra may still result in identical CIExyY
coordinates (see "metamerism").

This is precisely the project for which I did a series of animations a
while ago.


Post a reply to this message

From: Mike Horvath
Subject: Re: Spectral locus
Date: 13 Mar 2017 17:57:38
Message: <58c715d2$1@news.povray.org>
On 3/13/2017 5:19 PM, clipka wrote:
> Am 13.03.2017 um 20:12 schrieb Mike Horvath:
>
>>> "This data set gives wavelengths every 1.0 nm, along with the associated
>>> CIE xyz values for the spectral locus of the 1931 CIE chromaticity
>>> diagram. They are called xyz values here as they are called that in the
>>> original source, but they are also known as xyY or XYZ values."
> ...
>> I'm also assuming the data set will produce a 3D shape. Is that right?
>
> Not really.
>
> What the data set will give you (if you connect the dots) is a line in
> 2D space, namely the famous CIE "horseshoe".
>
> To get a 3D shape from that, you'll first have to identify what you
> really want to plot.
>
> For example, the entire CIExyY colour space would be just an extrusion
> of that horseshoe along the Y axis, stretching to positive infinity, as
> there is no theoretical limit on brightness (for practical purposes at
> any rate): The extruded horseshoe itself would represent the locus of
> all theoretically possible monochromatic colours (i.e. colours comprised
> of only a single wavelength of light), while the volume it encompasses
> would represent the locus of all theoretically possible polychromatic
> colours.
>
>
> On the other hand, the locus of all theoretially possible pigment
> colours as illuminated by a particular light source is a much more
> complex construct, and creating its shape requires some smart ideas, as
> the volume of that shape is effectively a projection from
> infinite-dimensional space (each dimension corresponding to the
> pigment's reflectivity at a particular wavelength) to 3-dimensional
> CIExyY space.
>
> That locus may even differ between light sources with identical CIExyY
> whitepoint coordinates, as it depends on the spectrum of the light
> source, and different spectra may still result in identical CIExyY
> coordinates (see "metamerism").
>
> This is precisely the project for which I did a series of animations a
> while ago.
>

Yeah, I saw those animations and wanted to reproduce them. I figured 
that the white point would need to play a part in them, but didn't 
realize there were so many pitfalls.


Mike


Post a reply to this message

From: Mike Horvath
Subject: Re: Spectral locus
Date: 13 Mar 2017 20:00:02
Message: <58c73282$1@news.povray.org>
On 3/13/2017 5:19 PM, clipka wrote:
> Am 13.03.2017 um 20:12 schrieb Mike Horvath:
>
>>> "This data set gives wavelengths every 1.0 nm, along with the associated
>>> CIE xyz values for the spectral locus of the 1931 CIE chromaticity
>>> diagram. They are called xyz values here as they are called that in the
>>> original source, but they are also known as xyY or XYZ values."
> ...
>> I'm also assuming the data set will produce a 3D shape. Is that right?
>
> Not really.
>
> What the data set will give you (if you connect the dots) is a line in
> 2D space, namely the famous CIE "horseshoe".
>
> To get a 3D shape from that, you'll first have to identify what you
> really want to plot.
>
> For example, the entire CIExyY colour space would be just an extrusion
> of that horseshoe along the Y axis, stretching to positive infinity, as
> there is no theoretical limit on brightness (for practical purposes at
> any rate): The extruded horseshoe itself would represent the locus of
> all theoretically possible monochromatic colours (i.e. colours comprised
> of only a single wavelength of light), while the volume it encompasses
> would represent the locus of all theoretically possible polychromatic
> colours.
>
>
> On the other hand, the locus of all theoretially possible pigment
> colours as illuminated by a particular light source is a much more
> complex construct, and creating its shape requires some smart ideas, as
> the volume of that shape is effectively a projection from
> infinite-dimensional space (each dimension corresponding to the
> pigment's reflectivity at a particular wavelength) to 3-dimensional
> CIExyY space.
>
> That locus may even differ between light sources with identical CIExyY
> whitepoint coordinates, as it depends on the spectrum of the light
> source, and different spectra may still result in identical CIExyY
> coordinates (see "metamerism").
>
> This is precisely the project for which I did a series of animations a
> while ago.
>


Are things as simple as using these formulas?

http://www.brucelindbloom.com/index.html?Eqn_Spect_to_XYZ.html

I forgot how to do calculus integrals and sums, but if I'm on the right 
track I can try to re-learn.


Mike


Post a reply to this message

From: dick balaska
Subject: Re: Spectral locus
Date: 13 Mar 2017 23:06:53
Message: <58c75e4d$1@news.povray.org>
Am 2017-03-13 12:30, also sprach clipka:
> Am 13.03.2017 um 11:17 schrieb Mr:
>
>>> But remember that I have to take my socks off to count past 10. :)
>>
>> :-D !
>> I thought POVers used only binary ?
>
> Why, no, of course they don't. POV-Ray only deals in floating-point
> numbers, not binary integers ;)
>

That's right. Even boolean is 64 bits and has a mantissa!
true == 3ff0 0000 0000 0000
:)

-- 
dik


Post a reply to this message

From: clipka
Subject: Re: Spectral locus
Date: 14 Mar 2017 04:23:40
Message: <58c7a88c$1@news.povray.org>
Am 14.03.2017 um 01:00 schrieb Mike Horvath:

>> On the other hand, the locus of all theoretially possible pigment
>> colours as illuminated by a particular light source is a much more
>> complex construct, and creating its shape requires some smart ideas, as
>> the volume of that shape is effectively a projection from
>> infinite-dimensional space (each dimension corresponding to the
>> pigment's reflectivity at a particular wavelength) to 3-dimensional
>> CIExyY space.
>>
>> That locus may even differ between light sources with identical CIExyY
>> whitepoint coordinates, as it depends on the spectrum of the light
>> source, and different spectra may still result in identical CIExyY
>> coordinates (see "metamerism").
>>
>> This is precisely the project for which I did a series of animations a
>> while ago.
>>
> 
> 
> Are things as simple as using these formulas?
> 
> http://www.brucelindbloom.com/index.html?Eqn_Spect_to_XYZ.html
> 
> I forgot how to do calculus integrals and sums, but if I'm on the right
> track I can try to re-learn.

As the page already mentions, in practice you'll be doing sums rather
than integrals.

For an equal-energy(*) light source (emitting all wavelengths at the
same intensity), the "compute CIE XYZ coordinates for this particular
spectrum" is indeed that simple.

(* Actually, "equal-power" would be a more fitting term, but
"equal-energy" has stuck.)

For any other light source, the terms in the sum get just a little more
complicated, as you have to multiply them with a factor representing the
light source's emissive power at that corresponding wavelength.

Remember to convert from XYZ to xyY afterwards, using x=X/(X+Y+Z),
y=Y/(X+Y+Z).


The tricky part, at least for me, was to figure out what spectra would
end up on the surface of the resulting shape, and how to connect them
into a mesh.


Post a reply to this message

From: Mike Horvath
Subject: Re: Spectral locus
Date: 14 Mar 2017 16:18:24
Message: <58c85010$1@news.povray.org>
On 3/13/2017 4:23 PM, clipka wrote:
> Am 13.03.2017 um 20:09 schrieb Mike Horvath:
>> Translator needed:
>>
>> https://en.wikipedia.org/wiki/Talk:Lab_color_space#CIELAB_images_in_article
>>
>> The guy I'm talking to here is German, and I don't understand what he's
>> talking about. Would someone care to translate for me? Thanks.
>
> Unfortunately he's trying to write English, so I'd have to guess as well
> -- even though I'm also German.
>
> BTW, his use of the word "remission" actually seems to be closer to the
> English use than to the German one:
>
> https://en.wikipedia.org/wiki/Remission_(spectroscopy)
>
> Whereas (according to Wikipedia) the English spectroscopy term
> encompasses both diffuse /and/ specular reflection, the corresponding
> German term ("Remission") seems to refer only to the diffuse component.
>

Do you have an idea what those images are supposed to show? Is it the 
spectral locus? I've only plotted the sRGB gamut so far (which is shaped 
like a skewed cube), not the spectral locus.


Mike


Post a reply to this message

From: clipka
Subject: Re: Spectral locus
Date: 15 Mar 2017 07:27:06
Message: <58c9250a$1@news.povray.org>
Am 14.03.2017 um 21:18 schrieb Mike Horvath:

> Do you have an idea what those images are supposed to show? Is it the
> spectral locus? I've only plotted the sRGB gamut so far (which is shaped
> like a skewed cube), not the spectral locus.

Before I can answer that question, we may have to first agree on a
definition of "spectral locus".

According to my understanding of the Wikipedia article on "spectral
color", the "spectral locus" would be the locus of all monochromatic
colours, i.e. colours comprised of only a single wavelength.

In a 2D chromaticity space (a "colour" space that does not care about
absolute brightness) such as CIE xy, that would be the famous "horseshoe".

In a 3D colour space, it would be an extrusion of that horseshoe, traced
on an arbitrary locus of equal brightness in that colour space, extruded
along paths of constant chromaticity, up to the locus of zero brightness
in one direction and up to the locus of infinite brightness, in the other.

For example, in CIE xyY colour space it would be a "cylinder-ish" shape
(having a cross-section identical with the familiar CIE horseshoe
shape), oriented along the L axis, starting at L=0 and extending to
infinity.

On the other hand, in an RGB colour space it would instead be a
"cone-ish" shape (with a cross-section also reminiscient of the CIE
horseshoe, albeit possibly distorted depending on the angle at which you
cut), encompassing the positive legs of all colour axes, with its apex
at R=G=B=0 and extending to infinity.


According to that definition, the images are clearly /not/ supposed to
show the spectral locus.


Instead, from what the other guy is writing, it is my understanding that
the images are /supposed/ to show the locus (or rather, selected points
from that locus' boundary) of all possible /pigment colours/, under a
poorly defined illuminant (from the description my guesses would be E,
the equal-energy illuminant), in CIE L*a*b colour space whith a poorly
defined whitepoint (my guess would be D65 or D50).

The side view looks reasonably convincing (I don't recall ever having
plotted this shape in CIE L*a*b space). Note that towards L=0 the locus
appears to converge to (*a,*b)=(0,0), which seems to agree with the
mathematical definition of the colour space.

The top view, on the other hand, has some features that make me
suspicious; but they might just be artefacts resulting from a different
scaling along the L axis than used for the side view, or I might be
seeing ghosts.


Post a reply to this message

<<< Previous 10 Messages Goto Latest 10 Messages Next 5 Messages >>>

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