Skip to content

Ed94/TextRendering_Notes

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Text Rendering Notes

Industry standard

slug: Eric Lengyel's all-in-one solution. Has patented slug algorithim (free if you negotiate use on a free purpose, porting interface to X-Lang is problably non-trivial).
GNOME/pango: High-level do-it-all library.
Apple/Core Text
MicrosoftDocs/DirectWrite

Composite Repos

kb_text_shape: Unicode text segmentation and OpenType shaping by Jimmy Lefevre.

runic: Odin community effort towards a all-in-one solution, ttf/opentype parser, shaper, renderer, and some other goodies.

ColleagueRiley/RFont: Claims to target better perforamnce than fontstash. Decided to directly intergrate stb_truetype.h instead of keeping it separate (There is an option to define RFONT_EXTERNAL_STB).

silnrsi/Graphite: "smart font" system developed specifically to handle the complexities of lesser-known languages of the world.

Host-Oman/libraqm: A library for complex text layout

hypernewbie/VEFontCache: VE Font Cache is a single header-only GPU font rendering library designed for game engines. (Uses harfbuzz and stb_truetype)

  • Ed94/VEFontCache-Odin: Ended up porting & overhauled this to Odin-lang
    • Uses a 4-layered atlas cache texture with CPU triangulated vert draw-list for very efficient but slightly reduced text quality.
    • Shader sample only supports greyscale anti-aliasing.
    • Shaper & Parser will be overridable. (Harfbuzz & stb_truetype for now)
    • Affine KB docs (WIP)

Font Parsers

JimmyLefevre/kb - kb_text_shape: Has a parser. Might be the best right now (perf wise).
jon-lipstate/runic: See ttf package (WIP).
stb/stb_truetype: Faster parsing and less bloated than freetype.
freetype
englerj/odin-freetype
odin-lang/Odin/vendor/stb/truetype/stb_truetype.odin
harfbuzz/ttf-parser (rust)
redox-os/rusttype

MSDN - True Type
MSDN - OpenType Specification

khaledhosny/ots - OpenType Sanitizer

Shapers

harfbuzz: Industry standard all-in-one text shaping.

JimmyLefevre/kb - kb_text_shape: Has a shaper.
jon-lipstate/runic: See shaper package (WIP).
hamza: Alternative WIP text shaper.

memononen/budouxc: Word boundary detection for east-asian languages.
adah1972/libunibreak: Grapheme and line-break detection.

crowbar: An application for debugging the layout tables of an OpenType font.

Segmentation

JimmyLefevre/kb - kb_text_shape: Has segmentation via breaks (Clustering is a TODO)
memononen/Skribidi: Bi-directional text stack for building UIs. Seems to be a nice all-in-one solution.
Fribidi: GNU Bi-directional detection.
Tehreer/SheenBidi: Bi-directional detection.
unicode-org/icu: Does quite a bit but specifically also does segmenting

Renderers

Chlumsky/msdfgen
fontdue
(Self-proclaimed "fastest rasterizer")

fontstash
Supported by sokol: sokol/util/sokol_fontstash.h
There are several forks for fonstash... Going to elabroate on them in a separate file

azsn/gllabel: GPU Vector Text Rendering
jtsiomb/libdrawtext
tomolt/libschrift
bzt/scalable-font: Scalable Screen Font renderer and file format specification

kevinmkchin/vertext

Learning Resources

State of Text Rendering 2024
Text Rendering Hates You

Robust Vertical Text Layout

Summer of Code 2012 - Text processing

npx-imx/gtec-demo-frameowrk/Doc/FslSimpleUI

Implementing a Font Reader and Rasterizer from Scratch, Part 1: TTF Font Reader

LearnOpenGL - Text Rendering
Improving Learn OpenGL's Text Rendering Example | Adventures in Coding
Repo for above vod: johnWRS/LearnOpenGLTextRenderingImprovement

GPU Gems 3: Chapter 25. Rendering Vector Art on the GPU

Writing a TrueType font renderer

Wikibooks/OpenGL_Programming/... Text Rendering 01
02 of above

Simple good quality subpixel text rendering in OpenGL with stb_truetype and dual source blending

Examples

Immediate-Mode-UI/Nuklear/nuklear_font.c
raddebugger (non-trivial to digest solution)
refterm
ocornut/imgui/imgui_draw.cpp#L4006
4coder-archive/4coder
gl-4.5-subpixel-text-rendering

GPU Related

GPU text rendering with vector textures
Efficient 2D Signed Distance Field Generation on GPU

GreenLighting/gpu-font-rendering

evanw/theta
Related article for theta's implementation

MSDFGL - OpenGL-accelerated implementation of the multi-channel signed distance-field algorithm.
andrewlowndes/perfect-antialiasing: Antialiasing via conservative rasterisation and analytical area computation

GPU Gems 2: Chapter 42. Conservative Rasterization

Vector Path Accelerators

NV Path Rendering
OpenVG
ajstarks/openvg
ShivaVG: open-source ANSI C OpenVG
ileben/ShivaVG
amanithvg

Papers

SIGGRAPH2007: Improved Alpha-Tested Magnification for Vector Textures and Special Effects
Resolution Independent Curve Rendering using Programmable Graphics Hardware
Higher Quality 2D Text Rendering
Wavelet Rasterization

Metafont (Historical)

Wikipedia
metaflop/metaflop-www
Metapost

Unicode

Unicode Technical Reports
International Components for Unicode

UTrie Accelerators

Forking Paths

A Vector Graphics Renderer — part 1
A Vector Graphics Renderer — part 2
A Vector Graphics Renderer — part 3
Revisiting Vector Graphics on the GPU
Orca Vector Graphics Backend

Mr. 4th Programming

Graphics 2[7] Baking Optimized Fonts Data
Graphics [8]: Low Level Rendering API Part 1
Graphics [9]: Low Level Rendering API Part 2
Graphics [10]: High Level Rendering API ...

Tscoding

ded editor
Legendary Font Rendering
Rendering Text Editor on GPU

OpenGL Text Rendering for My Immediate UI Library - Offline Stream #02

Conceptual Overview for Typography

Google Fonts: Typeface
Wikipeida - Outline
Wikipedia - Anatomy
Anatomy img

Sociology of Fonts - Defining the Terms Part 1: Anatomy
Sociology of Fonts - Defining the Terms Part 2: Process
Sociology of Fonts - Defining the Terms Part 3: Categorization

Original Notes Header

The goal here was to find some solution that was small and preferrably interopped well with odin-lang. So, everything that was either not written in C or was not going to be an easy port, was ignored.

Now I just keep this in sync with anything I find while working on my fork of VEFontCache.

VEFontCache will most likely stay in a relatively "finished" state for the forseable future. Much of my interest have shifted to maybe utilizing the runic library when there is time to spruce it up.

Interesting...

MacType

About

Notes on getting the old letters onto a digital screen

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published