GuilRender.mp4
A collection of rendering tools I built while developing my UI framework, organized into their own repo since the UI depends on them directly, meaning they'll get all the maintenance they deserve. Feel free to use them!
A rendering class built around aggressive batching, Everything from clipping, gradients to shape data is baked directly into the vertices, keeping draw calls minimal while minimizing vertex bloat.
Supports:
- Rectangles, Lines, Circles, Arcs, Ellipses
- Textures
- Gradients (baked into vertices)
- Clipping (baked into vertices)
Renders fonts pre-generated by the included Python tool (a GUI tool, not CLI). Any .ttf can be converted into a .guif file, which pre-bakes the font across multiple sizes using pygame's font rendering engine. At runtime, GuilFont picks the closest atlas size and scales to the exact height you need.
Features:
- Multi-atlas automatic size selection & scaling
- Text wrapping
- Per-character coloring
- Position → index and index → position mapping (cursor-ready)
- Surgically accurate size measurement (WYSIWYG)
A MonoGame-compatible float rectangle that has grown a solid collection of utility methods over time. Used internally by both GuilBatch and GuilFont.
Located at Tools/GuilFont File Generator.py is a GUI-based Python tool (powered by pygame) that takes any .ttf font and outputs a .guif file with pre-baked atlas textures across multiple sizes.
See LICENSE.txt.