diff --git a/examples/shader/extended_material_bindless.rs b/examples/shader/extended_material_bindless.rs index 0a17803272b5d..a9d9c35e6de89 100644 --- a/examples/shader/extended_material_bindless.rs +++ b/examples/shader/extended_material_bindless.rs @@ -24,14 +24,13 @@ static SHADER_ASSET_PATH: &str = "shaders/extended_material_bindless.wgsl"; /// The `#[data(50, ExampleBindlessExtensionUniform, binding_array(101))]` /// attribute specifies that the plain old data /// [`ExampleBindlessExtensionUniform`] will be placed into an array with -/// binding 100 and will occupy index 50 in the -/// `ExampleBindlessExtendedMaterialIndices` structure. (See the shader for the +/// binding 101 and that the index referencing it will be stored in slot 50 of the `ExampleBindlessExtendedMaterialIndices` structure. (See below or lookup the shader for the /// definition of that structure.) That corresponds to the following shader /// declaration: /// /// ```wgsl -/// @group(2) @binding(100) var example_extended_material_indices: -/// array; +/// @group(#{MATERIAL_BIND_GROUP}) @binding(101) +/// var example_extended_material: array; /// ``` /// /// The `#[bindless(index_table(range(50..53), binding(100)))]` attribute @@ -48,8 +47,8 @@ static SHADER_ASSET_PATH: &str = "shaders/extended_material_bindless.wgsl"; /// modulate_texture_sampler: u32, // 52 /// } /// -/// @group(2) @binding(100) var example_extended_material_indices: -/// array; +/// @group(#{MATERIAL_BIND_GROUP}) @binding(100) +/// var example_extended_material_indices: array; /// ``` /// /// We need to use the `index_table` subattribute because the @@ -112,7 +111,7 @@ fn setup( mut meshes: ResMut>, mut materials: ResMut>>, ) { - // Create a gray sphere, modulated with a red-tinted Bevy logo. + // Create a gray sphere, modulated with a red-tinted checkerboard pattern. commands.spawn(( Mesh3d(meshes.add(SphereMeshBuilder::new( 1.0,