|
|
@ -565,25 +565,25 @@ impl CanvasState {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// Text
|
|
|
|
// Text
|
|
|
|
let mut shader = self.text_buffers.get(
|
|
|
|
// let mut shader = self.text_buffers.get(
|
|
|
|
self.get_shader_handle(String::from("simple_text"))
|
|
|
|
// self.get_shader_handle(String::from("simple_text"))
|
|
|
|
.unwrap().clone().handle as usize
|
|
|
|
// .unwrap().clone().handle as usize
|
|
|
|
).unwrap();
|
|
|
|
// ).unwrap();
|
|
|
|
|
|
|
|
|
|
|
|
if !self.text_vertex_buffer.is_empty() {
|
|
|
|
// if !self.text_vertex_buffer.is_empty() {
|
|
|
|
for (text_handle, vertex_buffer) in self.text_vertex_buffer.clone() {
|
|
|
|
// for (text_handle, vertex_buffer) in self.text_vertex_buffer.clone() {
|
|
|
|
let handle = texture_handle.clone().handle as usize;
|
|
|
|
// let handle = text_handle.clone().handle as usize;
|
|
|
|
let descriptor_set = self.text_buffers.get(handle).clone().unwrap().clone()
|
|
|
|
// let descriptor_set = self.text_buffers.get(handle).clone().unwrap().clone()
|
|
|
|
.get_descriptor_set(shader.get_pipeline(), self.sampler.clone());
|
|
|
|
// .get_descriptor_set(shader.get_pipeline(), self.sampler.clone());
|
|
|
|
|
|
|
|
//
|
|
|
|
command_buffer = command_buffer.draw(
|
|
|
|
// command_buffer = command_buffer.draw(
|
|
|
|
shader.get_pipeline().clone(),
|
|
|
|
// shader.get_pipeline().clone(),
|
|
|
|
// Multiple vertex buffers must have their definition in the pipeline!
|
|
|
|
// // Multiple vertex buffers must have their definition in the pipeline!
|
|
|
|
&self.dynamic_state.clone(), vec![vertex_buffer],
|
|
|
|
// &self.dynamic_state.clone(), vec![vertex_buffer],
|
|
|
|
vec![descriptor_set], (),
|
|
|
|
// vec![descriptor_set], (),
|
|
|
|
).unwrap();
|
|
|
|
// ).unwrap();
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
}
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
|
|
command_buffer
|
|
|
|
command_buffer
|
|
|
|
.end_render_pass()
|
|
|
|
.end_render_pass()
|
|
|
|