bevy/crates/bevy_ui/src/render
ickshonpe 675f8ad403
Improved text batching (#14848)
# Objective

The UI text rendering is really slow because it extracts each glyph as a
separate ui node even though all the glyphs in a text section have the
same texture, color and clipping rects.

## Solution

Store the glyphs in a seperate contiguous array, queue one transparent
ui item per text section which has indices into the glyph array.

## Testing

```cargo run --example many_glyphs --release```

Runs at about 22fps on main and 95fps with this PR on my computer.

I'll do some proper comparisons once I work out why tracy 11 is refusing to run.

---------

Co-authored-by: Kristoffer Søholm <k.soeholm@gmail.com>
2024-10-08 22:24:27 +00:00
..
box_shadow.rs Synchronize removed components with the render world (#15582) 2024-10-08 22:23:17 +00:00
box_shadow.wgsl box shadow (#15204) 2024-10-08 16:26:17 +00:00
mod.rs Improved text batching (#14848) 2024-10-08 22:24:27 +00:00
pipeline.rs Enable/disable UI anti-aliasing (#15170) 2024-09-16 23:06:23 +00:00
render_pass.rs Add core and alloc over std Lints (#15281) 2024-09-27 00:59:59 +00:00
ui.wgsl use precomputed border values (#15163) 2024-09-26 23:10:35 +00:00
ui_material.wgsl Normalise matrix naming (#13489) 2024-06-03 16:56:53 +00:00
ui_material_pipeline.rs Synchronize removed components with the render world (#15582) 2024-10-08 22:23:17 +00:00
ui_texture_slice.wgsl UI texture atlas slice shader (#14990) 2024-09-02 23:03:58 +00:00
ui_texture_slice_pipeline.rs Synchronize removed components with the render world (#15582) 2024-10-08 22:23:17 +00:00
ui_vertex_output.wgsl Include UI node size in the vertex inputs for UiMaterial. (#11722) 2024-02-06 16:15:09 +00:00