Class ISpectralDataExtensions
- Namespace
- NixUniversalSDK
- Assembly
- NixUniversalSDK.dll
Extensions for the ISpectralData interface
public static class ISpectralDataExtensions
- Inheritance
-
ISpectralDataExtensions
- Inherited Members
Methods
ToColorData(ISpectralData, Illuminant, Observer, ColorType)
Provides color data from this measurement for the specified illuminant and observer white point. Result is null
if an invalid white point is specified.
public static IColorData ToColorData(this ISpectralData data, Illuminant illuminant = Illuminant.D50, Observer observer = Observer.CIE1931, ColorType type = ColorType.CIEXYZ)
Parameters
data
ISpectralDataThis spectral data instance
illuminant
IlluminantSelected illuminant reference for output (defaults to D50)
observer
ObserverSelected observer reference for output (defaults to CIE1931)
type
ColorTypeOutput color type (defaults to CIEXYZ)
Returns
- IColorData
Color data, or
null
if an invalid white point is specified
ToDensityData(ISpectralData, DensityStatus)
Provides absolute density values for this measurement for the specified density status evaluated as per ISO 5-3:2009, or null
if the SpectralData feature is not enabled for the current license. See also IsFeatureEnabled(LicenseFeature?).
public static IDensityData ToDensityData(this ISpectralData data, DensityStatus status = DensityStatus.T)
Parameters
data
ISpectralDataThis spectral data instance
status
DensityStatusDensity status (defaults to T)
Returns
ToRgbValue(ISpectralData, Illuminant, Observer)
Provides an sRGB value for this measurement for the specified illuminant and observer white point. Result is null
if the specified white point is not available for this measurement.
public static byte[] ToRgbValue(this ISpectralData data, Illuminant illuminant = Illuminant.D50, Observer observer = Observer.CIE1931)
Parameters
data
ISpectralDataThis spectral data instance
illuminant
IlluminantSelected illuminant reference for output (defaults to D50)
observer
ObserverSelected observer reference for output (defaults to CIE1931)
Returns
- byte[]
sRGB value
ToRgbValue(ISpectralData, ReferenceWhite)
Provides an sRGB value for this measurement for the specified illuminant and observer white point. Result is null
if the specified white point is not available for this measurement.
public static byte[] ToRgbValue(this ISpectralData data, ReferenceWhite reference = ReferenceWhite.D50_2)
Parameters
data
ISpectralDataThis spectral data instance
reference
ReferenceWhiteSelected reference white (defaults to D50_2)
Returns
- byte[]
sRGB value