rust-windowing / glutin

A low-level library for OpenGL context creation
Apache License 2.0
2k stars 477 forks source link

Fullscreen support on ARM Linux (Ubuntu) #829

Closed tl8roy closed 6 years ago

tl8roy commented 7 years ago

I am using Conrod with the Glium/Glutin backend.

When I run in Windows, the fullscreen mode works fine. When I try in Linux, I get the following backtrace:

gumstix@ubuntu:~$ RUST_BACKTRACE=1 ./proto_one
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: BackendCreationError(OsError("Could not find a suitable graphics mode"))', /buildslave/rust-buildbot/slave/stable-dist-rustc-cross-host-linux/build/src/libcore/result.rs:799
stack backtrace:
   1: 0xb6e6aa1b - std::sys::backtrace::tracing::imp::write::hd28a1f8221c946e5
   2: 0xb6e6f2ab - std::panicking::default_hook::{{closure}}::hcb904beb56706ec8
   3: 0xb6e6de7f - std::panicking::default_hook::hd59cb475a55dc643
   4: 0xb6e6e58f - std::panicking::rust_panic_with_hook::hea2bde53d708eb9a
   5: 0xb6e6e447 - std::panicking::begin_panic::hc4949303f890336e
   6: 0xb6e6e383 - std::panicking::begin_panic_fmt::he756d57ad1c1864c
   7: 0xb6e6e317 - rust_begin_unwind
   8: 0xb6e8d9b3 - core::panicking::panic_fmt::ha615cb8b8c64841b
   9: 0xb6805a9f - core::result::unwrap_failed::h888690e97d223775
                at /buildslave/rust-buildbot/slave/stable-dist-rustc-cross-host-linux/build/src/libcore/macros.rs:29
  10: 0xb67ecee7 - <core::result::Result<T, E>>::unwrap::hb50183d1be6a0d7b
                at /buildslave/rust-buildbot/slave/stable-dist-rustc-cross-host-linux/build/src/libcore/result.rs:737
  11: 0xb688ce1f - proto_one::main::h2a6de000b5d22706
                at /home/tlostroh/blu/proto_one/src/main.rs:49
  12: 0xb6e7322f - __rust_maybe_catch_panic
  13: 0xb6e6d5bf - std::rt::lang_start::hcb77440d8735d978
  14: 0xb689d74f - main
  15: 0xb65ec8a9 - __libc_start_main

This is the code used to build the window: // Build the window. let monitor = glium::glutin::get_primary_monitor(); let display = glium::glutin::WindowBuilder::new() .with_vsync() .with_dimensions(WIDTH, HEIGHT) .with_fullscreen(monitor) .with_decorations(false) .with_srgb(Some(false)) .with_title("Conrod with glium!") .build_glium() .unwrap();

Removing .with_dimensions(WIDTH, HEIGHT) appears to solve the issue.

icefoxen commented 7 years ago

Is the width and height you request a fullscreen resolution supported by your driver?

tl8roy commented 7 years ago

I has been a while since I checked this, but that certainly seems like it could be the problem.

We were having resolution issues, so I may have spec on higher than the screen can take.

francesca64 commented 6 years ago

This issue has likely been fixed via tomaka/winit#270.