summaryrefslogtreecommitdiffstats
path: root/examples/integration_wgpu/src/scene.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2022-07-08 19:31:45 +0200
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2022-07-08 19:31:45 +0200
commitfa55dff61db47197a961152285c6a6abfab0b217 (patch)
tree44904afb16a0cab9e22fce0d73a5616676cd426b /examples/integration_wgpu/src/scene.rs
parent1dd1a2f97fc747e15e12b5188dad6c41b0d052ea (diff)
parent66eb6263003c1bbedd1fd14d6b12f172d20a6211 (diff)
downloadiced-fa55dff61db47197a961152285c6a6abfab0b217.tar.gz
iced-fa55dff61db47197a961152285c6a6abfab0b217.tar.bz2
iced-fa55dff61db47197a961152285c6a6abfab0b217.zip
Merge branch 'master' into theming
Diffstat (limited to 'examples/integration_wgpu/src/scene.rs')
-rw-r--r--examples/integration_wgpu/src/scene.rs12
1 files changed, 6 insertions, 6 deletions
diff --git a/examples/integration_wgpu/src/scene.rs b/examples/integration_wgpu/src/scene.rs
index fbda1326..af75e67c 100644
--- a/examples/integration_wgpu/src/scene.rs
+++ b/examples/integration_wgpu/src/scene.rs
@@ -23,7 +23,7 @@ impl Scene {
) -> wgpu::RenderPass<'a> {
encoder.begin_render_pass(&wgpu::RenderPassDescriptor {
label: None,
- color_attachments: &[wgpu::RenderPassColorAttachment {
+ color_attachments: &[Some(wgpu::RenderPassColorAttachment {
view: target,
resolve_target: None,
ops: wgpu::Operations {
@@ -39,7 +39,7 @@ impl Scene {
}),
store: true,
},
- }],
+ })],
depth_stencil_attachment: None,
})
}
@@ -55,8 +55,8 @@ fn build_pipeline(
texture_format: wgpu::TextureFormat,
) -> wgpu::RenderPipeline {
let (vs_module, fs_module) = (
- device.create_shader_module(&wgpu::include_wgsl!("shader/vert.wgsl")),
- device.create_shader_module(&wgpu::include_wgsl!("shader/frag.wgsl")),
+ device.create_shader_module(wgpu::include_wgsl!("shader/vert.wgsl")),
+ device.create_shader_module(wgpu::include_wgsl!("shader/frag.wgsl")),
);
let pipeline_layout =
@@ -78,14 +78,14 @@ fn build_pipeline(
fragment: Some(wgpu::FragmentState {
module: &fs_module,
entry_point: "main",
- targets: &[wgpu::ColorTargetState {
+ targets: &[Some(wgpu::ColorTargetState {
format: texture_format,
blend: Some(wgpu::BlendState {
color: wgpu::BlendComponent::REPLACE,
alpha: wgpu::BlendComponent::REPLACE,
}),
write_mask: wgpu::ColorWrites::ALL,
- }],
+ })],
}),
primitive: wgpu::PrimitiveState {
topology: wgpu::PrimitiveTopology::TriangleList,