From 60cf6a580f5f1a6e609a73a39ee4a3b847b41c20 Mon Sep 17 00:00:00 2001 From: Humza Shahid Date: Mon, 1 Sep 2025 23:07:45 +0100 Subject: [PATCH] add r, g, b arguments to equals function (forgot to do this in previous commit) --- fonts/equals.sml | 50 +++++++++++++----------------------------------- 1 file changed, 13 insertions(+), 37 deletions(-) diff --git a/fonts/equals.sml b/fonts/equals.sml index 022f8d3..8d5a749 100644 --- a/fonts/equals.sml +++ b/fonts/equals.sml @@ -6,7 +6,7 @@ struct fun yToNdc (yOffset, ypos, scale, halfHeight) = ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight, r, g, b) = let val halfWidth = windowWidth / 2.0 val halfHeight = windowHeight / 2.0 @@ -14,64 +14,40 @@ struct #[ xToNdc (xOffset, 0.000000000000000, scale, halfWidth), yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 5.000000000000000, scale, halfWidth), yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 0.000000000000000, scale, halfWidth), yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 0.000000000000000, scale, halfWidth), yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 5.000000000000000, scale, halfWidth), yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 5.000000000000000, scale, halfWidth), yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 0.000000000000000, scale, halfWidth), yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 5.000000000000000, scale, halfWidth), yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 0.000000000000000, scale, halfWidth), yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 0.000000000000000, scale, halfWidth), yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 5.000000000000000, scale, halfWidth), yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, +r, g, b, xToNdc (xOffset, 5.000000000000000, scale, halfWidth), yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 +r, g, b ] end end