pixix4 / ev3dev-lang-rust

Rust language bindings for http://ev3dev.org
MIT License
71 stars 14 forks source link

check if screen uses rgb mode #30

Open Natejoestev opened 6 months ago

Natejoestev commented 6 months ago

It would be nice to beable to have a check to see if the screen allows for RGB or B&W.

pixix4 commented 6 months ago

You can already do this with the framebuffer crate, that is used internally. With screen.buffer.var_screen_info.bits_per_pixel you get 1 for black and white and 16 or 32 for screens with color support. Does this work for your usecase?