No description
Find a file
Héctor Ramón Jiménez ea5f122f78 Remove potentially huge texture_pending from InnerAtlas
Instead, issue a `write_texture` for every glyph that isn't present in
the atlas. I think this should be fine, since cache eviction should be
rare and, therefore, uploads will be too.

The result here is lower memory usage for bigger caches.
2023-03-27 23:00:19 -02:30
.github Rename workflow 2022-05-10 09:37:38 -02:30
examples Set default_color per TextArea 2023-02-26 23:30:30 -03:30
src Remove potentially huge texture_pending from InnerAtlas 2023-03-27 23:00:19 -02:30
.gitignore Remove lock 2022-05-10 09:21:45 -02:30
Cargo.toml Update to latest cosmic-text 2023-02-24 12:33:03 -03:30
LICENSE-APACHE Initial commit 2022-05-09 10:19:10 -02:30
LICENSE-MIT Initial commit 2022-05-09 10:19:10 -02:30
LICENSE-ZLIB Initial commit 2022-05-09 10:19:10 -02:30
README.md Update README 2023-01-29 22:11:54 -03:30

🦅 glyphon 🦁

Fast, simple 2D text rendering for wgpu

crates.io docs.rs Minimum Rust Version Build Status

What is this?

This crate provides a simple way to render 2D text with wgpu by:

  • shaping/calculating layout/rasterizing glyphs (with cosmic-text)
  • packing the glyphs into texture atlas (with etagere)
  • sampling from the texture atlas to render text (with wgpu)

To avoid extra render passes, rendering uses existing render passes (following the middleware pattern described in wgpu's Encapsulating Graphics Work wiki page.

License

This project is licensed under either Apache License, Version 2.0, zlib License, or MIT License, at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this project by you, as defined in the Apache 2.0 license, shall be triple licensed as above, without any additional terms or conditions.