Class ISpectralDataExtensions
Extensions for the ISpectralData interface
Inherited Members
Namespace: NixUniversalSDK
Assembly: NixUniversalSDK.dll
Syntax
public static class ISpectralDataExtensions
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.
Declaration
public static IColorData ToColorData(this ISpectralData data, Illuminant illuminant = Illuminant.D50, Observer observer = Observer.CIE1931, ColorType type = ColorType.CIEXYZ)
Parameters
| Type | Name | Description |
|---|---|---|
| ISpectralData | data | This spectral data instance |
| Illuminant | illuminant | Selected illuminant reference for output (defaults to D50) |
| Observer | observer | Selected observer reference for output (defaults to CIE1931) |
| ColorType | type | Output color type (defaults to CIEXYZ) |
Returns
| Type | Description |
|---|---|
| IColorData | Color data, or |
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?).
Declaration
public static IDensityData ToDensityData(this ISpectralData data, DensityStatus status = DensityStatus.T)
Parameters
| Type | Name | Description |
|---|---|---|
| ISpectralData | data | This spectral data instance |
| DensityStatus | status | Density status (defaults to T) |
Returns
| Type | Description |
|---|---|
| IDensityData |
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.
Declaration
public static byte[] ToRgbValue(this ISpectralData data, Illuminant illuminant = Illuminant.D50, Observer observer = Observer.CIE1931)
Parameters
| Type | Name | Description |
|---|---|---|
| ISpectralData | data | This spectral data instance |
| Illuminant | illuminant | Selected illuminant reference for output (defaults to D50) |
| Observer | observer | Selected observer reference for output (defaults to CIE1931) |
Returns
| Type | Description |
|---|---|
| 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.
Declaration
public static byte[] ToRgbValue(this ISpectralData data, ReferenceWhite reference = ReferenceWhite.D50_2)
Parameters
| Type | Name | Description |
|---|---|---|
| ISpectralData | data | This spectral data instance |
| ReferenceWhite | reference | Selected reference white (defaults to D50_2) |
Returns
| Type | Description |
|---|---|
| byte[] | sRGB value |