+ /// Opens the first device that succeeds and returns its `Display`.
+ ///
+ /// The only difference from ordinary `open` is that it does not print debug information
+ /// about libva version and opened driver.
+ ///
+ /// If an error occurs on a given device, it is ignored and the next one is tried until one
+ /// succeeds or we reach the end of the iterator.
+ pub fn open_silently() -> Option<Rc<Self>> {
+ let devices = DrmDeviceIterator::default();
+
+ // Try all the DRM devices until one succeeds.
+ for device in devices {
+ if let Ok(display) = Self::open_drm_display_internal(device, true) {
+ return Some(display);
+ }
+ }
+
+ None
+ }
+