From b0c04c6f7bf9864e07697dd9fefd231919bd2b02 Mon Sep 17 00:00:00 2001 From: Werner Date: Sat, 2 Apr 2022 18:01:13 -0300 Subject: [PATCH] Update Triangle.rs --- Examples/Triangle.rs | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/Examples/Triangle.rs b/Examples/Triangle.rs index 007e90d..672ea3d 100644 --- a/Examples/Triangle.rs +++ b/Examples/Triangle.rs @@ -100,23 +100,7 @@ impl State for Triangle { vertex: wgpu::VertexState { module: &shader_module, entry_point: "vs_main", - buffers: &[wgpu::VertexBufferLayout { - array_stride: std::mem::size_of::() - as wgpu::BufferAddress, - step_mode: wgpu::VertexStepMode::Vertex, - attributes: &[ - wgpu::VertexAttribute { - offset: 0, - shader_location: 0, - format: wgpu::VertexFormat::Float32x3, - }, - wgpu::VertexAttribute { - offset: std::mem::size_of::<[f32; 3]>() as wgpu::BufferAddress, - shader_location: 1, - format: wgpu::VertexFormat::Float32x3, - }, - ], - }], + buffers: &[wgpu_layout], }, fragment: Some(wgpu::FragmentState { module: &shader_module,