PistonDevelopers / conrod

An easy-to-use, 2D GUI library written entirely in Rust.
Other
3.35k stars 297 forks source link

Conrod on Beaglebone Black or other SBC? #997

Open adamski opened 7 years ago

adamski commented 7 years ago

I'm researching possibilities for an upcoming embedded+touchscreen GUI project, and I'd like to use Rust. (I currently use the JUCE C++ library to build applications.) Conrod seems like a great GUI library. I'm just wondering if anyone's had any luck getting it going on an SBC. I saw there were some issues with the Raspberry Pi, concerning OpenGL versions. AFAICS the BBB supports OpenGL ES 2.0.

Any tips much appreciated.

tl8roy commented 7 years ago

We are successfully running Conrod in (future) production on a Raspberry Pi Compute Module 3 (And a newer spec Pi 2 and by association, a Pi 3).

With the OpenGL driver we get a fast and responsive program.

This is the window builder that I use.

let monitor = glium::glutin::get_primary_monitor();
display = glium::glutin::WindowBuilder::new()
    .with_vsync()
    .with_fullscreen(monitor)
    .with_multitouch()
    .with_srgb(Some(false))
    .with_gl(glium::glutin::GlRequest::Specific(glium::glutin::Api::OpenGl,(2,1)))
    .build_glium()
    .expect("Failed to start the display");

There is a small issue with the colour space being SRGB rather than RGB, but that is solvable.

We are working on better touchscreen feedback, but in general touchscreen works.

Let me know if you need any more info.