PistonDevelopers / conrod

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

Setting background transparency with glium backend #1305

Open stevensonmt opened 4 years ago

stevensonmt commented 4 years ago

I'm trying to set the background of the list_select example to a transparent color. On lines 112 - 114 I have

widget::Canvas::new()
  .color(conrod_core::color::TRANSPARENT)
  .set(ids.canvas, ui);

The background remains opaque, however. What is the correct way for setting the background alpha?

mitchmindtree commented 4 years ago

You may also need to build the glutin window with the .with_transparency(true) method so that the window does not have an opaque background (which I believe is the default).

stevensonmt commented 4 years ago

That gives me an error. No pixel format available.

I'm using X11 on Manjaro Linux with OpenGL version 3.0 Mesa 19.1.3. Getting the glium::glutin::GL_CORE for the app returns Specific(OpenGl, (3, 2)). Not sure if that is relevant.