video: Use correct versions of primaries/transfer function enums

This commit is contained in:
Sebastian Dröge 2020-07-03 12:23:32 +03:00
parent 01eaf76b31
commit 2db7b8ebcc
2 changed files with 50 additions and 2 deletions

View file

@ -22,8 +22,6 @@ generate = [
"GstVideo.VideoFormatFlags", "GstVideo.VideoFormatFlags",
"GstVideo.VideoTileMode", "GstVideo.VideoTileMode",
"GstVideo.VideoColorMatrix", "GstVideo.VideoColorMatrix",
"GstVideo.VideoTransferFunction",
"GstVideo.VideoColorPrimaries",
"GstVideo.VideoMultiviewMode", "GstVideo.VideoMultiviewMode",
"GstVideo.VideoFieldOrder", "GstVideo.VideoFieldOrder",
"GstVideo.VideoMultiviewFramePacking", "GstVideo.VideoMultiviewFramePacking",
@ -481,3 +479,32 @@ status = "generate"
[[object.member]] [[object.member]]
name = "none" name = "none"
ignore = true ignore = true
[[object]]
name = "GstVideo.VideoTransferFunction"
status = "generate"
[[object.member]]
name = "bt2020_10"
version = "1.18"
[[object.member]]
name = "smpte2084"
version = "1.18"
[[object.member]]
name = "arib_std_b67"
version = "1.18"
[[object]]
name = "GstVideo.VideoColorPrimaries"
status = "generate"
[[object.member]]
name = "smptest428"
version = "1.16"
[[object.member]]
name = "smpterp431"
version = "1.16"
[[object.member]]
name = "smpteeg432"
version = "1.16"
[[object.member]]
name = "ebu3213"
version = "1.16"

View file

@ -462,9 +462,13 @@ pub enum VideoColorPrimaries {
Film, Film,
Bt2020, Bt2020,
Adobergb, Adobergb,
#[cfg(any(feature = "v1_16", feature = "dox"))]
Smptest428, Smptest428,
#[cfg(any(feature = "v1_16", feature = "dox"))]
Smpterp431, Smpterp431,
#[cfg(any(feature = "v1_16", feature = "dox"))]
Smpteeg432, Smpteeg432,
#[cfg(any(feature = "v1_16", feature = "dox"))]
Ebu3213, Ebu3213,
#[doc(hidden)] #[doc(hidden)]
__Unknown(i32), __Unknown(i32),
@ -485,9 +489,13 @@ impl ToGlib for VideoColorPrimaries {
VideoColorPrimaries::Film => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_FILM, VideoColorPrimaries::Film => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_FILM,
VideoColorPrimaries::Bt2020 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_BT2020, VideoColorPrimaries::Bt2020 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_BT2020,
VideoColorPrimaries::Adobergb => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_ADOBERGB, VideoColorPrimaries::Adobergb => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_ADOBERGB,
#[cfg(any(feature = "v1_16", feature = "dox"))]
VideoColorPrimaries::Smptest428 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_SMPTEST428, VideoColorPrimaries::Smptest428 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_SMPTEST428,
#[cfg(any(feature = "v1_16", feature = "dox"))]
VideoColorPrimaries::Smpterp431 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_SMPTERP431, VideoColorPrimaries::Smpterp431 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_SMPTERP431,
#[cfg(any(feature = "v1_16", feature = "dox"))]
VideoColorPrimaries::Smpteeg432 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_SMPTEEG432, VideoColorPrimaries::Smpteeg432 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_SMPTEEG432,
#[cfg(any(feature = "v1_16", feature = "dox"))]
VideoColorPrimaries::Ebu3213 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_EBU3213, VideoColorPrimaries::Ebu3213 => gst_video_sys::GST_VIDEO_COLOR_PRIMARIES_EBU3213,
VideoColorPrimaries::__Unknown(value) => value, VideoColorPrimaries::__Unknown(value) => value,
} }
@ -508,9 +516,13 @@ impl FromGlib<gst_video_sys::GstVideoColorPrimaries> for VideoColorPrimaries {
6 => VideoColorPrimaries::Film, 6 => VideoColorPrimaries::Film,
7 => VideoColorPrimaries::Bt2020, 7 => VideoColorPrimaries::Bt2020,
8 => VideoColorPrimaries::Adobergb, 8 => VideoColorPrimaries::Adobergb,
#[cfg(any(feature = "v1_16", feature = "dox"))]
9 => VideoColorPrimaries::Smptest428, 9 => VideoColorPrimaries::Smptest428,
#[cfg(any(feature = "v1_16", feature = "dox"))]
10 => VideoColorPrimaries::Smpterp431, 10 => VideoColorPrimaries::Smpterp431,
#[cfg(any(feature = "v1_16", feature = "dox"))]
11 => VideoColorPrimaries::Smpteeg432, 11 => VideoColorPrimaries::Smpteeg432,
#[cfg(any(feature = "v1_16", feature = "dox"))]
12 => VideoColorPrimaries::Ebu3213, 12 => VideoColorPrimaries::Ebu3213,
value => VideoColorPrimaries::__Unknown(value), value => VideoColorPrimaries::__Unknown(value),
} }
@ -1728,8 +1740,11 @@ pub enum VideoTransferFunction {
Log316, Log316,
Bt202012, Bt202012,
Adobergb, Adobergb,
#[cfg(any(feature = "v1_18", feature = "dox"))]
Bt202010, Bt202010,
#[cfg(any(feature = "v1_18", feature = "dox"))]
Smpte2084, Smpte2084,
#[cfg(any(feature = "v1_18", feature = "dox"))]
AribStdB67, AribStdB67,
#[doc(hidden)] #[doc(hidden)]
__Unknown(i32), __Unknown(i32),
@ -1754,8 +1769,11 @@ impl ToGlib for VideoTransferFunction {
VideoTransferFunction::Log316 => gst_video_sys::GST_VIDEO_TRANSFER_LOG316, VideoTransferFunction::Log316 => gst_video_sys::GST_VIDEO_TRANSFER_LOG316,
VideoTransferFunction::Bt202012 => gst_video_sys::GST_VIDEO_TRANSFER_BT2020_12, VideoTransferFunction::Bt202012 => gst_video_sys::GST_VIDEO_TRANSFER_BT2020_12,
VideoTransferFunction::Adobergb => gst_video_sys::GST_VIDEO_TRANSFER_ADOBERGB, VideoTransferFunction::Adobergb => gst_video_sys::GST_VIDEO_TRANSFER_ADOBERGB,
#[cfg(any(feature = "v1_18", feature = "dox"))]
VideoTransferFunction::Bt202010 => gst_video_sys::GST_VIDEO_TRANSFER_BT2020_10, VideoTransferFunction::Bt202010 => gst_video_sys::GST_VIDEO_TRANSFER_BT2020_10,
#[cfg(any(feature = "v1_18", feature = "dox"))]
VideoTransferFunction::Smpte2084 => gst_video_sys::GST_VIDEO_TRANSFER_SMPTE2084, VideoTransferFunction::Smpte2084 => gst_video_sys::GST_VIDEO_TRANSFER_SMPTE2084,
#[cfg(any(feature = "v1_18", feature = "dox"))]
VideoTransferFunction::AribStdB67 => gst_video_sys::GST_VIDEO_TRANSFER_ARIB_STD_B67, VideoTransferFunction::AribStdB67 => gst_video_sys::GST_VIDEO_TRANSFER_ARIB_STD_B67,
VideoTransferFunction::__Unknown(value) => value, VideoTransferFunction::__Unknown(value) => value,
} }
@ -1780,8 +1798,11 @@ impl FromGlib<gst_video_sys::GstVideoTransferFunction> for VideoTransferFunction
10 => VideoTransferFunction::Log316, 10 => VideoTransferFunction::Log316,
11 => VideoTransferFunction::Bt202012, 11 => VideoTransferFunction::Bt202012,
12 => VideoTransferFunction::Adobergb, 12 => VideoTransferFunction::Adobergb,
#[cfg(any(feature = "v1_18", feature = "dox"))]
13 => VideoTransferFunction::Bt202010, 13 => VideoTransferFunction::Bt202010,
#[cfg(any(feature = "v1_18", feature = "dox"))]
14 => VideoTransferFunction::Smpte2084, 14 => VideoTransferFunction::Smpte2084,
#[cfg(any(feature = "v1_18", feature = "dox"))]
15 => VideoTransferFunction::AribStdB67, 15 => VideoTransferFunction::AribStdB67,
value => VideoTransferFunction::__Unknown(value), value => VideoTransferFunction::__Unknown(value),
} }