graphics: rewrite the DisplayControls to use a write-ack mechanism between the renderer and ui tasks
This commit is contained in:
@@ -82,8 +82,10 @@ async fn main(spawner: Spawner) {
|
||||
let mut surfaces = UiSurfacePool::default();
|
||||
let ui = Ui::new(&mut surfaces);
|
||||
|
||||
let display_controls = DisplayControls::default();
|
||||
let oled_controls = DisplayControls::default();
|
||||
static MAIN_DISPLAY_SWITCH: ConstStaticCell<DisplayControlResources> = ConstStaticCell::new(DisplayControlResources::new());
|
||||
static OLED_DISPLAY_SWITCH: ConstStaticCell<DisplayControlResources> = ConstStaticCell::new(DisplayControlResources::new());
|
||||
let display_controls = DisplayControls::new(MAIN_DISPLAY_SWITCH.take());
|
||||
let oled_controls = DisplayControls::new(OLED_DISPLAY_SWITCH.take());
|
||||
|
||||
let mut oled_surfaces = OledUiSurfacePool::default();
|
||||
let oled_uniforms = Default::default();
|
||||
|
||||
Reference in New Issue
Block a user