From 0e72f073e16532126df89437a222082e64fef398 Mon Sep 17 00:00:00 2001 From: Carter Anderson Date: Tue, 14 Jan 2020 18:57:10 -0800 Subject: [PATCH] move swap_chain and device initialization to render_graph --- CREDITS.md | 11 +++++ src/app/app.rs | 57 +++--------------------- src/app/app_builder.rs | 24 +++++++++- src/render/render_graph/mod.rs | 80 ++++++++++++++++++++++++---------- 4 files changed, 98 insertions(+), 74 deletions(-) create mode 100644 CREDITS.md diff --git a/CREDITS.md b/CREDITS.md new file mode 100644 index 0000000000..3a286f4234 --- /dev/null +++ b/CREDITS.md @@ -0,0 +1,11 @@ +# Bevy Credits + +## Adapted Code + +* legion_transform +* wgpu-rs examples + +## Insipration + +* amethyst +* coffee \ No newline at end of file diff --git a/src/app/app.rs b/src/app/app.rs index 6fcb8272df..f573237bab 100644 --- a/src/app/app.rs +++ b/src/app/app.rs @@ -11,7 +11,6 @@ use crate::{render::*, core::Time}; pub struct App { pub world: World, pub render_graph: RenderGraph, - pub swap_chain: Option, pub schedule: Schedule, } @@ -21,7 +20,6 @@ impl App { world, schedule: schedule, render_graph, - swap_chain: None, } } @@ -30,73 +28,30 @@ impl App { time.start(); } self.schedule.execute(&mut self.world); - self.render(); + self.render_graph.render(&mut self.world); if let Some(mut time) = self.world.resources.get_mut::