update benchmark_fonts
This commit is contained in:
parent
fe59c77230
commit
84dd01fd00
1 changed files with 3 additions and 3 deletions
|
@ -5,13 +5,13 @@ const text = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis in q
|
|||
var font = readFont("tests/fonts/Roboto-Regular_1.ttf")
|
||||
font.size = 16
|
||||
|
||||
timeIt "typeset":
|
||||
discard font.typeset(text, vec2(500, 0))
|
||||
|
||||
let
|
||||
image = newImage(500, 300)
|
||||
mask = newMask(500, 300)
|
||||
|
||||
timeIt "typeset":
|
||||
discard font.typeset(text, bounds = image.wh)
|
||||
|
||||
timeIt "rasterize":
|
||||
image.fill(rgba(255, 255, 255, 255))
|
||||
image.fillText(font, text, rgba(0, 0, 0, 255), bounds = image.wh)
|
||||
|
|
Loading…
Reference in a new issue