Mercurial > games > semicongine
diff tests/test_text.nim @ 1329:ad09d41abd1e
add: 2d-scaling for text
author | sam <sam@basx.dev> |
---|---|
date | Sat, 17 Aug 2024 16:09:15 +0700 |
parents | 373a4888f6ac |
children | df3c075e5dea |
line wrap: on
line diff
--- a/tests/test_text.nim Sat Aug 17 15:09:01 2024 +0700 +++ b/tests/test_text.nim Sat Aug 17 16:09:15 2024 +0700 @@ -213,11 +213,11 @@ var labels: seq[Textbox] var positions = newSeq[Vec3f](100) var colors = newSeq[Vec4f](100) - var scales = newSeq[float32](100) + var scales = newSeq[Vec2f](100) for i in 0 ..< 100: positions[i] = vec3(rand(-0.5 .. 0.5), rand(-0.5 .. 0.5), rand(-0.1 .. 0.1)) colors[i] = vec4(rand(0.5 .. 1.0), rand(0.5 .. 1.0), rand(0.5 .. 1.0), rand(0.5 .. 1.0)) - scales[i] = rand(0.5'f32 .. 1.5'f32) + scales[i] = vec2(rand(0.5'f32 .. 1.5'f32), rand(0.5'f32 .. 1.5'f32)) labels.add initTextbox( renderdata, pipeline.layout(0),