Added glyph rendering using stb_truetype

This commit is contained in:
2026-03-22 12:42:24 +05:45
parent 9af832adf6
commit 9294a1699f
4 changed files with 405 additions and 6 deletions
-6
View File
@@ -2,11 +2,9 @@ package edit2draw
import "base:runtime"
import "core:fmt"
import "core:math"
import "core:math/linalg"
import gl "vendor:OpenGL"
import b2 "vendor:box2d"
import "vendor:glfw"
Camera :: struct {
@@ -236,10 +234,6 @@ background_destroy :: proc(back : ^Background) {
background_draw :: proc(back : ^Background, cam : ^Camera) {
gl.UseProgram(back.program)
time := f32(glfw.GetTime())
time = math.mod_f32(time, f32(10.0))
gl.Uniform1f(back.uniforms["time"].location, time)
gl.Uniform2f(
back.uniforms["resolution"].location,
f32(cam.width),