Skip to content

raylib.MakeFont

JoeStrout edited this page Apr 29, 2026 · 3 revisions

MakeFont

Parameters

Parameter Default Value Note
baseSize
glyphs
recs
texture
glyphPadding 0

Return value

Condition Return Value
(always) map

Notes

Example

// Construct a Font map from pre-built glyph data and atlas texture
// (glyphs, recs, and tex are typically obtained from LoadFontData + GenImageFontAtlas)
font = raylib.MakeFont(32, glyphs, recs, tex, 4)
if raylib.IsFontValid(font) then
    raylib.DrawTextEx font, "Custom font", [10, 10], 32, 1, raylib.WHITE
end if

Clone this wiki locally