recreate pipelines on csg update
This commit is contained in:
@@ -220,6 +220,7 @@ struct App {
|
|||||||
host_visible_allocator: Arc<Mutex<SubbufferAllocator>>,
|
host_visible_allocator: Arc<Mutex<SubbufferAllocator>>,
|
||||||
compute_visible_allocator: Arc<Mutex<SubbufferAllocator>>,
|
compute_visible_allocator: Arc<Mutex<SubbufferAllocator>>,
|
||||||
pipeline_cache: Arc<PipelineCache>,
|
pipeline_cache: Arc<PipelineCache>,
|
||||||
|
recreate_pipelines: bool,
|
||||||
draw_gui: bool,
|
draw_gui: bool,
|
||||||
gstate: GState,
|
gstate: GState,
|
||||||
csg_count: usize,
|
csg_count: usize,
|
||||||
@@ -754,6 +755,7 @@ impl App {
|
|||||||
aabb_allocator,
|
aabb_allocator,
|
||||||
pipeline_cache,
|
pipeline_cache,
|
||||||
csg_count: gstate.csg.len(),
|
csg_count: gstate.csg.len(),
|
||||||
|
recreate_pipelines: false,
|
||||||
draw_gui: true,
|
draw_gui: true,
|
||||||
gstate,
|
gstate,
|
||||||
previous_debug: PreviousDebug::default(),
|
previous_debug: PreviousDebug::default(),
|
||||||
@@ -1715,6 +1717,7 @@ impl App {
|
|||||||
} else {
|
} else {
|
||||||
self.gstate.csg[index as usize] = csg;
|
self.gstate.csg[index as usize] = csg;
|
||||||
}
|
}
|
||||||
|
self.recreate_pipelines = true;
|
||||||
},
|
},
|
||||||
WorkComplete::GetPushConstants(..) => {},
|
WorkComplete::GetPushConstants(..) => {},
|
||||||
WorkComplete::RecompilePipelines(..) => {},
|
WorkComplete::RecompilePipelines(..) => {},
|
||||||
@@ -2150,7 +2153,8 @@ impl App {
|
|||||||
self.gstate.new_csgs_needed -= 1;
|
self.gstate.new_csgs_needed -= 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
rcx.recreate_pipelines |= self.gstate.recreate_pipelines;
|
rcx.recreate_pipelines |= std::mem::take(&mut self.gstate.recreate_pipelines);
|
||||||
|
rcx.recreate_pipelines |= std::mem::take(&mut self.recreate_pipelines);
|
||||||
|
|
||||||
let mut push_constants = vec![
|
let mut push_constants = vec![
|
||||||
PushConstantData {
|
PushConstantData {
|
||||||
|
|||||||
Reference in New Issue
Block a user