libweston: publish eotf and colorimetry mode to string

Frontend wants to print these sometimes.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
This commit is contained in:
Pekka Paalanen 2024-06-04 13:44:47 +03:00
parent d26ab4360d
commit 98becedfcd
3 changed files with 10 additions and 10 deletions

View file

@ -278,6 +278,9 @@ enum weston_colorimetry_mode {
WESTON_COLORIMETRY_MODE_P3DCI | \
WESTON_COLORIMETRY_MODE_ICTCP))
const char *
weston_colorimetry_mode_to_str(enum weston_colorimetry_mode c);
/** EOTF mode for outputs and heads
*
* A list of EOTF modes for driving displays, defined by CTA-861-G for
@ -312,6 +315,9 @@ enum weston_eotf_mode {
((uint32_t)(WESTON_EOTF_MODE_SDR | WESTON_EOTF_MODE_TRADITIONAL_HDR | \
WESTON_EOTF_MODE_ST2084 | WESTON_EOTF_MODE_HLG))
const char *
weston_eotf_mode_to_str(enum weston_eotf_mode e);
/** CIE 1931 xy chromaticity coordinates */
struct weston_CIExy {
float x;

View file

@ -464,9 +464,9 @@ out_close:
return cprof;
}
/** Get a string naming the EOTF mode
/** Get a string naming the EOTF mode for logs
*
* \internal
* \return Static string. "???" for unknown mode.
*/
WL_EXPORT const char *
weston_eotf_mode_to_str(enum weston_eotf_mode e)
@ -536,9 +536,9 @@ weston_colorimetry_mode_info_get_by_wdrm(enum wdrm_colorspace cs)
return NULL;
}
/** Get a string naming the colorimetry mode
/** Get a string naming the colorimetry mode for logs
*
* \internal
* \return Static string. "???" for unknown mode.
*/
WL_EXPORT const char *
weston_colorimetry_mode_to_str(enum weston_colorimetry_mode c)

View file

@ -631,9 +631,6 @@ weston_color_manager_noop_create(struct weston_compositor *compositor);
struct weston_color_manager *
weston_color_manager_create(struct weston_compositor *compositor);
const char *
weston_eotf_mode_to_str(enum weston_eotf_mode e);
char *
weston_eotf_mask_to_str(uint32_t eotf_mask);
@ -654,9 +651,6 @@ weston_colorimetry_mode_info_get(enum weston_colorimetry_mode c);
const struct weston_colorimetry_mode_info *
weston_colorimetry_mode_info_get_by_wdrm(enum wdrm_colorspace cs);
const char *
weston_colorimetry_mode_to_str(enum weston_colorimetry_mode c);
char *
weston_colorimetry_mask_to_str(uint32_t colorimetry_mask);