freetype: update examples

compile error due the last functions rename
This commit is contained in:
Ali Chraghi 2022-07-22 23:17:33 +04:30 committed by Stephen Gutekanst
parent 0aa9cc4a04
commit 30612500e0
2 changed files with 2 additions and 2 deletions

View file

@ -24,7 +24,7 @@ const OutlinePrinter = struct {
var lib = try freetype.Library.init();
return Self{
.library = lib,
.face = try lib.newFace("upstream/assets/FiraSans-Regular.ttf", 0),
.face = try lib.createFace("upstream/assets/FiraSans-Regular.ttf", 0),
.output_file = file,
.path_stream = std.io.fixedBufferStream(&buf),
.xMin = 0,

View file

@ -17,7 +17,7 @@ pub fn main() !void {
const lib = try freetype.Library.init();
defer lib.deinit();
const face = try lib.newFace("upstream/assets/FiraSans-Regular.ttf", 0);
const face = try lib.createFace("upstream/assets/FiraSans-Regular.ttf", 0);
try face.setCharSize(60 * 48, 0, 50, 0);
try face.loadChar(args[1][0], .{ .render = true });
const bitmap = face.glyph().bitmap();