Add a high-level function to get the supported additional signal
colorimetries. This is only an interesting sub-set of the CTA-861-H
defined colorimetries, for driving WCG and HDR displays.
Wayland compositors will be interested in this.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
The low-level struct di_cta_hdr_static_metadata_block is essentially
duplicated in struct di_hdr_static_metadata to make the high-level API
independent of low-level API headers. It's also simpler in form, while
new fields can still be added in the end while maintaining ABI backward
compatibility.
If new sources for HDR static metadata appear, they can be parsed into
this same structure in the future when compatible.
Wayland compositors will be interested in this.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
Add a high-level function to retrieve color primaries. Wayland
compositors will be interested in this.
A high-level function may later be extended to support stand-alone
DisplayID and other sources.
The high-level data is derived from low-level API calls in
di_info_parse_edid(). As we stash the results in struct di_info to avoid
requiring the callers to explicitly free the high-level structures, this
allows keeping struct di_info deeply const in high-level API
implementation. We also avoid some dynamic allocations.
https://github.com/linuxhw/EDID.git database contains 20399 samples for
which edid-decode complains:
Basic Display Parameters & Features: sRGB is signaled, but the chromaticities do not match.
Therefore I assume that the sRGB flag is more correct when set.
Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com>
This exposes a new di_info opaque struct from which high-level
information will be able to be queried by the user. A new
di_info_parse_edid function creates a di_info from an EDID blob.
Signed-off-by: Simon Ser <contact@emersion.fr>