Skip to content

Commit 630d9c5

Browse files
committed
Use new mesh attribute api
1 parent 10b3f0f commit 630d9c5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

crates/bevy_render/src/mesh/shape/regular_polygon.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,9 @@ impl From<RegularPolygon> for Mesh {
4040
}
4141

4242
let mut mesh = Mesh::new(PrimitiveTopology::TriangleList);
43-
mesh.set_attribute(Mesh::ATTRIBUTE_POSITION, positions);
44-
mesh.set_attribute(Mesh::ATTRIBUTE_NORMAL, normals);
45-
mesh.set_attribute(Mesh::ATTRIBUTE_UV_0, uvs);
43+
mesh.insert_attribute(Mesh::ATTRIBUTE_POSITION, positions);
44+
mesh.insert_attribute(Mesh::ATTRIBUTE_NORMAL, normals);
45+
mesh.insert_attribute(Mesh::ATTRIBUTE_UV_0, uvs);
4646
mesh.set_indices(Some(Indices::U32(indices)));
4747
mesh
4848
}

0 commit comments

Comments
 (0)