bevy/crates/bevy_sprite/src/mesh2d
Patrick Walton 8577a448f7
Fix rendering of sprites, text, and meshlets after #12582. (#12945)
`Sprite`, `Text`, and `Handle<MeshletMesh>` were types of renderable
entities that the new segregated visible entity system didn't handle, so
they didn't appear.

Because `bevy_text` depends on `bevy_sprite`, and the visibility
computation of text happens in the latter crate, I had to introduce a
new marker component, `SpriteSource`. `SpriteSource` marks entities that
aren't themselves sprites but become sprites during rendering. I added
this component to `Text2dBundle`. Unfortunately, this is technically a
breaking change, although I suspect it won't break anybody in practice
except perhaps editors.

Fixes #12935.

## Changelog

### Changed

* `Text2dBundle` now includes a new marker component, `SpriteSource`.
Bevy uses this internally to optimize visibility calculation.

## Migration Guide

* `Text` now requires a `SpriteSource` marker component in order to
appear. This component has been added to `Text2dBundle`.
2024-04-13 14:15:00 +00:00
..
color_material.rs Consolidate Render(Ui)Materials(2d) into RenderAssets (#12827) 2024-04-09 13:26:34 +00:00
color_material.wgsl Swap material and mesh bind groups (#10485) 2023-11-28 22:26:22 +00:00
material.rs Divide the single VisibleEntities list into separate lists for 2D meshes, 3D meshes, lights, and UI elements, for performance. (#12582) 2024-04-11 20:33:20 +00:00
mesh.rs Fix rendering of sprites, text, and meshlets after #12582. (#12945) 2024-04-13 14:15:00 +00:00
mesh2d.wgsl update shader imports (#10180) 2023-10-21 11:51:58 +00:00
mesh2d_bindings.wgsl Swap material and mesh bind groups (#10485) 2023-11-28 22:26:22 +00:00
mesh2d_functions.wgsl Add support for KHR_texture_transform (#11904) 2024-02-21 01:11:28 +00:00
mesh2d_types.wgsl Add support for KHR_texture_transform (#11904) 2024-02-21 01:11:28 +00:00
mesh2d_vertex_output.wgsl pbr shader cleanup (#10105) 2023-10-13 19:12:40 +00:00
mesh2d_view_bindings.wgsl update shader imports (#10180) 2023-10-21 11:51:58 +00:00
mesh2d_view_types.wgsl Refactor Globals and View structs into separate shaders (#7512) 2023-02-11 17:55:18 +00:00
mod.rs Support wireframes for 2D meshes (#12135) 2024-03-29 18:34:04 +00:00
wireframe2d.rs Support wireframes for 2D meshes (#12135) 2024-03-29 18:34:04 +00:00
wireframe2d.wgsl Support wireframes for 2D meshes (#12135) 2024-03-29 18:34:04 +00:00