1//! `custom_phase_item.wesl`2//!3//! This shader goes with the `custom_phase_item` example. It demonstrates how to4//! enqueue custom rendering logic in a `RenderPhase`.6/// The GPU-side vertex structure.7struct Vertex {8 /// The world-space position of the vertex.9 @location(0) position: vec3<f32>,10 /// The color of the vertex.11 @location(1) color: vec3<f32>,12};14/// Information passed from the vertex shader to the fragment shader.15struct VertexOutput {16 /// The clip-space position of the vertex.17 @builtin(position) clip_position: vec4<f32>,18 /// The color of the vertex.19 @location(0) color: vec3<f32>,20};22/// The vertex shader entry point.23@vertex24fn vertex(vertex: Vertex) -> VertexOutput {25 // Use an orthographic projection.26 var vertex_output: VertexOutput;27 vertex_output.clip_position = vec4(vertex.position.xyz, 1.0);28 vertex_output.color = vertex.color;29 return vertex_output;30}32/// The fragment shader entry point.33@fragment34fn fragment(vertex_output: VertexOutput) -> @location(0) vec4<f32> {35 return vec4(vertex_output.color, 1.0);36}