INNER CODE UNIT · Rust
y
attackgoat/vk-graph · crates/vk-graph-egui/src/lib.rs:284
let y = (clip_rect.min.y * pixels_per_point) as i32;
let width = ((clip_rect.max.x - clip_rect.min.x) * pixels_per_point) as u32;
let height = ((clip_rect.max.y - clip_rect.min.y) * pixels_per_point) as u32;
graph
.begin_cmd()
.debug_name("Egui pass")
.bind_pipeline(&self.ppl)
.resource_access(idx_buf, AccessType::IndexBuffer)
.resource_access(vert_buf, AccessType::VertexBuffer)
.shader_resource_access(0, *texture, AccessType::FragmentShaderReadOther)
.color_attachment_image(0, target, LoadOp::Load, StoreOp::Store)
.record_cmd(move |cmd| {
cmd.bind_index_buffer(idx_buf, 0, vk::IndexType::UINT32)
.bind_vertex_buffer(0, vert_buf, 0)
.push_constants(0, cast_slice(&[push_constants]))
.set_scissor(