Skip to content

Commit 89cc968

Browse files
committed
Implement glyph atlas and tileset loading for Runeforge
- Introduced `GlyphAtlas` for efficient text rendering with pre-rendered glyphs. - Added `Tileset` for loading PNG tilesets, supporting sprite sheets for graphical rendering. - Implemented font loading and rendering for TrueType and BDF bitmap fonts. - Created error handling for tileset operations with `TilesetError`. - Updated `Cargo.toml` for `runeforge-tileset` with necessary dependencies. - Enhanced documentation with examples for font and tileset usage. - Added tests for character encoding and tile dimensions.
1 parent 121f759 commit 89cc968

8 files changed

Lines changed: 1476 additions & 37 deletions

File tree

Cargo.lock

Lines changed: 150 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,25 @@
11
[package]
2-
name = "runeforge-tileset"
3-
version.workspace = true
4-
edition.workspace = true
5-
rust-version.workspace = true
6-
license.workspace = true
7-
repository.workspace = true
2+
name = "runeforge-tileset"
3+
version.workspace = true
4+
edition.workspace = true
5+
rust-version.workspace = true
6+
license.workspace = true
7+
repository.workspace = true
88
documentation.workspace = true
9-
keywords.workspace = true
10-
categories.workspace = true
11-
description = "Font and tileset loading for the Runeforge roguelike library"
9+
keywords.workspace = true
10+
categories.workspace = true
11+
description = "Font and tileset loading for the Runeforge roguelike library"
1212

1313
[dependencies]
14-
ab_glyph = { workspace = true }
15-
image = { workspace = true }
16-
thiserror = { workspace = true }
14+
runeforge-color = { workspace = true }
15+
ab_glyph = { workspace = true }
16+
bdf-parser = { workspace = true }
17+
image = { workspace = true }
18+
thiserror = { workspace = true }
1719

1820
[features]
19-
default = ["truetype", "bitmap"]
21+
default = ["truetype", "bitmap"]
2022
truetype = []
21-
bitmap = []
23+
bitmap = []
2224

2325
[dev-dependencies]

0 commit comments

Comments
 (0)