| MunsellToXYZ | R Documentation |
MunsellToXYZ Converts a
Munsell specification to XYZ coordinates, by interpolating over the
extrapolated Munsell renotation data.
Note that by default the returned XYZ is relative to the white point of Illuminant C.
Since Illuminant C is obsolete, it is almost certain that if this XYZ is used in subsequent
calculations, it must be chromatically adapted to a different white point.
But if the white point for subsequent calculations is supplied,
then the chromatic adaptation is done internally by
spacesXYZ::adaptXYZ().
MunsellToXYZ( MunsellSpec, white=NULL, adapt='Bradford', ... )
MunsellSpec |
a numeric Nx3 matrix with HVC values in the rows, or a vector that can be converted to such a matrix, by row. |
white |
XYZ for the output white point.
If |
adapt |
method for chromatic adaptation; for valid values see |
... |
other parameters passed to |
The conversion is done in these steps:
HVC \rarrow xyY using MunsellToxyY() and .... This xyY is for Illuminant C.
xyY \rarrow XYZ using spacesXYZ::XYZfromxyY()
If white is not NULL, XYZ is chromatically adapted from the white point of Illuminant C to the given white using the given adapt method.
an Nx3 matrix with XYZ values in the rows.
The rownames of XYZ are copied from the input HVC matrix,
unless the rownames are NULL and
then the output rownames are the Munsell notations for HVC.
Jose Gama and Glenn Davis
Paul Centore 2014 The Munsell and Kubelka-Munk Toolbox \MKMTB
MunsellToxyY(),
spacesXYZ::XYZfromxyY(),
spacesXYZ::adaptXYZ()
## make expected XYZ for a Perfect Reflecting Diffuser, under Illuminant D65
white.D65 = 100 * as.numeric( spacesXYZ::standardXYZ( 'D65' ) )
white.D65
## [1] 95.047 100.000 108.883
## convert Munsell 'N 10/' - the Perfect Reflecting Difuser - to XYZ
MunsellToXYZ( "N 10/" )
## X Y Z
## N 10/ 98.03984 100 118.1157
## this is the white point of Illuminant C, and not equal to white.D65
## Redo and supply the true white point.
MunsellToXYZ( "N 10/", white=white.D65 )
## X Y Z
## N 10/ 95.047 100 108.883
##
## now we have a match
MunsellToXYZ('7.6P 8.9/2.2')
## X Y Z
## 7.6P 8.9/2.2 75.6055 74.61345 92.92308
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.