mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-24 02:31:03 +00:00
video-color: Add compile-time assert for ColorimetryInfo enum
A comment is not sufficient because this will break when cherry-picking or backporting commits.
This commit is contained in:
parent
fb842a3fdb
commit
12d534bada
1 changed files with 4 additions and 0 deletions
|
@ -80,6 +80,10 @@ static const ColorimetryInfo colorimetry[] = {
|
|||
MAKE_COLORIMETRY (NONAME, _UNKNOWN, UNKNOWN, UNKNOWN, UNKNOWN),
|
||||
};
|
||||
|
||||
/* Ensure that DEFAULT_UNKNOWN is indeed updated */
|
||||
G_STATIC_ASSERT (sizeof (colorimetry) ==
|
||||
(sizeof (gchar *) + sizeof (GstVideoColorimetry)) * (DEFAULT_UNKNOWN + 1));
|
||||
|
||||
static const ColorimetryInfo *
|
||||
gst_video_get_colorimetry (const gchar * s)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue