diff options
author | Jan Beich <jbeich@FreeBSD.org> | 2023-04-22 15:36:06 +0300 |
---|---|---|
committer | Jan Beich <jbeich@FreeBSD.org> | 2023-04-22 15:58:29 +0300 |
commit | 8d6751c88d8a11680f89c232cef94ac918010871 (patch) | |
tree | f18170b51928e2d102ae76529ff7cf8b441c85f5 /video | |
parent | 8e4fd2c1678cd29641d2a085eb7b2edd28232184 (diff) |
gtk4: unbreak wayland, x11egl, x11glx features on non-Linux
As the features are non-default leave the responsibility to filter by
platform to consumers.
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1191>
Diffstat (limited to 'video')
-rw-r--r-- | video/gtk4/src/sink/imp.rs | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/video/gtk4/src/sink/imp.rs b/video/gtk4/src/sink/imp.rs index a9789d76e..a8b21e3ab 100644 --- a/video/gtk4/src/sink/imp.rs +++ b/video/gtk4/src/sink/imp.rs @@ -595,11 +595,11 @@ impl PaintableSink { }; match gdk_context.type_().name() { - #[cfg(all(target_os = "linux", feature = "x11egl"))] + #[cfg(feature = "x11egl")] "GdkX11GLContextEGL" => (), - #[cfg(all(target_os = "linux", feature = "x11glx"))] + #[cfg(feature = "x11glx")] "GdkX11GLContextGLX" => (), - #[cfg(all(target_os = "linux", feature = "wayland"))] + #[cfg(feature = "wayland")] "GdkWaylandGLContext" => (), #[cfg(target_os = "macos")] "GdkMacosGLContext" => (), @@ -621,11 +621,11 @@ impl PaintableSink { gdk_context.make_current(); let res = match gdk_context.type_().name() { - #[cfg(all(target_os = "linux", feature = "x11egl"))] + #[cfg(feature = "x11egl")] "GdkX11GLContextEGL" => self.initialize_x11egl(gdk_display), - #[cfg(all(target_os = "linux", feature = "x11glx"))] + #[cfg(feature = "x11glx")] "GdkX11GLContextGLX" => self.initialize_x11glx(gdk_display), - #[cfg(all(target_os = "linux", feature = "wayland"))] + #[cfg(feature = "wayland")] "GdkWaylandGLContext" => self.initialize_waylandegl(gdk_display), #[cfg(target_os = "macos")] "GdkMacosGLContext" => self.initialize_macosgl(gdk_display), @@ -675,7 +675,7 @@ impl PaintableSink { }; } - #[cfg(all(target_os = "linux", feature = "x11egl"))] + #[cfg(feature = "x11egl")] fn initialize_x11egl( &self, display: gdk::Display, @@ -725,7 +725,7 @@ impl PaintableSink { } } - #[cfg(all(target_os = "linux", feature = "x11glx"))] + #[cfg(feature = "x11glx")] fn initialize_x11glx( &self, display: gdk::Display, @@ -774,7 +774,7 @@ impl PaintableSink { } } - #[cfg(all(target_os = "linux", feature = "wayland"))] + #[cfg(feature = "wayland")] fn initialize_waylandegl( &self, display: gdk::Display, |