Function to access various colorimetry datasets.
◆ zsl_clr_illum_get()
Retrieves a pointer to the zsl_clr_illum_data for the specified illuminant.
- Parameters
-
obs | The standard observer associated with this #illum. |
illum | The illuminant whose data should be retrieved. |
data | Pointer to the pointer where the const zsl_clr_illum_data should be made accessible. |
- Returns
- 0 on normal execution, otherwise an appropriate error code.
Example
The following example shows how to use the pointer to a pointer mechnaism to access illuminant A data in an resource efficient manner.
void
get_illum(void)
{
int rc;
if (rc) {
return;
}
}
◆ zsl_clr_lef_get()
Retrieves a pointer to the zsl_clr_spd data for the specified CIE luminous efficiency function.
- Parameters
-
lef | The luminous efficiency func. whose data should be retrieved. |
data | Pointer to the pointer where the const zsl_clr_spd data should be made accessible. |
◆ zsl_clr_lef_lerp()
Interpolates a single value from the specified CIE luminous efficiency function using linear interpolation.
- Parameters
-
lef | The luminous efficiency function to use. |
nm | The wavelength to interpolate. |
val | Pointer to the interpolated value's placeholder. |
- Returns
- 0 on normal execution, otherwise an appropriate error code.
◆ zsl_clr_obs_get()
Retrieves a pointer to the zsl_clr_obs_data for the specified CIE standard observer model.
- Parameters
-
obs | The standard observer whose data should be retrieved. |
data | Pointer to the pointer where the const zsl_clr_obs_data should be made accessible. |
- Returns
- 0 on normal execution, otherwise an appropriate error code.
Example
The following example shows how to use the pointer to a pointer mechnaism to access standard 2 degree observer data in an resource efficient manner.
void
get_stdobs(void)
{
printf(
"obs: %s\n", obs->
name);
}
◆ zsl_clr_rgbccm_get()
Retrieves a pointer to a standard 3x3 XYZ to RGB color space correlation matrix.
- Parameters
-
ccm | The XYZ to RGB color space correlation matrix to retrieve. |
mtx | Pointer to the pointer where the const zsl_mtx data should be made accessible. |
- Returns
- 0 on normal execution, otherwise an appropriate error code.
int zsl_clr_illum_get(enum zsl_clr_obs obs, enum zsl_clr_illum illum, const struct zsl_clr_illum_data **data)
Retrieves a pointer to the zsl_clr_illum_data for the specified illuminant.
void zsl_clr_obs_get(enum zsl_clr_obs obs, const struct zsl_clr_obs_data **data)
Retrieves a pointer to the zsl_clr_obs_data for the specified CIE standard observer model.