diff --git a/fonts/0.dsc b/fonts/0.dsc deleted file mode 100644 index e766f4e..0000000 --- a/fonts/0.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 -x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y 0.333333343267 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.333333343267 -x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y ~0.466666638851 diff --git a/fonts/1.dsc b/fonts/1.dsc deleted file mode 100644 index d1a09bf..0000000 --- a/fonts/1.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x ~0.200000017881 y 0.333333343267 x ~0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.333333343267 -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 -x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.466666638851 -x 0.333333283663 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 x 0.333333283663 y ~0.466666638851 diff --git a/fonts/2.dsc b/fonts/2.dsc deleted file mode 100644 index bff2bf5..0000000 --- a/fonts/2.dsc +++ /dev/null @@ -1,16 +0,0 @@ -x ~0.333333343267 y 0.200000017881 x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.200000017881 x ~0.333333343267 y 0.200000017881 -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 x 0.333333283663 y 0.333333343267 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 -x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 -x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 -x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 -x 0.333333283663 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 x 0.333333283663 y ~0.466666638851 diff --git a/fonts/3.dsc b/fonts/3.dsc deleted file mode 100644 index eb5e8bb..0000000 --- a/fonts/3.dsc +++ /dev/null @@ -1,14 +0,0 @@ -x ~0.333333343267 y 0.200000017881 x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.200000017881 x ~0.333333343267 y 0.200000017881 -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 x 0.333333283663 y 0.333333343267 -x ~0.0666666701436 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y 0.0666666701436 -x 0.333333283663 y ~0.0666667371988 x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.0666667371988 x 0.333333283663 y ~0.0666667371988 -x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.333333283663 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/4.dsc b/fonts/4.dsc deleted file mode 100644 index 8b29638..0000000 --- a/fonts/4.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x 0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.333333343267 -x ~0.0666666701436 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.200000017881 -x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y ~0.0666667371988 -x ~0.333333343267 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x ~0.333333343267 y ~0.0666667371988 x ~0.333333343267 y ~0.199999943376 x ~0.466666668653 y ~0.199999943376 -x ~0.466666668653 y ~0.199999943376 x ~0.466666668653 y ~0.0666667371988 x ~0.333333343267 y ~0.0666667371988 -x ~0.466666668653 y ~0.333333283663 x ~0.466666668653 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 -x 0.333333283663 y ~0.333333283663 x 0.333333283663 y ~0.199999943376 x ~0.466666668653 y ~0.333333283663 -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x 0.199999943376 y 0.466666638851 x 0.0666666701436 y 0.466666638851 diff --git a/fonts/5.dsc b/fonts/5.dsc deleted file mode 100644 index a2c3ea6..0000000 --- a/fonts/5.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.333333283663 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.333333343267 x ~0.333333343267 y 0.333333343267 -x ~0.333333343267 y 0.333333343267 x ~0.333333343267 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y 0.333333343267 x 0.333333283663 y 0.333333343267 diff --git a/fonts/6.dsc b/fonts/6.dsc deleted file mode 100644 index edee3fc..0000000 --- a/fonts/6.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x 0.199999943376 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.333333343267 -x ~0.0666666701436 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 -x ~0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.200000017881 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.333333343267 x ~0.0666666701436 y 0.333333343267 -x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 -x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.0666667371988 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/7.dsc b/fonts/7.dsc deleted file mode 100644 index 52e3c93..0000000 --- a/fonts/7.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.333333283663 y 0.200000017881 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y 0.333333343267 x 0.333333283663 y 0.333333343267 diff --git a/fonts/8.dsc b/fonts/8.dsc deleted file mode 100644 index 32afb21..0000000 --- a/fonts/8.dsc +++ /dev/null @@ -1,14 +0,0 @@ -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.333333343267 x 0.333333283663 y 0.333333343267 -x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.0666667371988 -x ~0.333333343267 y ~0.0666667371988 x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.0666667371988 x ~0.333333343267 y ~0.0666667371988 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/9.dsc b/fonts/9.dsc deleted file mode 100644 index 280b711..0000000 --- a/fonts/9.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x ~0.200000017881 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.466666638851 -x 0.0666666701436 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.466666638851 -x 0.333333283663 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.333333283663 y 0.333333343267 x 0.333333283663 y ~0.333333283663 -x 0.199999943376 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.199999943376 -x ~0.333333343267 y ~0.0666667371988 x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y ~0.0666667371988 x ~0.333333343267 y ~0.0666667371988 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 x ~0.200000017881 y 0.466666638851 -x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 x 0.199999943376 y 0.333333343267 diff --git a/fonts/ampersand.dsc b/fonts/ampersand.dsc deleted file mode 100644 index a895d1c..0000000 --- a/fonts/ampersand.dsc +++ /dev/null @@ -1,20 +0,0 @@ -x 0.333333283663 y 0.0666666701436 x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 -x 0.333333283663 y ~0.599999964237 x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 -x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x 0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.599999964237 -x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 -x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 -x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.200000017881 -x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.466666638851 x 0.0666666701436 y 0.466666638851 -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.200000017881 x ~0.200000017881 y 0.200000017881 -x 0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.599999964237 diff --git a/fonts/ampersand.sml b/fonts/ampersand.sml index 103e6b2..b7dc044 100644 --- a/fonts/ampersand.sml +++ b/fonts/ampersand.sml @@ -1,135 +1,317 @@ -structure Ampersand = +structure Ampersand = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/angle-bracket-closed.dsc b/fonts/angle-bracket-closed.dsc deleted file mode 100644 index 5b6bf4f..0000000 --- a/fonts/angle-bracket-closed.dsc +++ /dev/null @@ -1,14 +0,0 @@ -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.0666666701436 -x 0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.200000017881 -x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 -x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.199999943376 -x 0.199999943376 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 x 0.333333283663 y ~0.0666667371988 -x 0.199999943376 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.199999943376 -x 0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.466666638851 -x ~0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x ~0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.466666638851 diff --git a/fonts/angle-bracket-closed.sml b/fonts/angle-bracket-closed.sml deleted file mode 100644 index b8e92a8..0000000 --- a/fonts/angle-bracket-closed.sml +++ /dev/null @@ -1,99 +0,0 @@ -structure AngleBracketClosed = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/angle-bracket-open.dsc b/fonts/angle-bracket-open.dsc deleted file mode 100644 index 8ec60c2..0000000 --- a/fonts/angle-bracket-open.dsc +++ /dev/null @@ -1,14 +0,0 @@ -x 0.199999943376 y 0.333333343267 x 0.0666666701436 y 0.333333343267 x 0.0666666701436 y 0.200000017881 -x 0.0666666701436 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.333333343267 -x 0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y 0.0666666701436 -x ~0.333333343267 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y ~0.199999943376 -x ~0.200000017881 y ~0.199999943376 x ~0.333333343267 y ~0.199999943376 x ~0.333333343267 y ~0.0666667371988 -x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 -x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 diff --git a/fonts/angle-bracket-open.sml b/fonts/angle-bracket-open.sml deleted file mode 100644 index ec534a0..0000000 --- a/fonts/angle-bracket-open.sml +++ /dev/null @@ -1,99 +0,0 @@ -structure AngleBracketOpen = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/ascii-at.sml b/fonts/ascii-at.sml index 4beacdb..407488b 100644 --- a/fonts/ascii-at.sml +++ b/fonts/ascii-at.sml @@ -1,99 +1,227 @@ -structure AsciiAt = +structure AsciiAt = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-dot.sml b/fonts/ascii-dot.sml index 09b5f77..4c4ded7 100644 --- a/fonts/ascii-dot.sml +++ b/fonts/ascii-dot.sml @@ -1,27 +1,47 @@ -structure AsciiDot = +structure AsciiDot = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-eight.sml b/fonts/ascii-eight.sml index 05b6160..6c0fa15 100644 --- a/fonts/ascii-eight.sml +++ b/fonts/ascii-eight.sml @@ -1,99 +1,227 @@ -structure AsciiEight = +structure AsciiEight = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-equals.sml b/fonts/ascii-equals.sml deleted file mode 100644 index 61e49f0..0000000 --- a/fonts/ascii-equals.sml +++ /dev/null @@ -1,39 +0,0 @@ -structure AsciiEquals = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/ascii-five.sml b/fonts/ascii-five.sml index 61e6db6..96ab8ed 100644 --- a/fonts/ascii-five.sml +++ b/fonts/ascii-five.sml @@ -1,87 +1,197 @@ -structure AsciiFive = +structure AsciiFive = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-four.sml b/fonts/ascii-four.sml index a29bbfd..49a935f 100644 --- a/fonts/ascii-four.sml +++ b/fonts/ascii-four.sml @@ -1,87 +1,197 @@ -structure AsciiFour = +structure AsciiFour = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 6.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 6.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 6.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-hash.sml b/fonts/ascii-hash.sml index 80961cd..9de6958 100644 --- a/fonts/ascii-hash.sml +++ b/fonts/ascii-hash.sml @@ -1,63 +1,137 @@ -structure AsciiHash = +structure AsciiHash = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-minus.sml b/fonts/ascii-minus.sml index b05f092..f4cc2ae 100644 --- a/fonts/ascii-minus.sml +++ b/fonts/ascii-minus.sml @@ -1,27 +1,47 @@ -structure AsciiMinus = +structure AsciiMinus = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-nine.sml b/fonts/ascii-nine.sml index c6b0811..8e8cec7 100644 --- a/fonts/ascii-nine.sml +++ b/fonts/ascii-nine.sml @@ -1,87 +1,197 @@ -structure AsciiNine = +structure AsciiNine = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-one.sml b/fonts/ascii-one.sml index 9c9feee..78bb259 100644 --- a/fonts/ascii-one.sml +++ b/fonts/ascii-one.sml @@ -1,63 +1,137 @@ -structure AsciiOne = +structure AsciiOne = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-percent.sml b/fonts/ascii-percent.sml index 34620ee..61f47ec 100644 --- a/fonts/ascii-percent.sml +++ b/fonts/ascii-percent.sml @@ -1,171 +1,407 @@ -structure AsciiPercent = +structure AsciiPercent = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-pipe.sml b/fonts/ascii-pipe.sml index 4d79ec2..2b351d7 100644 --- a/fonts/ascii-pipe.sml +++ b/fonts/ascii-pipe.sml @@ -1,27 +1,47 @@ -structure AsciiPipe = +structure AsciiPipe = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-plus.sml b/fonts/ascii-plus.sml index a4ae6d0..a63b24a 100644 --- a/fonts/ascii-plus.sml +++ b/fonts/ascii-plus.sml @@ -1,39 +1,77 @@ -structure AsciiPlus = +structure AsciiPlus = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-seven.sml b/fonts/ascii-seven.sml index d6badb3..cbadace 100644 --- a/fonts/ascii-seven.sml +++ b/fonts/ascii-seven.sml @@ -1,75 +1,167 @@ -structure AsciiSeven = +structure AsciiSeven = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-six.sml b/fonts/ascii-six.sml index 9ca845d..8235545 100644 --- a/fonts/ascii-six.sml +++ b/fonts/ascii-six.sml @@ -1,87 +1,197 @@ -structure AsciiSix = +structure AsciiSix = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/new-fonts/ascii-space.sml b/fonts/ascii-space.sml similarity index 100% rename from new-fonts/ascii-space.sml rename to fonts/ascii-space.sml diff --git a/fonts/ascii-three.sml b/fonts/ascii-three.sml index 2da9842..9b8e88f 100644 --- a/fonts/ascii-three.sml +++ b/fonts/ascii-three.sml @@ -1,99 +1,227 @@ -structure AsciiThree = +structure AsciiThree = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/new-fonts/ascii-tilde.sml b/fonts/ascii-tilde.sml similarity index 100% rename from new-fonts/ascii-tilde.sml rename to fonts/ascii-tilde.sml diff --git a/fonts/ascii-two.sml b/fonts/ascii-two.sml index 65531ed..155e8e7 100644 --- a/fonts/ascii-two.sml +++ b/fonts/ascii-two.sml @@ -1,111 +1,257 @@ -structure AsciiTwo = +structure AsciiTwo = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/ascii-zero.sml b/fonts/ascii-zero.sml index eb9c46d..48915c9 100644 --- a/fonts/ascii-zero.sml +++ b/fonts/ascii-zero.sml @@ -1,75 +1,168 @@ -structure AsciiZero = +structure AsciiZero = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight): Real32.real + vector = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/asterisk.dsc b/fonts/asterisk.dsc deleted file mode 100644 index 71a22f7..0000000 --- a/fonts/asterisk.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x 0.333333283663 y ~0.199999943376 x 0.333333283663 y ~0.0666667371988 x ~0.333333343267 y ~0.0666667371988 -x ~0.333333343267 y ~0.0666667371988 x ~0.333333343267 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 -x 0.199999943376 y 0.200000017881 x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.0666666701436 -x 0.0666666701436 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.200000017881 x ~0.200000017881 y 0.200000017881 -x 0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y 0.0666666701436 -x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.466666638851 -x 0.0666666701436 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.333333283663 diff --git a/fonts/asterisk.sml b/fonts/asterisk.sml index 8fcb64c..11c7444 100644 --- a/fonts/asterisk.sml +++ b/fonts/asterisk.sml @@ -1,87 +1,197 @@ -structure Asterisk = +structure Asterisk = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/at.dsc b/fonts/at.dsc deleted file mode 100644 index 2eff8de..0000000 --- a/fonts/at.dsc +++ /dev/null @@ -1,14 +0,0 @@ -x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.199999943376 -x 0.0666666701436 y ~0.199999943376 x 0.199999943376 y ~0.199999943376 x 0.199999943376 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y 0.0666666701436 -x 0.333333283663 y ~0.333333283663 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y ~0.333333283663 x 0.333333283663 y ~0.333333283663 -x 0.199999943376 y 0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 -x 0.333333283663 y ~0.599999964237 x 0.333333283663 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.333333343267 x ~0.333333343267 y 0.333333343267 -x ~0.333333343267 y 0.333333343267 x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 diff --git a/fonts/backtick.dsc b/fonts/backtick.dsc deleted file mode 100644 index 2234179..0000000 --- a/fonts/backtick.dsc +++ /dev/null @@ -1,4 +0,0 @@ -x 0.0666666701436 y 0.333333343267 x 0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.333333343267 x 0.0666666701436 y 0.333333343267 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.599999964237 x ~0.200000017881 y 0.599999964237 -x ~0.200000017881 y 0.599999964237 x ~0.200000017881 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 diff --git a/fonts/backtick.sml b/fonts/backtick.sml index f00bd51..fc43186 100644 --- a/fonts/backtick.sml +++ b/fonts/backtick.sml @@ -1,39 +1,77 @@ -structure Backtick = +structure Backtick = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/new-fonts/backward-slash.sml b/fonts/backward-slash.sml similarity index 100% rename from new-fonts/backward-slash.sml rename to fonts/backward-slash.sml diff --git a/fonts/bracket-closed.dsc b/fonts/bracket-closed.dsc deleted file mode 100644 index 8508077..0000000 --- a/fonts/bracket-closed.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.200000017881 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.599999964237 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.200000017881 -x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 -x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.733333289623 x ~0.0666666701436 y ~0.733333289623 -x ~0.0666666701436 y ~0.733333289623 x ~0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 -x ~0.0666666701436 y ~0.733333289623 x ~0.200000017881 y ~0.733333289623 x ~0.200000017881 y ~0.866666674614 -x ~0.200000017881 y ~0.866666674614 x ~0.0666666701436 y ~0.866666674614 x ~0.0666666701436 y ~0.733333289623 diff --git a/fonts/bracket-closed.sml b/fonts/bracket-closed.sml deleted file mode 100644 index 7efbf79..0000000 --- a/fonts/bracket-closed.sml +++ /dev/null @@ -1,75 +0,0 @@ -structure BracketClosed = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/bracket-open.dsc b/fonts/bracket-open.dsc deleted file mode 100644 index 896ca73..0000000 --- a/fonts/bracket-open.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.199999943376 y 0.599999964237 x 0.199999943376 y 0.466666638851 x 0.0666666701436 y 0.466666638851 -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.599999964237 x 0.199999943376 y 0.599999964237 -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.466666638851 -x ~0.200000017881 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y ~0.466666638851 -x ~0.0666666701436 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.200000017881 -x 0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.733333289623 -x 0.0666666701436 y ~0.733333289623 x ~0.0666666701436 y ~0.733333289623 x ~0.0666666701436 y ~0.466666638851 -x 0.199999943376 y ~0.733333289623 x 0.0666666701436 y ~0.733333289623 x 0.0666666701436 y ~0.866666674614 -x 0.0666666701436 y ~0.866666674614 x 0.199999943376 y ~0.866666674614 x 0.199999943376 y ~0.733333289623 diff --git a/fonts/bracket-open.sml b/fonts/bracket-open.sml deleted file mode 100644 index 74b3aa2..0000000 --- a/fonts/bracket-open.sml +++ /dev/null @@ -1,75 +0,0 @@ -structure BracketOpen = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/caret.dsc b/fonts/caret.dsc deleted file mode 100644 index ce391ae..0000000 --- a/fonts/caret.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.0666666701436 y 0.599999964237 x 0.199999943376 y 0.599999964237 x 0.199999943376 y 0.466666638851 -x 0.199999943376 y 0.466666638851 x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.599999964237 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.466666638851 x 0.199999943376 y 0.466666638851 -x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 x 0.333333283663 y 0.333333343267 -x ~0.333333343267 y 0.333333343267 x ~0.333333343267 y 0.466666638851 x ~0.200000017881 y 0.466666638851 -x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 x ~0.333333343267 y 0.333333343267 -x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 -x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.466666638851 x ~0.200000017881 y 0.466666638851 -x 0.0666666701436 y 0.599999964237 x 0.0666666701436 y 0.733333289623 x ~0.0666666701436 y 0.733333289623 -x ~0.0666666701436 y 0.733333289623 x ~0.0666666701436 y 0.599999964237 x 0.0666666701436 y 0.599999964237 diff --git a/fonts/caret.sml b/fonts/caret.sml index 239e147..8c91924 100644 --- a/fonts/caret.sml +++ b/fonts/caret.sml @@ -1,75 +1,167 @@ -structure Caret = +structure Caret = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.866666674614)) + (endY * 0.866666674614)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.866666674614)) + (endY * 0.866666674614)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.866666674614)) + (endY * 0.866666674614)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/colon-semi.dsc b/fonts/colon-semi.dsc deleted file mode 100644 index 92a745b..0000000 --- a/fonts/colon-semi.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x ~0.200000017881 y 0.200000017881 x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.599999964237 -x 0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.333333283663 -x 0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.733333289623 -x ~0.0666666701436 y ~0.733333289623 x 0.0666666701436 y ~0.733333289623 x 0.0666666701436 y ~0.599999964237 -x ~0.0666666701436 y ~0.733333289623 x ~0.200000017881 y ~0.733333289623 x ~0.200000017881 y ~0.866666674614 -x ~0.200000017881 y ~0.866666674614 x ~0.0666666701436 y ~0.866666674614 x ~0.0666666701436 y ~0.733333289623 diff --git a/fonts/colon.dsc b/fonts/colon.dsc deleted file mode 100644 index e463452..0000000 --- a/fonts/colon.dsc +++ /dev/null @@ -1,4 +0,0 @@ -x ~0.199999973178 y 0.199999928474 x 0.0666667073965 y 0.199999928474 x 0.0666667073965 y ~0.0666667073965 -x ~0.199999973178 y ~0.0666667073965 x 0.0666667073965 y ~0.0666667073965 x ~0.199999973178 y 0.199999928474 -x 0.0666667073965 y ~0.333333343267 x ~0.199999973178 y ~0.333333343267 x ~0.199999973178 y ~0.600000143051 -x ~0.199999973178 y ~0.600000143051 x 0.0666667073965 y ~0.600000143051 x 0.0666667073965 y ~0.333333343267 diff --git a/fonts/colon.sml b/fonts/colon.sml index 3861b69..728fb86 100644 --- a/fonts/colon.sml +++ b/fonts/colon.sml @@ -1,39 +1,77 @@ -structure Colon = +structure Colon = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.599999964237)) + (endY * 0.599999964237)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.599999964237)) + (endY * 0.599999964237)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.599999964237)) + (endY * 0.599999964237)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/comma.dsc b/fonts/comma.dsc deleted file mode 100644 index 77fec36..0000000 --- a/fonts/comma.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x ~0.199999973178 y ~0.333333343267 x 0.0666667073965 y ~0.333333343267 x 0.0666667073965 y ~0.600000143051 -x 0.0666667073965 y ~0.600000143051 x ~0.199999973178 y ~0.600000143051 x ~0.199999973178 y ~0.333333343267 -x 0.0666667073965 y ~0.600000143051 x 0.0666667073965 y ~0.733333349228 x ~0.066666610539 y ~0.733333349228 -x ~0.066666610539 y ~0.733333349228 x ~0.066666610539 y ~0.600000143051 x 0.0666667073965 y ~0.600000143051 -x ~0.066666610539 y ~0.866666793823 x ~0.199999973178 y ~0.866666793823 x ~0.199999973178 y ~0.733333349228 -x ~0.199999973178 y ~0.733333349228 x ~0.066666610539 y ~0.733333349228 x ~0.066666610539 y ~0.866666793823 diff --git a/fonts/comma.sml b/fonts/comma.sml index fe2b89d..158e474 100644 --- a/fonts/comma.sml +++ b/fonts/comma.sml @@ -1,51 +1,107 @@ -structure Comma = +structure Comma = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.333333313465)) + (endY * 0.333333313465)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333325386)) + (endY * 0.133333325386)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666698456)) + (endX * 0.466666698456)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333325386)) + (endY * 0.133333325386)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666698456)) + (endX * 0.466666698456)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333325386)) + (endY * 0.133333325386)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666698456)) + (endX * 0.466666698456)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.199999928474)) + (endY * 0.199999928474)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666698456)) + (endX * 0.466666698456)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0666666030884)) + (endY * 0.0666666030884)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0666666030884)) + (endY * 0.0666666030884)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333325386)) + (endY * 0.133333325386)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.40000000596)) + (endX * 0.40000000596)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333325386)) + (endY * 0.133333325386)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666698456)) + (endX * 0.466666698456)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333325386)) + (endY * 0.133333325386)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666698456)) + (endX * 0.466666698456)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0666666030884)) + (endY * 0.0666666030884)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/cozette-ascii.mlb b/fonts/cozette-ascii.mlb index c730a31..bfc9fef 100644 --- a/fonts/cozette-ascii.mlb +++ b/fonts/cozette-ascii.mlb @@ -1,5 +1,4 @@ $(SML_LIB)/basis/basis.mlb - ann "allowVectorExps true" in @@ -14,29 +13,26 @@ in ascii-seven.sml ascii-eight.sml ascii-nine.sml - + ascii-space.sml ampersand.sml - angle-bracket-closed.sml - angle-bracket-open.sml - ascii-at.sml - ascii-dot.sml - ascii-hash.sml - ascii-minus.sml - ascii-percent.sml - ascii-pipe.sml - ascii-plus.sml asterisk.sml + ascii-at.sml backtick.sml - bracket-closed.sml - bracket-open.sml + backward-slash.sml caret.sml colon.sml comma.sml - curly-brace-closed.sml - curly-brace-open.sml dollar.sml - exclamation-mark.sml - + quotes-double.sml + equals.sml + exclamation_mark.sml + forward-slash.sml + ascii-dot.sml + ascii-hash.sml + left-angled-bracket.sml + left-brace.sml + left-bracket.sml + left-paren.sml lower-case-a.sml lower-case-b.sml lower-case-c.sml @@ -63,18 +59,20 @@ in lower-case-x.sml lower-case-y.sml lower-case-z.sml - + ascii-minus.sml + ascii-percent.sml + ascii-pipe.sml + ascii-plus.sml question-mark.sml - quotes-double.sml + right-angled-bracket.sml + right-brace.sml + right-bracket.sml + right-paren.sml + semicolon.sml quotes-single.sml - semi-colon.sml - slash-backwards.sml - slash-forwards.sml - square-bracket-closed.sml - square-bracket-open.sml - tilde.sml + ascii-tilde.sml underscore.sml - + unknown.sml upper-case-a.sml upper-case-b.sml upper-case-c.sml @@ -101,10 +99,6 @@ in upper-case-x.sml upper-case-y.sml upper-case-z.sml - - ascii-equals.sml - space.sml - unknown-char.sml in cozette-ascii.sml end diff --git a/fonts/cozette-ascii.sml b/fonts/cozette-ascii.sml index 39a3418..be85e29 100644 --- a/fonts/cozette-ascii.sml +++ b/fonts/cozette-ascii.sml @@ -1,38 +1,38 @@ structure CozetteAscii = struct val asciiTable = #[ - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, AsciiSpace.lerp, ExclamationMark.lerp, QuotesDouble.lerp, @@ -41,14 +41,14 @@ struct AsciiPercent.lerp, Ampersand.lerp, QuotesSingle.lerp, - BracketOpen.lerp, - BracketClosed.lerp, + LeftParen.lerp, + RightParen.lerp, Asterisk.lerp, AsciiPlus.lerp, Comma.lerp, AsciiMinus.lerp, AsciiDot.lerp, - SlashForwards.lerp, + ForwardSlash.lerp, AsciiZero.lerp, AsciiOne.lerp, AsciiTwo.lerp, @@ -61,9 +61,9 @@ struct AsciiNine.lerp, Colon.lerp, Semicolon.lerp, - AngleBracketOpen.lerp, + LeftAngledBracket.lerp, AsciiEquals.lerp, - AngleBracketClosed.lerp, + RightAngledBracket.lerp, QuestionMark.lerp, AsciiAt.lerp, UpperCaseA.lerp, @@ -92,9 +92,9 @@ struct UpperCaseX.lerp, UpperCaseY.lerp, UpperCaseZ.lerp, - SquareBracketOpen.lerp, - SlashBackwards.lerp, - SquareBracketClosed.lerp, + LeftBracket.lerp, + BackwardSlash.lerp, + RightBracket.lerp, Caret.lerp, Underscore.lerp, Backtick.lerp, @@ -124,130 +124,137 @@ struct LowerCaseX.lerp, LowerCaseY.lerp, LowerCaseZ.lerp, - CurlyBraceOpen.lerp, + LeftBrace.lerp, AsciiPipe.lerp, - CurlyBraceClosed.lerp, + RightBrace.lerp, AsciiTilde.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp, - UnknownChar.lerp + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp, + Unknown.lerp ] + + fun make (chr, posX, posY, scale, windowWidth, windowHeight, r, g, b) = + let + val chrFun = Vector.sub (asciiTable, Char.ord chr) + in + chrFun (posX, posY, scale, windowWidth, windowHeight) + end end diff --git a/fonts/curly-brace-closed.dsc b/fonts/curly-brace-closed.dsc deleted file mode 100644 index eaaea9c..0000000 --- a/fonts/curly-brace-closed.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.333333343267 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y 0.599999964237 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x 0.333333283663 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.199999943376 -x 0.0666666701436 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 x 0.333333283663 y ~0.0666667371988 -x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.733333289623 x ~0.0666666701436 y ~0.733333289623 -x ~0.0666666701436 y ~0.733333289623 x ~0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y ~0.733333289623 x ~0.333333343267 y ~0.733333289623 x ~0.333333343267 y ~0.866666674614 -x ~0.333333343267 y ~0.866666674614 x ~0.0666666701436 y ~0.866666674614 x ~0.0666666701436 y ~0.733333289623 diff --git a/fonts/curly-brace-closed.sml b/fonts/curly-brace-closed.sml deleted file mode 100644 index 8800b14..0000000 --- a/fonts/curly-brace-closed.sml +++ /dev/null @@ -1,75 +0,0 @@ -structure CurlyBraceClosed = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/curly-brace-open.dsc b/fonts/curly-brace-open.dsc deleted file mode 100644 index e550e78..0000000 --- a/fonts/curly-brace-open.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.199999943376 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.599999964237 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x ~0.466666668653 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y ~0.199999943376 -x ~0.200000017881 y ~0.199999943376 x ~0.466666668653 y ~0.199999943376 x ~0.466666668653 y ~0.0666667371988 -x ~0.200000017881 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.733333289623 -x ~0.0666666701436 y ~0.733333289623 x ~0.200000017881 y ~0.733333289623 x ~0.200000017881 y ~0.199999943376 -x ~0.0666666701436 y ~0.733333289623 x 0.199999943376 y ~0.733333289623 x 0.199999943376 y ~0.866666674614 -x 0.199999943376 y ~0.866666674614 x ~0.0666666701436 y ~0.866666674614 x ~0.0666666701436 y ~0.733333289623 diff --git a/fonts/curly-brace-open.sml b/fonts/curly-brace-open.sml deleted file mode 100644 index ba12533..0000000 --- a/fonts/curly-brace-open.sml +++ /dev/null @@ -1,75 +0,0 @@ -structure CurlyBraceOpen = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/dollar.dsc b/fonts/dollar.dsc deleted file mode 100644 index ee27e05..0000000 --- a/fonts/dollar.dsc +++ /dev/null @@ -1,16 +0,0 @@ -x 0.333333283663 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.200000017881 -x 0.199999943376 y 0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 -x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y 0.333333343267 -x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x 0.199999943376 y ~0.0666667371988 x 0.333333283663 y ~0.0666667371988 x 0.333333283663 y ~0.466666638851 -x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.333333283663 -x 0.0666666701436 y ~0.733333289623 x 0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 -x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y ~0.733333289623 x 0.0666666701436 y ~0.733333289623 diff --git a/fonts/dollar.sml b/fonts/dollar.sml index a19ddf6..78c70e5 100644 --- a/fonts/dollar.sml +++ b/fonts/dollar.sml @@ -1,111 +1,257 @@ -structure Dollar = +structure Dollar = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b - ] - end + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end end diff --git a/fonts/dot.dsc b/fonts/dot.dsc deleted file mode 100644 index e06611e..0000000 --- a/fonts/dot.dsc +++ /dev/null @@ -1,2 +0,0 @@ -x 0.0666667073965 y ~0.333333343267 x ~0.199999973178 y ~0.333333343267 x ~0.199999973178 y ~0.600000143051 -x ~0.199999973178 y ~0.600000143051 x 0.0666667073965 y ~0.600000143051 x 0.0666667073965 y ~0.333333343267 diff --git a/fonts/equals.dsc b/fonts/equals.dsc deleted file mode 100644 index dc0799c..0000000 --- a/fonts/equals.dsc +++ /dev/null @@ -1,4 +0,0 @@ -x 0.333333283663 y ~0.333333283663 x 0.333333283663 y ~0.199999943376 x ~0.333333343267 y ~0.199999943376 -x ~0.333333343267 y ~0.199999943376 x ~0.333333343267 y ~0.333333283663 x 0.333333283663 y ~0.333333283663 -x 0.333333283663 y ~0.0666667371988 x ~0.333333343267 y ~0.0666667371988 x ~0.333333343267 y 0.0666666701436 -x ~0.333333343267 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 x 0.333333283663 y ~0.0666667371988 diff --git a/new-fonts/equals.sml b/fonts/equals.sml similarity index 100% rename from new-fonts/equals.sml rename to fonts/equals.sml diff --git a/fonts/exclamation-mark.dsc b/fonts/exclamation-mark.dsc deleted file mode 100644 index bfbd650..0000000 --- a/fonts/exclamation-mark.dsc +++ /dev/null @@ -1,4 +0,0 @@ -x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 -x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 -x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 diff --git a/fonts/exclamation-mark.sml b/fonts/exclamation-mark.sml deleted file mode 100644 index cd95cca..0000000 --- a/fonts/exclamation-mark.sml +++ /dev/null @@ -1,39 +0,0 @@ -structure ExclamationMark = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/new-fonts/exclamation_mark.sml b/fonts/exclamation_mark.sml similarity index 100% rename from new-fonts/exclamation_mark.sml rename to fonts/exclamation_mark.sml diff --git a/new-fonts/forward-slash.sml b/fonts/forward-slash.sml similarity index 100% rename from new-fonts/forward-slash.sml rename to fonts/forward-slash.sml diff --git a/fonts/hash.dsc b/fonts/hash.dsc deleted file mode 100644 index 5596e1a..0000000 --- a/fonts/hash.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x 0.333333283663 y ~0.333333283663 x 0.333333283663 y ~0.199999943376 x ~0.333333343267 y ~0.199999943376 -x ~0.333333343267 y ~0.199999943376 x ~0.333333343267 y ~0.333333283663 x 0.333333283663 y ~0.333333283663 -x 0.333333283663 y 0.0666666701436 x 0.333333283663 y 0.200000017881 x ~0.333333343267 y 0.200000017881 -x ~0.333333343267 y 0.200000017881 x ~0.333333343267 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 -x 0.199999943376 y ~0.599999964237 x 0.199999943376 y 0.466666638851 x 0.0666666701436 y 0.466666638851 -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 -x ~0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 -x ~0.200000017881 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y ~0.599999964237 diff --git a/new-fonts/left-angled-bracket.sml b/fonts/left-angled-bracket.sml similarity index 100% rename from new-fonts/left-angled-bracket.sml rename to fonts/left-angled-bracket.sml diff --git a/new-fonts/left-brace.sml b/fonts/left-brace.sml similarity index 100% rename from new-fonts/left-brace.sml rename to fonts/left-brace.sml diff --git a/new-fonts/left-bracket.sml b/fonts/left-bracket.sml similarity index 100% rename from new-fonts/left-bracket.sml rename to fonts/left-bracket.sml diff --git a/new-fonts/left-paren.sml b/fonts/left-paren.sml similarity index 100% rename from new-fonts/left-paren.sml rename to fonts/left-paren.sml diff --git a/fonts/lower-case-a.dsc b/fonts/lower-case-a.dsc deleted file mode 100644 index cce4517..0000000 --- a/fonts/lower-case-a.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 -x ~0.200000017881 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.466666638851 -x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y ~0.466666638851 -x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 -x 0.0666666701436 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.333333283663 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x 0.333333283663 y ~0.599999964237 x 0.333333283663 y 0.200000017881 x 0.199999943376 y 0.200000017881 diff --git a/fonts/lower-case-a.sml b/fonts/lower-case-a.sml index 1d4f984..78be494 100644 --- a/fonts/lower-case-a.sml +++ b/fonts/lower-case-a.sml @@ -1,75 +1,167 @@ -structure LowerCaseA = +structure LowerCaseA = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-b.dsc b/fonts/lower-case-b.dsc deleted file mode 100644 index 73abe15..0000000 --- a/fonts/lower-case-b.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x 0.333333283663 y ~0.466666638851 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 -x 0.199999943376 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x ~0.200000017881 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y 0.599999964237 -x ~0.333333343267 y 0.599999964237 x ~0.200000017881 y 0.599999964237 x ~0.200000017881 y ~0.599999964237 diff --git a/fonts/lower-case-b.sml b/fonts/lower-case-b.sml index b7450da..16150cd 100644 --- a/fonts/lower-case-b.sml +++ b/fonts/lower-case-b.sml @@ -1,63 +1,137 @@ -structure LowerCaseB = +structure LowerCaseB = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-c.dsc b/fonts/lower-case-c.dsc deleted file mode 100644 index 881d961..0000000 --- a/fonts/lower-case-c.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.199999943376 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.333333283663 y ~0.0666667371988 x 0.333333283663 y 0.0666666701436 -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x 0.333333283663 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.333333283663 diff --git a/fonts/lower-case-c.sml b/fonts/lower-case-c.sml index 2f332a5..4042e89 100644 --- a/fonts/lower-case-c.sml +++ b/fonts/lower-case-c.sml @@ -1,75 +1,167 @@ -structure LowerCaseC = +structure LowerCaseC = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-d.dsc b/fonts/lower-case-d.dsc deleted file mode 100644 index 366e3cc..0000000 --- a/fonts/lower-case-d.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x 0.199999943376 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x ~0.333333343267 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.0666666701436 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 x 0.333333283663 y 0.599999964237 -x 0.333333283663 y 0.599999964237 x 0.199999943376 y 0.599999964237 x 0.199999943376 y ~0.599999964237 diff --git a/fonts/lower-case-d.sml b/fonts/lower-case-d.sml index 789e177..7863e2e 100644 --- a/fonts/lower-case-d.sml +++ b/fonts/lower-case-d.sml @@ -1,63 +1,137 @@ -structure LowerCaseD = +structure LowerCaseD = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-e.dsc b/fonts/lower-case-e.dsc deleted file mode 100644 index feb61dd..0000000 --- a/fonts/lower-case-e.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x ~0.200000017881 y ~0.199999943376 x 0.199999943376 y ~0.199999943376 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y ~0.199999943376 -x 0.333333283663 y ~0.199999943376 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 -x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 -x 0.333333283663 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.333333283663 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 -x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 diff --git a/fonts/lower-case-e.sml b/fonts/lower-case-e.sml index 07544ad..9b0a022 100644 --- a/fonts/lower-case-e.sml +++ b/fonts/lower-case-e.sml @@ -1,87 +1,197 @@ -structure LowerCaseE = +structure LowerCaseE = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-f.dsc b/fonts/lower-case-f.dsc deleted file mode 100644 index cf8bb12..0000000 --- a/fonts/lower-case-f.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.599999964237 x 0.333333283663 y 0.599999964237 -x 0.333333283663 y 0.599999964237 x 0.333333283663 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 diff --git a/fonts/lower-case-f.sml b/fonts/lower-case-f.sml index 563a389..d2d7880 100644 --- a/fonts/lower-case-f.sml +++ b/fonts/lower-case-f.sml @@ -1,51 +1,107 @@ -structure LowerCaseF = +structure LowerCaseF = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-g.dsc b/fonts/lower-case-g.dsc deleted file mode 100644 index d0dbc9f..0000000 --- a/fonts/lower-case-g.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.199999943376 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.0666666701436 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x 0.333333283663 y 0.200000017881 x 0.333333283663 y ~0.866666674614 x 0.199999943376 y ~0.866666674614 -x 0.199999943376 y ~0.866666674614 x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 -x 0.199999943376 y ~0.866666674614 x ~0.200000017881 y ~0.866666674614 x ~0.200000017881 y ~1 -x ~0.200000017881 y ~1 x 0.199999943376 y ~1 x 0.199999943376 y ~0.866666674614 diff --git a/fonts/lower-case-g.sml b/fonts/lower-case-g.sml index a1bbf62..964dd36 100644 --- a/fonts/lower-case-g.sml +++ b/fonts/lower-case-g.sml @@ -1,75 +1,167 @@ -structure LowerCaseG = +structure LowerCaseG = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-h.dsc b/fonts/lower-case-h.dsc deleted file mode 100644 index e4292e7..0000000 --- a/fonts/lower-case-h.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.200000017881 x ~0.200000017881 y 0.200000017881 -x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 x 0.333333283663 y 0.0666666701436 -x ~0.333333343267 y 0.599999964237 x ~0.200000017881 y 0.599999964237 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y 0.599999964237 diff --git a/fonts/lower-case-h.sml b/fonts/lower-case-h.sml index d5525b4..6407538 100644 --- a/fonts/lower-case-h.sml +++ b/fonts/lower-case-h.sml @@ -1,51 +1,107 @@ -structure LowerCaseH = +structure LowerCaseH = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-i.dsc b/fonts/lower-case-i.dsc deleted file mode 100644 index 87a095a..0000000 --- a/fonts/lower-case-i.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x ~0.0666666701436 y 0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.466666638851 -x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y 0.200000017881 -x ~0.0666666701436 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.599999964237 diff --git a/fonts/lower-case-i.sml b/fonts/lower-case-i.sml index c5a5c83..a331b7b 100644 --- a/fonts/lower-case-i.sml +++ b/fonts/lower-case-i.sml @@ -1,63 +1,137 @@ -structure LowerCaseI = +structure LowerCaseI = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-j.dsc b/fonts/lower-case-j.dsc deleted file mode 100644 index d83e8ad..0000000 --- a/fonts/lower-case-j.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 x 0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.0666666701436 -x 0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y ~0.733333289623 -x 0.0666666701436 y ~0.733333289623 x 0.199999943376 y ~0.733333289623 x 0.199999943376 y 0.200000017881 -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.733333289623 x ~0.0666666701436 y ~0.733333289623 -x ~0.0666666701436 y ~0.733333289623 x ~0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 -x 0.0666666701436 y ~0.733333289623 x 0.0666666701436 y ~0.866666674614 x ~0.0666666701436 y ~0.866666674614 -x ~0.0666666701436 y ~0.866666674614 x ~0.0666666701436 y ~0.733333289623 x 0.0666666701436 y ~0.733333289623 diff --git a/fonts/lower-case-j.sml b/fonts/lower-case-j.sml index d15bf65..187543f 100644 --- a/fonts/lower-case-j.sml +++ b/fonts/lower-case-j.sml @@ -1,75 +1,137 @@ -structure LowerCaseJ = +structure LowerCaseJ = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-k.dsc b/fonts/lower-case-k.dsc deleted file mode 100644 index 48e58c4..0000000 --- a/fonts/lower-case-k.dsc +++ /dev/null @@ -1,14 +0,0 @@ -x 0.333333283663 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y ~0.466666638851 x 0.0666666701436 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.333333283663 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 x 0.333333283663 y 0.200000017881 -x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 -x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.333333283663 -x ~0.200000017881 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.199999943376 -x ~0.200000017881 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y 0.599999964237 -x ~0.333333343267 y 0.599999964237 x ~0.200000017881 y 0.599999964237 x ~0.200000017881 y ~0.599999964237 diff --git a/fonts/lower-case-k.sml b/fonts/lower-case-k.sml index e67d1e3..d74ffbb 100644 --- a/fonts/lower-case-k.sml +++ b/fonts/lower-case-k.sml @@ -1,99 +1,227 @@ -structure LowerCaseK = +structure LowerCaseK = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-l.dsc b/fonts/lower-case-l.dsc deleted file mode 100644 index 11efd4a..0000000 --- a/fonts/lower-case-l.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x ~0.0666666701436 y 0.599999964237 x ~0.200000017881 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 -x ~0.0666666701436 y 0.599999964237 x 0.0666666701436 y 0.599999964237 x 0.0666666701436 y ~0.599999964237 -x 0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y 0.599999964237 -x 0.0666666701436 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.466666638851 diff --git a/fonts/lower-case-l.sml b/fonts/lower-case-l.sml index 72dfcd2..b9ba805 100644 --- a/fonts/lower-case-l.sml +++ b/fonts/lower-case-l.sml @@ -1,51 +1,107 @@ -structure LowerCaseL = +structure LowerCaseL = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 1.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-m.dsc b/fonts/lower-case-m.dsc deleted file mode 100644 index de70288..0000000 --- a/fonts/lower-case-m.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y ~0.599999964237 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.0666666701436 x 0.199999943376 y 0.200000017881 -x 0.0666666701436 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.200000017881 -x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 -x ~0.0666666701436 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.0666666701436 -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 diff --git a/fonts/lower-case-m.sml b/fonts/lower-case-m.sml index 423a5e9..700c78a 100644 --- a/fonts/lower-case-m.sml +++ b/fonts/lower-case-m.sml @@ -1,75 +1,167 @@ -structure LowerCaseM = +structure LowerCaseM = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-n.dsc b/fonts/lower-case-n.dsc deleted file mode 100644 index 474c9d3..0000000 --- a/fonts/lower-case-n.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.333333283663 y ~0.599999964237 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.333333343267 y 0.200000017881 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.200000017881 diff --git a/fonts/lower-case-n.sml b/fonts/lower-case-n.sml index 474b935..9c9fc96 100644 --- a/fonts/lower-case-n.sml +++ b/fonts/lower-case-n.sml @@ -1,51 +1,107 @@ -structure LowerCaseN = +structure LowerCaseN = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-o.dsc b/fonts/lower-case-o.dsc deleted file mode 100644 index 82b9e05..0000000 --- a/fonts/lower-case-o.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 -x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y 0.0666666701436 -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/lower-case-o.sml b/fonts/lower-case-o.sml index c0587d7..ff49e3f 100644 --- a/fonts/lower-case-o.sml +++ b/fonts/lower-case-o.sml @@ -1,63 +1,137 @@ -structure LowerCaseO = +structure LowerCaseO = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-p.dsc b/fonts/lower-case-p.dsc deleted file mode 100644 index 0026ece..0000000 --- a/fonts/lower-case-p.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x 0.333333283663 y 0.0666666701436 x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x ~0.200000017881 y 0.200000017881 x ~0.333333343267 y 0.200000017881 x ~0.333333343267 y ~1 -x ~0.333333343267 y ~1 x ~0.200000017881 y ~1 x ~0.200000017881 y 0.200000017881 diff --git a/fonts/lower-case-p.sml b/fonts/lower-case-p.sml index 8e80eee..d90a5cb 100644 --- a/fonts/lower-case-p.sml +++ b/fonts/lower-case-p.sml @@ -1,63 +1,137 @@ -structure LowerCaseP = +structure LowerCaseP = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-q.dsc b/fonts/lower-case-q.dsc deleted file mode 100644 index d56fac0..0000000 --- a/fonts/lower-case-q.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 -x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 -x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y ~0.866666674614 x 0.333333283663 y ~0.866666674614 -x 0.333333283663 y ~0.866666674614 x 0.333333283663 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x 0.199999943376 y ~0.866666674614 x 0.466666638851 y ~0.866666674614 x 0.466666638851 y ~1 -x 0.466666638851 y ~1 x 0.199999943376 y ~1 x 0.199999943376 y ~0.866666674614 diff --git a/fonts/lower-case-q.sml b/fonts/lower-case-q.sml index 9782607..0523bcc 100644 --- a/fonts/lower-case-q.sml +++ b/fonts/lower-case-q.sml @@ -1,75 +1,167 @@ -structure LowerCaseQ = +structure LowerCaseQ = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.733333349228)) + (endX * 0.733333349228)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.733333349228)) + (endX * 0.733333349228)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.733333349228)) + (endX * 0.733333349228)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 6.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 6.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 6.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-r.dsc b/fonts/lower-case-r.dsc deleted file mode 100644 index c208fb8..0000000 --- a/fonts/lower-case-r.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.333333283663 y 0.0666666701436 x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.333333343267 y 0.200000017881 diff --git a/fonts/lower-case-r.sml b/fonts/lower-case-r.sml index 2ae4286..1a0841d 100644 --- a/fonts/lower-case-r.sml +++ b/fonts/lower-case-r.sml @@ -1,51 +1,107 @@ -structure LowerCaseR = +structure LowerCaseR = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-s.dsc b/fonts/lower-case-s.dsc deleted file mode 100644 index 6372da8..0000000 --- a/fonts/lower-case-s.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 x 0.333333283663 y 0.200000017881 -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.0666667371988 x 0.199999943376 y ~0.199999943376 -x 0.199999943376 y ~0.199999943376 x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 -x 0.333333283663 y ~0.199999943376 x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 -x 0.199999943376 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/lower-case-s.sml b/fonts/lower-case-s.sml index a0feee5..8858742 100644 --- a/fonts/lower-case-s.sml +++ b/fonts/lower-case-s.sml @@ -1,75 +1,167 @@ -structure LowerCaseS = +structure LowerCaseS = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-t.dsc b/fonts/lower-case-t.dsc deleted file mode 100644 index c71d08a..0000000 --- a/fonts/lower-case-t.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x ~0.200000017881 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y ~0.466666638851 -x ~0.0666666701436 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.466666638851 -x ~0.0666666701436 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.599999964237 -x 0.333333283663 y ~0.599999964237 x ~0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.466666638851 diff --git a/fonts/lower-case-t.sml b/fonts/lower-case-t.sml index 89fa087..665b6bf 100644 --- a/fonts/lower-case-t.sml +++ b/fonts/lower-case-t.sml @@ -1,51 +1,107 @@ -structure LowerCaseT = +structure LowerCaseT = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-u.dsc b/fonts/lower-case-u.dsc deleted file mode 100644 index c43c5c2..0000000 --- a/fonts/lower-case-u.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.333333283663 y 0.200000017881 x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 -x 0.333333283663 y ~0.599999964237 x 0.333333283663 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x ~0.200000017881 y 0.200000017881 x ~0.333333343267 y 0.200000017881 x ~0.333333343267 y ~0.466666638851 -x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.200000017881 diff --git a/fonts/lower-case-u.sml b/fonts/lower-case-u.sml index 94691ce..4a8f892 100644 --- a/fonts/lower-case-u.sml +++ b/fonts/lower-case-u.sml @@ -1,51 +1,107 @@ -structure LowerCaseU = +structure LowerCaseU = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-v.dsc b/fonts/lower-case-v.dsc deleted file mode 100644 index 7931f48..0000000 --- a/fonts/lower-case-v.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.599999964237 -x 0.333333283663 y 0.200000017881 x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 -x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x ~0.333333343267 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.200000017881 -x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.333333343267 y ~0.0666667371988 diff --git a/fonts/lower-case-v.sml b/fonts/lower-case-v.sml index 95836e6..4073b6c 100644 --- a/fonts/lower-case-v.sml +++ b/fonts/lower-case-v.sml @@ -1,75 +1,167 @@ -structure LowerCaseV = +structure LowerCaseV = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-w.dsc b/fonts/lower-case-w.dsc deleted file mode 100644 index ad84da6..0000000 --- a/fonts/lower-case-w.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y ~0.333333283663 -x 0.199999943376 y ~0.333333283663 x 0.333333283663 y ~0.333333283663 x 0.333333283663 y 0.200000017881 -x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y ~0.333333283663 -x ~0.200000017881 y ~0.333333283663 x ~0.333333343267 y ~0.333333283663 x ~0.333333343267 y 0.200000017881 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 diff --git a/fonts/lower-case-w.sml b/fonts/lower-case-w.sml index a35cc4e..5b4bc6e 100644 --- a/fonts/lower-case-w.sml +++ b/fonts/lower-case-w.sml @@ -1,75 +1,167 @@ -structure LowerCaseW = +structure LowerCaseW = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-x.dsc b/fonts/lower-case-x.dsc deleted file mode 100644 index dabf358..0000000 --- a/fonts/lower-case-x.dsc +++ /dev/null @@ -1,18 +0,0 @@ -x ~0.200000017881 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y ~0.0666667371988 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 -x ~0.333333343267 y 0.200000017881 x ~0.333333343267 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.200000017881 x ~0.333333343267 y 0.200000017881 -x 0.333333283663 y 0.200000017881 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 -x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 -x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.466666638851 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x ~0.0666666701436 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.333333283663 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 diff --git a/fonts/lower-case-x.sml b/fonts/lower-case-x.sml index 6f29944..1e96496 100644 --- a/fonts/lower-case-x.sml +++ b/fonts/lower-case-x.sml @@ -1,123 +1,287 @@ -structure LowerCaseX = +structure LowerCaseX = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-y.dsc b/fonts/lower-case-y.dsc deleted file mode 100644 index 280c6ba..0000000 --- a/fonts/lower-case-y.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x 0.333333283663 y ~0.866666674614 x 0.333333283663 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y ~0.866666674614 x 0.333333283663 y ~0.866666674614 -x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.200000017881 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x 0.199999943376 y ~0.866666674614 x ~0.200000017881 y ~0.866666674614 x ~0.200000017881 y ~1 -x ~0.200000017881 y ~1 x 0.199999943376 y ~1 x 0.199999943376 y ~0.866666674614 diff --git a/fonts/lower-case-y.sml b/fonts/lower-case-y.sml index 18b1e46..20d64e0 100644 --- a/fonts/lower-case-y.sml +++ b/fonts/lower-case-y.sml @@ -1,63 +1,137 @@ -structure LowerCaseY = +structure LowerCaseY = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.0)) + (endY * 0.0)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 13.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/lower-case-z.dsc b/fonts/lower-case-z.dsc deleted file mode 100644 index 5f76352..0000000 --- a/fonts/lower-case-z.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x ~0.333333343267 y 0.200000017881 x 0.333333283663 y 0.200000017881 x 0.333333283663 y 0.0666666701436 -x 0.333333283663 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y 0.200000017881 -x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 -x 0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.0666667371988 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.199999943376 x ~0.200000017881 y ~0.333333283663 -x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 -x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 -x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 -x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 diff --git a/fonts/lower-case-z.sml b/fonts/lower-case-z.sml index 33d1c2d..d846b9d 100644 --- a/fonts/lower-case-z.sml +++ b/fonts/lower-case-z.sml @@ -1,87 +1,197 @@ -structure LowerCaseZ = +structure LowerCaseZ = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/minus.dsc b/fonts/minus.dsc deleted file mode 100644 index 0d84e07..0000000 --- a/fonts/minus.dsc +++ /dev/null @@ -1,2 +0,0 @@ -x 0.333333283663 y ~0.199999943376 x 0.333333283663 y ~0.0666667371988 x ~0.333333343267 y ~0.0666667371988 -x ~0.333333343267 y ~0.0666667371988 x ~0.333333343267 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 diff --git a/fonts/percent.dsc b/fonts/percent.dsc deleted file mode 100644 index f364343..0000000 --- a/fonts/percent.dsc +++ /dev/null @@ -1,26 +0,0 @@ -x 0.333333283663 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.333333283663 -x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 -x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 -x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 -x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 -x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 -x ~0.333333343267 y ~0.333333283663 x ~0.333333343267 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 -x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.333333283663 x ~0.333333343267 y ~0.333333283663 -x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 -x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 -x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 -x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 -x 0.333333283663 y 0.200000017881 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.333333343267 -x ~0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.466666638851 x ~0.200000017881 y 0.466666638851 -x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 diff --git a/fonts/pipe.dsc b/fonts/pipe.dsc deleted file mode 100644 index cacec91..0000000 --- a/fonts/pipe.dsc +++ /dev/null @@ -1,2 +0,0 @@ -x 0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y ~0.866666674614 -x ~0.0666666701436 y ~0.866666674614 x 0.0666666701436 y ~0.866666674614 x 0.0666666701436 y 0.599999964237 diff --git a/fonts/plus.dsc b/fonts/plus.dsc deleted file mode 100644 index f2b2a5d..0000000 --- a/fonts/plus.dsc +++ /dev/null @@ -1,4 +0,0 @@ -x 0.333333283663 y ~0.0666667371988 x 0.333333283663 y ~0.199999943376 x ~0.333333343267 y ~0.199999943376 -x ~0.333333343267 y ~0.199999943376 x ~0.333333343267 y ~0.0666667371988 x 0.333333283663 y ~0.0666667371988 -x 0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y ~0.466666638851 -x ~0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y 0.200000017881 diff --git a/fonts/question-mark.dsc b/fonts/question-mark.dsc deleted file mode 100644 index 31f15cf..0000000 --- a/fonts/question-mark.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x ~0.200000017881 y 0.333333343267 x ~0.333333343267 y 0.333333343267 x ~0.333333343267 y 0.200000017881 -x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.333333343267 x 0.333333283663 y 0.333333343267 -x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 -x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 -x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 -x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 diff --git a/fonts/question-mark.sml b/fonts/question-mark.sml index bb58676..38f37fb 100644 --- a/fonts/question-mark.sml +++ b/fonts/question-mark.sml @@ -1,87 +1,197 @@ -structure QuestionMark = +structure QuestionMark = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/quotes-double.dsc b/fonts/quotes-double.dsc deleted file mode 100644 index 905ea76..0000000 --- a/fonts/quotes-double.dsc +++ /dev/null @@ -1,4 +0,0 @@ -x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.599999964237 x 0.0666666701436 y 0.599999964237 -x 0.0666666701436 y 0.599999964237 x 0.0666666701436 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.599999964237 x ~0.200000017881 y 0.599999964237 -x ~0.200000017881 y 0.599999964237 x ~0.200000017881 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 diff --git a/fonts/quotes-double.sml b/fonts/quotes-double.sml index dbb58a7..e1829b3 100644 --- a/fonts/quotes-double.sml +++ b/fonts/quotes-double.sml @@ -1,39 +1,77 @@ -structure QuotesDouble = +structure QuotesDouble = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/quotes-single.dsc b/fonts/quotes-single.dsc deleted file mode 100644 index 7478780..0000000 --- a/fonts/quotes-single.dsc +++ /dev/null @@ -1,2 +0,0 @@ -x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.599999964237 -x ~0.0666666701436 y 0.599999964237 x ~0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.200000017881 diff --git a/fonts/quotes-single.sml b/fonts/quotes-single.sml index dbebf3d..020cfef 100644 --- a/fonts/quotes-single.sml +++ b/fonts/quotes-single.sml @@ -1,27 +1,47 @@ -structure QuotesSingle = +structure QuotesSingle = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/new-fonts/right-angled-bracket.sml b/fonts/right-angled-bracket.sml similarity index 100% rename from new-fonts/right-angled-bracket.sml rename to fonts/right-angled-bracket.sml diff --git a/new-fonts/right-brace.sml b/fonts/right-brace.sml similarity index 100% rename from new-fonts/right-brace.sml rename to fonts/right-brace.sml diff --git a/new-fonts/right-bracket.sml b/fonts/right-bracket.sml similarity index 100% rename from new-fonts/right-bracket.sml rename to fonts/right-bracket.sml diff --git a/new-fonts/right-paren.sml b/fonts/right-paren.sml similarity index 100% rename from new-fonts/right-paren.sml rename to fonts/right-paren.sml diff --git a/fonts/semi-colon.sml b/fonts/semi-colon.sml deleted file mode 100644 index 67500a1..0000000 --- a/fonts/semi-colon.sml +++ /dev/null @@ -1,63 +0,0 @@ -structure Semicolon = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/new-fonts/semicolon.sml b/fonts/semicolon.sml similarity index 100% rename from new-fonts/semicolon.sml rename to fonts/semicolon.sml diff --git a/fonts/slash-backwards.dsc b/fonts/slash-backwards.dsc deleted file mode 100644 index 901593d..0000000 --- a/fonts/slash-backwards.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y ~0.733333289623 x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.733333289623 x 0.333333283663 y ~0.733333289623 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 -x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.599999964237 x ~0.333333343267 y 0.599999964237 -x ~0.333333343267 y 0.599999964237 x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 diff --git a/fonts/slash-backwards.sml b/fonts/slash-backwards.sml deleted file mode 100644 index 740c387..0000000 --- a/fonts/slash-backwards.sml +++ /dev/null @@ -1,75 +0,0 @@ -structure SlashBackwards = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/slash-forwards.dsc b/fonts/slash-forwards.dsc deleted file mode 100644 index f4e33aa..0000000 --- a/fonts/slash-forwards.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.333333343267 y ~0.733333289623 x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.733333289623 x ~0.333333343267 y ~0.733333289623 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 -x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 -x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 -x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.599999964237 x 0.333333283663 y 0.599999964237 -x 0.333333283663 y 0.599999964237 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 diff --git a/fonts/slash-forwards.sml b/fonts/slash-forwards.sml deleted file mode 100644 index 4da3d75..0000000 --- a/fonts/slash-forwards.sml +++ /dev/null @@ -1,75 +0,0 @@ -structure SlashForwards = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/space.sml b/fonts/space.sml deleted file mode 100644 index bf94a6e..0000000 --- a/fonts/space.sml +++ /dev/null @@ -1,5 +0,0 @@ -structure AsciiSpace = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - #[ ] -end diff --git a/fonts/square-bracket-closed.dsc b/fonts/square-bracket-closed.dsc deleted file mode 100644 index 5a84dbb..0000000 --- a/fonts/square-bracket-closed.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x ~0.200000017881 y 0.599999964237 x ~0.200000017881 y 0.466666638851 x 0.0666666701436 y 0.466666638851 -x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.599999964237 x ~0.200000017881 y 0.599999964237 -x ~0.200000017881 y ~0.733333289623 x 0.0666666701436 y ~0.733333289623 x 0.0666666701436 y ~0.866666674614 -x 0.0666666701436 y ~0.866666674614 x ~0.200000017881 y ~0.866666674614 x ~0.200000017881 y ~0.733333289623 -x 0.199999943376 y 0.599999964237 x 0.0666666701436 y 0.599999964237 x 0.0666666701436 y ~0.866666674614 -x 0.0666666701436 y ~0.866666674614 x 0.199999943376 y ~0.866666674614 x 0.199999943376 y 0.599999964237 diff --git a/fonts/square-bracket-closed.sml b/fonts/square-bracket-closed.sml deleted file mode 100644 index b446541..0000000 --- a/fonts/square-bracket-closed.sml +++ /dev/null @@ -1,51 +0,0 @@ -structure SquareBracketClosed = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/square-bracket-open.dsc b/fonts/square-bracket-open.dsc deleted file mode 100644 index 4464779..0000000 --- a/fonts/square-bracket-open.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.199999943376 y 0.599999964237 x 0.199999943376 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 -x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.599999964237 x 0.199999943376 y 0.599999964237 -x 0.199999943376 y ~0.733333289623 x ~0.0666666701436 y ~0.733333289623 x ~0.0666666701436 y ~0.866666674614 -x ~0.0666666701436 y ~0.866666674614 x 0.199999943376 y ~0.866666674614 x 0.199999943376 y ~0.733333289623 -x ~0.0666666701436 y 0.599999964237 x ~0.200000017881 y 0.599999964237 x ~0.200000017881 y ~0.866666674614 -x ~0.200000017881 y ~0.866666674614 x ~0.0666666701436 y ~0.866666674614 x ~0.0666666701436 y 0.599999964237 diff --git a/fonts/square-bracket-open.sml b/fonts/square-bracket-open.sml deleted file mode 100644 index b376e11..0000000 --- a/fonts/square-bracket-open.sml +++ /dev/null @@ -1,51 +0,0 @@ -structure SquareBracketOpen = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.066666662693)) + (endY * 0.066666662693)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/tilde.dsc b/fonts/tilde.dsc deleted file mode 100644 index 7b9a4d2..0000000 --- a/fonts/tilde.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y 0.0666666701436 x 0.333333283663 y ~0.199999943376 x 0.199999943376 y ~0.199999943376 -x 0.199999943376 y ~0.199999943376 x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 -x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.199999943376 -x 0.0666666701436 y ~0.199999943376 x 0.199999943376 y ~0.199999943376 x 0.199999943376 y ~0.333333283663 -x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 -x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y 0.0666666701436 -x ~0.200000017881 y ~0.0666667371988 x ~0.333333343267 y ~0.0666667371988 x ~0.333333343267 y ~0.333333283663 -x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.0666667371988 diff --git a/fonts/tilde.sml b/fonts/tilde.sml deleted file mode 100644 index d410e19..0000000 --- a/fonts/tilde.sml +++ /dev/null @@ -1,75 +0,0 @@ -structure AsciiTilde = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/fonts/underscore.dsc b/fonts/underscore.dsc deleted file mode 100644 index d5e0cfa..0000000 --- a/fonts/underscore.dsc +++ /dev/null @@ -1,2 +0,0 @@ -x 0.333333283663 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y ~0.733333289623 -x ~0.333333343267 y ~0.733333289623 x 0.333333283663 y ~0.733333289623 x 0.333333283663 y ~0.599999964237 diff --git a/fonts/underscore.sml b/fonts/underscore.sml index 50e86eb..d0f228c 100644 --- a/fonts/underscore.sml +++ b/fonts/underscore.sml @@ -1,27 +1,47 @@ -structure Underscore = +structure Underscore = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 12.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/unknown-char.dsc b/fonts/unknown-char.dsc deleted file mode 100644 index a3831e1..0000000 --- a/fonts/unknown-char.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x 0.599999964237 y ~0.466666638851 x 0.599999964237 y 0.466666638851 x 0.466666638851 y 0.466666638851 -x 0.466666638851 y 0.466666638851 x 0.466666638851 y ~0.466666638851 x 0.599999964237 y ~0.466666638851 -x 0.599999964237 y 0.599999964237 x ~0.466666668653 y 0.599999964237 x ~0.466666668653 y 0.466666638851 -x ~0.466666668653 y 0.466666638851 x 0.599999964237 y 0.466666638851 x 0.599999964237 y 0.599999964237 -x ~0.466666668653 y 0.599999964237 x ~0.466666668653 y ~0.466666638851 x ~0.599999964237 y ~0.466666638851 -x ~0.599999964237 y ~0.466666638851 x ~0.599999964237 y 0.599999964237 x ~0.466666668653 y 0.599999964237 -x 0.599999964237 y ~0.466666638851 x ~0.599999964237 y ~0.466666638851 x ~0.599999964237 y ~0.599999964237 -x ~0.599999964237 y ~0.599999964237 x 0.599999964237 y ~0.599999964237 x 0.599999964237 y ~0.466666638851 diff --git a/fonts/unknown-char.sml b/fonts/unknown-char.sml deleted file mode 100644 index 47dd9fd..0000000 --- a/fonts/unknown-char.sml +++ /dev/null @@ -1,63 +0,0 @@ -structure UnknownChar = -struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = - let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 - in - #[ (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.733333349228)) + (endX * 0.733333349228)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.733333349228)) + (endX * 0.733333349228)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.733333349228)) + (endX * 0.733333349228)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.200000017881)) + (endX * 0.200000017881)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.200000017881)) + (endX * 0.200000017881)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.200000017881)) + (endX * 0.200000017881)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.266666650772)) + (endX * 0.266666650772)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.799999952316)) + (endY * 0.799999952316)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.200000017881)) + (endX * 0.200000017881)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.200000017881)) + (endX * 0.200000017881)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.200000017881)) + (endX * 0.200000017881)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.799999952316)) + (endX * 0.799999952316)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file diff --git a/new-fonts/unknown.sml b/fonts/unknown.sml similarity index 100% rename from new-fonts/unknown.sml rename to fonts/unknown.sml diff --git a/fonts/upper-case-a.dsc b/fonts/upper-case-a.dsc deleted file mode 100644 index 05f4d77..0000000 --- a/fonts/upper-case-a.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x ~0.200000017881 y ~0.199999943376 x 0.199999943376 y ~0.199999943376 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y ~0.199999943376 -x 0.333333283663 y ~0.599999964237 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y 0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 -x ~0.200000017881 y 0.333333343267 x ~0.333333343267 y 0.333333343267 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.333333343267 diff --git a/fonts/upper-case-a.sml b/fonts/upper-case-a.sml index b429e83..f343d2f 100644 --- a/fonts/upper-case-a.sml +++ b/fonts/upper-case-a.sml @@ -1,63 +1,137 @@ -structure UpperCaseA = +structure UpperCaseA = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-b.dsc b/fonts/upper-case-b.dsc deleted file mode 100644 index 3155432..0000000 --- a/fonts/upper-case-b.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.333333343267 x 0.333333283663 y 0.333333343267 -x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.0666667371988 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 -x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 diff --git a/fonts/upper-case-b.sml b/fonts/upper-case-b.sml index b49b485..9f5ef7b 100644 --- a/fonts/upper-case-b.sml +++ b/fonts/upper-case-b.sml @@ -1,87 +1,197 @@ -structure UpperCaseB = +structure UpperCaseB = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-c.dsc b/fonts/upper-case-c.dsc deleted file mode 100644 index cfebfb5..0000000 --- a/fonts/upper-case-c.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 x 0.333333283663 y 0.333333343267 -x 0.333333283663 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.333333283663 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x ~0.200000017881 y 0.333333343267 x ~0.333333343267 y 0.333333343267 x ~0.333333343267 y ~0.466666638851 -x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.333333343267 diff --git a/fonts/upper-case-c.sml b/fonts/upper-case-c.sml index d4808a9..bd6186f 100644 --- a/fonts/upper-case-c.sml +++ b/fonts/upper-case-c.sml @@ -1,75 +1,167 @@ -structure UpperCaseC = +structure UpperCaseC = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-d.dsc b/fonts/upper-case-d.dsc deleted file mode 100644 index 041c3c3..0000000 --- a/fonts/upper-case-d.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x 0.333333283663 y 0.200000017881 x 0.333333283663 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 -x 0.199999943376 y ~0.333333283663 x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 -x ~0.200000017881 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.599999964237 -x 0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x 0.0666666701436 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.333333283663 -x 0.199999943376 y 0.200000017881 x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.333333343267 -x 0.0666666701436 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.200000017881 -x 0.0666666701436 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x ~0.200000017881 y 0.466666638851 x 0.0666666701436 y 0.466666638851 x 0.0666666701436 y 0.333333343267 -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 diff --git a/fonts/upper-case-d.sml b/fonts/upper-case-d.sml index 26c543d..e189e43 100644 --- a/fonts/upper-case-d.sml +++ b/fonts/upper-case-d.sml @@ -1,87 +1,197 @@ -structure UpperCaseD = +structure UpperCaseD = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-e.dsc b/fonts/upper-case-e.dsc deleted file mode 100644 index 82b6867..0000000 --- a/fonts/upper-case-e.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x 0.333333283663 y 0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.466666638851 -x 0.199999943376 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.0666666701436 -x 0.333333283663 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 x 0.333333283663 y ~0.466666638851 -x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 diff --git a/fonts/upper-case-e.sml b/fonts/upper-case-e.sml index ee361f2..50b0da8 100644 --- a/fonts/upper-case-e.sml +++ b/fonts/upper-case-e.sml @@ -1,63 +1,137 @@ -structure UpperCaseE = +structure UpperCaseE = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-f.dsc b/fonts/upper-case-f.dsc deleted file mode 100644 index 26793c4..0000000 --- a/fonts/upper-case-f.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x 0.333333283663 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x ~0.200000017881 y 0.466666638851 x 0.333333283663 y 0.466666638851 x 0.333333283663 y 0.333333343267 -x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 diff --git a/fonts/upper-case-f.sml b/fonts/upper-case-f.sml index c8613ad..b44fcf5 100644 --- a/fonts/upper-case-f.sml +++ b/fonts/upper-case-f.sml @@ -1,51 +1,107 @@ -structure UpperCaseF = +structure UpperCaseF = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-g.dsc b/fonts/upper-case-g.dsc deleted file mode 100644 index 17d2a31..0000000 --- a/fonts/upper-case-g.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 x 0.333333283663 y 0.333333343267 -x 0.333333283663 y ~0.466666638851 x 0.199999943376 y ~0.0666667371988 x 0.333333283663 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 -x 0.0666666701436 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.199999943376 -x 0.199999943376 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.0666667371988 -x 0.199999943376 y 0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 -x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.333333343267 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/upper-case-g.sml b/fonts/upper-case-g.sml index 6c37895..2c43b58 100644 --- a/fonts/upper-case-g.sml +++ b/fonts/upper-case-g.sml @@ -1,87 +1,197 @@ -structure UpperCaseG = +structure UpperCaseG = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-h.dsc b/fonts/upper-case-h.dsc deleted file mode 100644 index 4f69b33..0000000 --- a/fonts/upper-case-h.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.333333283663 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y 0.466666638851 -x 0.199999943376 y 0.466666638851 x 0.333333283663 y 0.466666638851 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 diff --git a/fonts/upper-case-h.sml b/fonts/upper-case-h.sml index aadeb65..797fac6 100644 --- a/fonts/upper-case-h.sml +++ b/fonts/upper-case-h.sml @@ -1,51 +1,107 @@ -structure UpperCaseH = +structure UpperCaseH = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-i.dsc b/fonts/upper-case-i.dsc deleted file mode 100644 index 2dcda73..0000000 --- a/fonts/upper-case-i.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 -x 0.0666666701436 y 0.333333343267 x 0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y ~0.466666638851 -x ~0.0666666701436 y ~0.466666638851 x ~0.0666666701436 y 0.333333343267 x 0.0666666701436 y 0.333333343267 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/upper-case-i.sml b/fonts/upper-case-i.sml index 264ac32..73c05c0 100644 --- a/fonts/upper-case-i.sml +++ b/fonts/upper-case-i.sml @@ -1,51 +1,107 @@ -structure UpperCaseI = +structure UpperCaseI = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-j.dsc b/fonts/upper-case-j.dsc deleted file mode 100644 index 235ebcf..0000000 --- a/fonts/upper-case-j.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x ~0.0666666701436 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 -x 0.199999943376 y 0.466666638851 x ~0.0666666701436 y 0.466666638851 x ~0.0666666701436 y 0.333333343267 -x 0.333333283663 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y 0.466666638851 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 -x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 diff --git a/fonts/upper-case-j.sml b/fonts/upper-case-j.sml index 5c09f78..94f6188 100644 --- a/fonts/upper-case-j.sml +++ b/fonts/upper-case-j.sml @@ -1,63 +1,137 @@ -structure UpperCaseJ = +structure UpperCaseJ = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-k.dsc b/fonts/upper-case-k.dsc deleted file mode 100644 index 095b869..0000000 --- a/fonts/upper-case-k.dsc +++ /dev/null @@ -1,14 +0,0 @@ -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 -x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.333333283663 y ~0.333333283663 x 0.333333283663 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.333333283663 x 0.333333283663 y ~0.333333283663 -x 0.333333283663 y 0.466666638851 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 x 0.333333283663 y 0.466666638851 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.200000017881 x 0.0666666701436 y 0.200000017881 -x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.200000017881 -x 0.0666666701436 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.0666667371988 -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 diff --git a/fonts/upper-case-k.sml b/fonts/upper-case-k.sml index 318b376..1e9a762 100644 --- a/fonts/upper-case-k.sml +++ b/fonts/upper-case-k.sml @@ -1,99 +1,227 @@ -structure UpperCaseK = +structure UpperCaseK = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-l.dsc b/fonts/upper-case-l.dsc deleted file mode 100644 index 56c986b..0000000 --- a/fonts/upper-case-l.dsc +++ /dev/null @@ -1,4 +0,0 @@ -x 0.333333283663 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 diff --git a/fonts/upper-case-l.sml b/fonts/upper-case-l.sml index 9da10aa..b27222a 100644 --- a/fonts/upper-case-l.sml +++ b/fonts/upper-case-l.sml @@ -1,39 +1,77 @@ -structure UpperCaseL = +structure UpperCaseL = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-m.dsc b/fonts/upper-case-m.dsc deleted file mode 100644 index 75cfa4c..0000000 --- a/fonts/upper-case-m.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y 0.466666638851 -x 0.199999943376 y 0.466666638851 x 0.333333283663 y 0.466666638851 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.200000017881 x 0.0666666701436 y 0.200000017881 -x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x ~0.0666666701436 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.0666666701436 y 0.200000017881 x ~0.0666666701436 y 0.333333343267 -x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 diff --git a/fonts/upper-case-m.sml b/fonts/upper-case-m.sml index 5c35ac6..9a41efa 100644 --- a/fonts/upper-case-m.sml +++ b/fonts/upper-case-m.sml @@ -1,75 +1,167 @@ -structure UpperCaseM = +structure UpperCaseM = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-n.dsc b/fonts/upper-case-n.dsc deleted file mode 100644 index 269b81c..0000000 --- a/fonts/upper-case-n.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 x 0.333333283663 y 0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 -x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.0666666701436 -x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 diff --git a/fonts/upper-case-n.sml b/fonts/upper-case-n.sml index aab7ccd..663cdb2 100644 --- a/fonts/upper-case-n.sml +++ b/fonts/upper-case-n.sml @@ -1,75 +1,167 @@ -structure UpperCaseN = +structure UpperCaseN = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-o.dsc b/fonts/upper-case-o.dsc deleted file mode 100644 index 518f82d..0000000 --- a/fonts/upper-case-o.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x 0.333333283663 y ~0.466666638851 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 -x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 -x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.333333343267 -x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 -x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/upper-case-o.sml b/fonts/upper-case-o.sml index 2a9eac6..45a394c 100644 --- a/fonts/upper-case-o.sml +++ b/fonts/upper-case-o.sml @@ -1,63 +1,137 @@ -structure UpperCaseO = +structure UpperCaseO = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-p.dsc b/fonts/upper-case-p.dsc deleted file mode 100644 index 0820212..0000000 --- a/fonts/upper-case-p.dsc +++ /dev/null @@ -1,8 +0,0 @@ -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y 0.333333343267 x 0.333333283663 y 0.333333343267 -x 0.199999943376 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.0666667371988 -x ~0.200000017881 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.199999943376 -x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y 0.466666638851 x ~0.200000017881 y 0.466666638851 diff --git a/fonts/upper-case-p.sml b/fonts/upper-case-p.sml index e434b57..329a43c 100644 --- a/fonts/upper-case-p.sml +++ b/fonts/upper-case-p.sml @@ -1,63 +1,137 @@ -structure UpperCaseP = +structure UpperCaseP = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-q.dsc b/fonts/upper-case-q.dsc deleted file mode 100644 index 1993ee2..0000000 --- a/fonts/upper-case-q.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x 0.333333283663 y ~0.333333283663 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y ~0.333333283663 x 0.333333283663 y ~0.333333283663 -x 0.199999943376 y 0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 -x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y 0.333333343267 -x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.466666638851 -x 0.0666666701436 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.333333283663 -x ~0.200000017881 y ~0.466666638851 x 0.0666666701436 y ~0.466666638851 x 0.0666666701436 y ~0.599999964237 -x 0.0666666701436 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.733333289623 -x 0.333333283663 y ~0.733333289623 x 0.199999943376 y ~0.733333289623 x 0.199999943376 y ~0.466666638851 diff --git a/fonts/upper-case-q.sml b/fonts/upper-case-q.sml index 127acbb..ab8179d 100644 --- a/fonts/upper-case-q.sml +++ b/fonts/upper-case-q.sml @@ -1,87 +1,197 @@ -structure UpperCaseQ = +structure UpperCaseQ = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.133333355188)) + (endY * 0.133333355188)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 11.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-r.dsc b/fonts/upper-case-r.dsc deleted file mode 100644 index c519e81..0000000 --- a/fonts/upper-case-r.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x ~0.200000017881 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.466666638851 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y 0.333333343267 x 0.333333283663 y 0.333333343267 -x ~0.200000017881 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y ~0.199999943376 x 0.199999943376 y ~0.199999943376 -x 0.199999943376 y ~0.199999943376 x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 -x 0.333333283663 y ~0.199999943376 x 0.333333283663 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 -x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 -x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y 0.466666638851 diff --git a/fonts/upper-case-r.sml b/fonts/upper-case-r.sml index 93ffde0..280f73b 100644 --- a/fonts/upper-case-r.sml +++ b/fonts/upper-case-r.sml @@ -1,87 +1,197 @@ -structure UpperCaseR = +structure UpperCaseR = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-s.dsc b/fonts/upper-case-s.dsc deleted file mode 100644 index 86607d3..0000000 --- a/fonts/upper-case-s.dsc +++ /dev/null @@ -1,14 +0,0 @@ -x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.333333283663 -x ~0.200000017881 y ~0.599999964237 x 0.199999943376 y ~0.599999964237 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y ~0.599999964237 -x 0.333333283663 y ~0.466666638851 x 0.333333283663 y ~0.0666667371988 x 0.199999943376 y ~0.0666667371988 -x 0.199999943376 y ~0.0666667371988 x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 -x 0.199999943376 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 -x ~0.333333343267 y 0.0666666701436 x ~0.333333343267 y 0.333333343267 x ~0.200000017881 y 0.333333343267 -x ~0.200000017881 y 0.333333343267 x ~0.200000017881 y 0.0666666701436 x ~0.333333343267 y 0.0666666701436 -x 0.333333283663 y 0.200000017881 x 0.333333283663 y 0.333333343267 x 0.199999943376 y 0.333333343267 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.200000017881 x 0.333333283663 y 0.200000017881 -x 0.199999943376 y 0.333333343267 x 0.199999943376 y 0.466666638851 x ~0.200000017881 y 0.466666638851 -x ~0.200000017881 y 0.466666638851 x ~0.200000017881 y 0.333333343267 x 0.199999943376 y 0.333333343267 diff --git a/fonts/upper-case-s.sml b/fonts/upper-case-s.sml index 71d07e6..a55b87c 100644 --- a/fonts/upper-case-s.sml +++ b/fonts/upper-case-s.sml @@ -1,99 +1,227 @@ -structure UpperCaseS = +structure UpperCaseS = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-t.dsc b/fonts/upper-case-t.dsc deleted file mode 100644 index b7986cf..0000000 --- a/fonts/upper-case-t.dsc +++ /dev/null @@ -1,4 +0,0 @@ -x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y 0.333333343267 x ~0.0666666701436 y 0.333333343267 -x ~0.0666666701436 y 0.333333343267 x ~0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 -x 0.333333283663 y 0.333333343267 x 0.333333283663 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y 0.333333343267 x 0.333333283663 y 0.333333343267 diff --git a/fonts/upper-case-t.sml b/fonts/upper-case-t.sml index a984595..f573958 100644 --- a/fonts/upper-case-t.sml +++ b/fonts/upper-case-t.sml @@ -1,39 +1,77 @@ -structure UpperCaseT = +structure UpperCaseT = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-u.dsc b/fonts/upper-case-u.dsc deleted file mode 100644 index 78957cf..0000000 --- a/fonts/upper-case-u.dsc +++ /dev/null @@ -1,6 +0,0 @@ -x 0.333333283663 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y ~0.466666638851 -x 0.199999943376 y ~0.466666638851 x 0.333333283663 y ~0.466666638851 x 0.333333283663 y 0.466666638851 -x 0.199999943376 y ~0.599999964237 x ~0.200000017881 y ~0.599999964237 x ~0.200000017881 y ~0.466666638851 -x ~0.200000017881 y ~0.466666638851 x 0.199999943376 y ~0.466666638851 x 0.199999943376 y ~0.599999964237 -x ~0.200000017881 y ~0.466666638851 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.200000017881 y ~0.466666638851 diff --git a/fonts/upper-case-u.sml b/fonts/upper-case-u.sml index a292d42..e0bf366 100644 --- a/fonts/upper-case-u.sml +++ b/fonts/upper-case-u.sml @@ -1,51 +1,107 @@ -structure UpperCaseU = +structure UpperCaseU = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-v.dsc b/fonts/upper-case-v.dsc deleted file mode 100644 index 3aefee0..0000000 --- a/fonts/upper-case-v.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 x 0.333333283663 y 0.466666638851 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 -x ~0.0666666701436 y ~0.333333283663 x ~0.0666666701436 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y ~0.333333283663 x ~0.0666666701436 y ~0.333333283663 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 diff --git a/fonts/upper-case-v.sml b/fonts/upper-case-v.sml index 9798d5d..d266c79 100644 --- a/fonts/upper-case-v.sml +++ b/fonts/upper-case-v.sml @@ -1,75 +1,167 @@ -structure UpperCaseV = +structure UpperCaseV = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-w.dsc b/fonts/upper-case-w.dsc deleted file mode 100644 index d378c83..0000000 --- a/fonts/upper-case-w.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x 0.333333283663 y 0.466666638851 x 0.199999943376 y 0.466666638851 x 0.199999943376 y ~0.199999943376 -x 0.199999943376 y ~0.199999943376 x 0.333333283663 y ~0.199999943376 x 0.333333283663 y 0.466666638851 -x 0.199999943376 y ~0.599999964237 x 0.0666666701436 y ~0.599999964237 x 0.0666666701436 y ~0.199999943376 -x 0.0666666701436 y ~0.199999943376 x 0.199999943376 y ~0.199999943376 x 0.199999943376 y ~0.599999964237 -x 0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y ~0.333333283663 -x ~0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 -x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y ~0.599999964237 x ~0.0666666701436 y ~0.599999964237 -x ~0.200000017881 y ~0.199999943376 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y ~0.199999943376 x ~0.200000017881 y ~0.199999943376 diff --git a/fonts/upper-case-w.sml b/fonts/upper-case-w.sml index bec134b..276153e 100644 --- a/fonts/upper-case-w.sml +++ b/fonts/upper-case-w.sml @@ -1,75 +1,167 @@ -structure UpperCaseW = +structure UpperCaseW = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 7.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-x.dsc b/fonts/upper-case-x.dsc deleted file mode 100644 index ee6eb20..0000000 --- a/fonts/upper-case-x.dsc +++ /dev/null @@ -1,18 +0,0 @@ -x 0.333333283663 y 0.466666638851 x 0.333333283663 y 0.200000017881 x 0.199999943376 y 0.200000017881 -x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.466666638851 x 0.333333283663 y 0.466666638851 -x 0.0666666701436 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.0666666701436 y 0.0666666701436 x 0.0666666701436 y 0.200000017881 -x 0.333333283663 y ~0.599999964237 x 0.333333283663 y ~0.333333283663 x 0.199999943376 y ~0.333333283663 -x 0.199999943376 y ~0.333333283663 x 0.199999943376 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 -x 0.199999943376 y ~0.199999943376 x 0.199999943376 y ~0.333333283663 x 0.0666666701436 y ~0.333333283663 -x 0.0666666701436 y ~0.333333283663 x 0.0666666701436 y ~0.199999943376 x 0.199999943376 y ~0.199999943376 -x ~0.333333343267 y ~0.599999964237 x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 -x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.599999964237 x ~0.333333343267 y ~0.599999964237 -x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.199999943376 x ~0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y ~0.199999943376 x ~0.0666666701436 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 -x 0.0666666701436 y ~0.199999943376 x 0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y ~0.199999943376 x 0.0666666701436 y ~0.199999943376 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y 0.200000017881 x ~0.200000017881 y 0.200000017881 -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.200000017881 y 0.200000017881 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y 0.200000017881 x ~0.200000017881 y 0.200000017881 diff --git a/fonts/upper-case-x.sml b/fonts/upper-case-x.sml index ad8a4c6..f67e3c8 100644 --- a/fonts/upper-case-x.sml +++ b/fonts/upper-case-x.sml @@ -1,123 +1,287 @@ -structure UpperCaseX = +structure UpperCaseX = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.400000035763)) + (endY * 0.400000035763)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-y.dsc b/fonts/upper-case-y.dsc deleted file mode 100644 index 829bac3..0000000 --- a/fonts/upper-case-y.dsc +++ /dev/null @@ -1,10 +0,0 @@ -x ~0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y ~0.599999964237 x ~0.0666666701436 y ~0.599999964237 -x ~0.200000017881 y ~0.0666667371988 x ~0.200000017881 y 0.0666666701436 x ~0.0666666701436 y 0.0666666701436 -x ~0.0666666701436 y 0.0666666701436 x ~0.0666666701436 y ~0.0666667371988 x ~0.200000017881 y ~0.0666667371988 -x 0.0666666701436 y ~0.0666667371988 x 0.0666666701436 y 0.0666666701436 x 0.199999943376 y 0.0666666701436 -x 0.199999943376 y 0.0666666701436 x 0.199999943376 y ~0.0666667371988 x 0.0666666701436 y ~0.0666667371988 -x 0.333333283663 y 0.0666666701436 x 0.333333283663 y 0.466666638851 x 0.199999943376 y 0.466666638851 -x 0.199999943376 y 0.466666638851 x 0.199999943376 y 0.0666666701436 x 0.333333283663 y 0.0666666701436 -x ~0.200000017881 y 0.0666666701436 x ~0.200000017881 y 0.466666638851 x ~0.333333343267 y 0.466666638851 -x ~0.333333343267 y 0.466666638851 x ~0.333333343267 y 0.0666666701436 x ~0.200000017881 y 0.0666666701436 diff --git a/fonts/upper-case-y.sml b/fonts/upper-case-y.sml index 22d3ccf..4ef2702 100644 --- a/fonts/upper-case-y.sml +++ b/fonts/upper-case-y.sml @@ -1,75 +1,167 @@ -structure UpperCaseY = +structure UpperCaseY = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.533333361149)) + (endY * 0.533333361149)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 5.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/fonts/upper-case-z.dsc b/fonts/upper-case-z.dsc deleted file mode 100644 index 114c3e2..0000000 --- a/fonts/upper-case-z.dsc +++ /dev/null @@ -1,12 +0,0 @@ -x ~0.333333343267 y 0.466666638851 x 0.333333283663 y 0.466666638851 x 0.333333283663 y 0.333333343267 -x 0.333333283663 y 0.333333343267 x ~0.333333343267 y 0.333333343267 x ~0.333333343267 y 0.466666638851 -x 0.199999943376 y 0.333333343267 x 0.0666666701436 y 0.333333343267 x 0.0666666701436 y 0.200000017881 -x 0.0666666701436 y 0.200000017881 x 0.199999943376 y 0.200000017881 x 0.199999943376 y 0.333333343267 -x 0.0666666701436 y 0.200000017881 x 0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 -x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y 0.200000017881 x 0.0666666701436 y 0.200000017881 -x ~0.0666666701436 y ~0.0666667371988 x ~0.0666666701436 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 -x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.0666667371988 x ~0.0666666701436 y ~0.0666667371988 -x ~0.200000017881 y ~0.333333283663 x ~0.200000017881 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 -x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.333333283663 x ~0.200000017881 y ~0.333333283663 -x 0.333333283663 y ~0.466666638851 x ~0.333333343267 y ~0.466666638851 x ~0.333333343267 y ~0.599999964237 -x ~0.333333343267 y ~0.599999964237 x 0.333333283663 y ~0.599999964237 x 0.333333283663 y ~0.466666638851 diff --git a/fonts/upper-case-z.sml b/fonts/upper-case-z.sml index 49aec50..fe855f3 100644 --- a/fonts/upper-case-z.sml +++ b/fonts/upper-case-z.sml @@ -1,87 +1,197 @@ -structure UpperCaseZ = +structure UpperCaseZ = struct - fun lerp (startX, startY, drawWidth, drawHeight, windowWidth, windowHeight, r, g, b) : Real32.real vector = + fun xToNdc (xOffset, xpos, scale, halfWidth) = + ((xpos * scale + xOffset) - halfWidth) / halfWidth + + fun yToNdc (yOffset, ypos, scale, halfHeight) = + ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) + + fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = let - val startX = Real32.fromInt startX - val startY = Real32.fromInt startY - val endY = windowHeight - startY - val startY = windowHeight - (startY + drawHeight) - val endX = startX + drawWidth - val windowHeight = windowHeight / 2.0 - val windowWidth = windowWidth / 2.0 + val halfWidth = windowWidth / 2.0 + val halfHeight = windowHeight / 2.0 in - #[ (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.733333349228)) + (endY * 0.733333349228)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.599999964237)) + (endX * 0.599999964237)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.666666686535)) + (endY * 0.666666686535)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.533333361149)) + (endX * 0.533333361149)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.600000023842)) + (endY * 0.600000023842)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.466666668653)) + (endX * 0.466666668653)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.466666638851)) + (endY * 0.466666638851)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.399999976158)) + (endX * 0.399999976158)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.33333337307)) + (endY * 0.33333337307)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.333333313465)) + (endX * 0.333333313465)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.200000017881)) + (endY * 0.200000017881)) / windowHeight) - 1.0, r, g, b, - (((startX * (1.0 - 0.66666662693)) + (endX * 0.66666662693)) / windowWidth) - 1.0, - (((startY * (1.0 - 0.266666680574)) + (endY * 0.266666680574)) / windowHeight) - 1.0, r, g, b - ] - end -end \ No newline at end of file + #[ +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 3.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 0.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 10.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 5.000000000000000, scale, halfWidth), +yToNdc (yOffset, 9.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 1.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 8.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 2.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 6.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 3.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 4.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000, +xToNdc (xOffset, 4.000000000000000, scale, halfWidth), +yToNdc (yOffset, 2.000000000000000, scale, halfHeight), +0.000000000000000, +0.000000000000000, +0.000000000000000 + ] + end +end diff --git a/new-fonts/ampersand.sml b/new-fonts/ampersand.sml deleted file mode 100644 index b7dc044..0000000 --- a/new-fonts/ampersand.sml +++ /dev/null @@ -1,317 +0,0 @@ -structure Ampersand = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-at.sml b/new-fonts/ascii-at.sml deleted file mode 100644 index 407488b..0000000 --- a/new-fonts/ascii-at.sml +++ /dev/null @@ -1,227 +0,0 @@ -structure AsciiAt = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-dot.sml b/new-fonts/ascii-dot.sml deleted file mode 100644 index 4c4ded7..0000000 --- a/new-fonts/ascii-dot.sml +++ /dev/null @@ -1,47 +0,0 @@ -structure AsciiDot = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-eight.sml b/new-fonts/ascii-eight.sml deleted file mode 100644 index 6c0fa15..0000000 --- a/new-fonts/ascii-eight.sml +++ /dev/null @@ -1,227 +0,0 @@ -structure AsciiEight = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-five.sml b/new-fonts/ascii-five.sml deleted file mode 100644 index 96ab8ed..0000000 --- a/new-fonts/ascii-five.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure AsciiFive = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-four.sml b/new-fonts/ascii-four.sml deleted file mode 100644 index 49a935f..0000000 --- a/new-fonts/ascii-four.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure AsciiFour = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 6.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 6.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 6.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-hash.sml b/new-fonts/ascii-hash.sml deleted file mode 100644 index 9de6958..0000000 --- a/new-fonts/ascii-hash.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure AsciiHash = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-minus.sml b/new-fonts/ascii-minus.sml deleted file mode 100644 index f4cc2ae..0000000 --- a/new-fonts/ascii-minus.sml +++ /dev/null @@ -1,47 +0,0 @@ -structure AsciiMinus = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-nine.sml b/new-fonts/ascii-nine.sml deleted file mode 100644 index 8e8cec7..0000000 --- a/new-fonts/ascii-nine.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure AsciiNine = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-one.sml b/new-fonts/ascii-one.sml deleted file mode 100644 index 78bb259..0000000 --- a/new-fonts/ascii-one.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure AsciiOne = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-percent.sml b/new-fonts/ascii-percent.sml deleted file mode 100644 index 61f47ec..0000000 --- a/new-fonts/ascii-percent.sml +++ /dev/null @@ -1,407 +0,0 @@ -structure AsciiPercent = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-pipe.sml b/new-fonts/ascii-pipe.sml deleted file mode 100644 index 2b351d7..0000000 --- a/new-fonts/ascii-pipe.sml +++ /dev/null @@ -1,47 +0,0 @@ -structure AsciiPipe = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-plus.sml b/new-fonts/ascii-plus.sml deleted file mode 100644 index a63b24a..0000000 --- a/new-fonts/ascii-plus.sml +++ /dev/null @@ -1,77 +0,0 @@ -structure AsciiPlus = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-seven.sml b/new-fonts/ascii-seven.sml deleted file mode 100644 index cbadace..0000000 --- a/new-fonts/ascii-seven.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure AsciiSeven = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-six.sml b/new-fonts/ascii-six.sml deleted file mode 100644 index 8235545..0000000 --- a/new-fonts/ascii-six.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure AsciiSix = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-three.sml b/new-fonts/ascii-three.sml deleted file mode 100644 index 9b8e88f..0000000 --- a/new-fonts/ascii-three.sml +++ /dev/null @@ -1,227 +0,0 @@ -structure AsciiThree = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-two.sml b/new-fonts/ascii-two.sml deleted file mode 100644 index 155e8e7..0000000 --- a/new-fonts/ascii-two.sml +++ /dev/null @@ -1,257 +0,0 @@ -structure AsciiTwo = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/ascii-zero.sml b/new-fonts/ascii-zero.sml deleted file mode 100644 index 48915c9..0000000 --- a/new-fonts/ascii-zero.sml +++ /dev/null @@ -1,168 +0,0 @@ -structure AsciiZero = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight): Real32.real - vector = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/asterisk.sml b/new-fonts/asterisk.sml deleted file mode 100644 index 11c7444..0000000 --- a/new-fonts/asterisk.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure Asterisk = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/backtick.sml b/new-fonts/backtick.sml deleted file mode 100644 index fc43186..0000000 --- a/new-fonts/backtick.sml +++ /dev/null @@ -1,77 +0,0 @@ -structure Backtick = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/caret.sml b/new-fonts/caret.sml deleted file mode 100644 index 8c91924..0000000 --- a/new-fonts/caret.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure Caret = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/colon.sml b/new-fonts/colon.sml deleted file mode 100644 index 728fb86..0000000 --- a/new-fonts/colon.sml +++ /dev/null @@ -1,77 +0,0 @@ -structure Colon = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/comma.sml b/new-fonts/comma.sml deleted file mode 100644 index 158e474..0000000 --- a/new-fonts/comma.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure Comma = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/cozette-ascii.mlb b/new-fonts/cozette-ascii.mlb deleted file mode 100644 index bfc9fef..0000000 --- a/new-fonts/cozette-ascii.mlb +++ /dev/null @@ -1,105 +0,0 @@ -$(SML_LIB)/basis/basis.mlb -ann - "allowVectorExps true" -in - local - ascii-zero.sml - ascii-one.sml - ascii-two.sml - ascii-three.sml - ascii-four.sml - ascii-five.sml - ascii-six.sml - ascii-seven.sml - ascii-eight.sml - ascii-nine.sml - ascii-space.sml - ampersand.sml - asterisk.sml - ascii-at.sml - backtick.sml - backward-slash.sml - caret.sml - colon.sml - comma.sml - dollar.sml - quotes-double.sml - equals.sml - exclamation_mark.sml - forward-slash.sml - ascii-dot.sml - ascii-hash.sml - left-angled-bracket.sml - left-brace.sml - left-bracket.sml - left-paren.sml - lower-case-a.sml - lower-case-b.sml - lower-case-c.sml - lower-case-d.sml - lower-case-e.sml - lower-case-f.sml - lower-case-g.sml - lower-case-h.sml - lower-case-i.sml - lower-case-j.sml - lower-case-k.sml - lower-case-l.sml - lower-case-m.sml - lower-case-n.sml - lower-case-o.sml - lower-case-p.sml - lower-case-q.sml - lower-case-r.sml - lower-case-s.sml - lower-case-t.sml - lower-case-u.sml - lower-case-v.sml - lower-case-w.sml - lower-case-x.sml - lower-case-y.sml - lower-case-z.sml - ascii-minus.sml - ascii-percent.sml - ascii-pipe.sml - ascii-plus.sml - question-mark.sml - right-angled-bracket.sml - right-brace.sml - right-bracket.sml - right-paren.sml - semicolon.sml - quotes-single.sml - ascii-tilde.sml - underscore.sml - unknown.sml - upper-case-a.sml - upper-case-b.sml - upper-case-c.sml - upper-case-d.sml - upper-case-e.sml - upper-case-f.sml - upper-case-g.sml - upper-case-h.sml - upper-case-i.sml - upper-case-j.sml - upper-case-k.sml - upper-case-l.sml - upper-case-m.sml - upper-case-n.sml - upper-case-o.sml - upper-case-p.sml - upper-case-q.sml - upper-case-r.sml - upper-case-s.sml - upper-case-t.sml - upper-case-u.sml - upper-case-v.sml - upper-case-w.sml - upper-case-x.sml - upper-case-y.sml - upper-case-z.sml - in - cozette-ascii.sml - end -end diff --git a/new-fonts/cozette-ascii.sml b/new-fonts/cozette-ascii.sml deleted file mode 100644 index 546bf08..0000000 --- a/new-fonts/cozette-ascii.sml +++ /dev/null @@ -1,253 +0,0 @@ -structure CozetteAscii = -struct - val asciiTable = #[ - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - AsciiSpace.lerp, - ExclamationMark.lerp, - QuotesDouble.lerp, - AsciiHash.lerp, - Dollar.lerp, - AsciiPercent.lerp, - Ampersand.lerp, - QuotesSingle.lerp, - LeftParen.lerp, - RightParen.lerp, - Asterisk.lerp, - AsciiPlus.lerp, - Comma.lerp, - AsciiMinus.lerp, - AsciiDot.lerp, - ForwardSlash.lerp, - AsciiZero.lerp, - AsciiOne.lerp, - AsciiTwo.lerp, - AsciiThree.lerp, - AsciiFour.lerp, - AsciiFive.lerp, - AsciiSix.lerp, - AsciiSeven.lerp, - AsciiEight.lerp, - AsciiNine.lerp, - Colon.lerp, - Semicolon.lerp, - LeftAngledBracket.lerp, - AsciiEquals.lerp, - RightAngledBracket.lerp, - QuestionMark.lerp, - AsciiAt.lerp, - UpperCaseA.lerp, - UpperCaseB.lerp, - UpperCaseC.lerp, - UpperCaseD.lerp, - UpperCaseE.lerp, - UpperCaseF.lerp, - UpperCaseG.lerp, - UpperCaseH.lerp, - UpperCaseI.lerp, - UpperCaseJ.lerp, - UpperCaseK.lerp, - UpperCaseL.lerp, - UpperCaseM.lerp, - UpperCaseN.lerp, - UpperCaseO.lerp, - UpperCaseP.lerp, - UpperCaseQ.lerp, - UpperCaseR.lerp, - UpperCaseS.lerp, - UpperCaseT.lerp, - UpperCaseU.lerp, - UpperCaseV.lerp, - UpperCaseW.lerp, - UpperCaseX.lerp, - UpperCaseY.lerp, - UpperCaseZ.lerp, - LeftBracket.lerp, - BackwardSlash.lerp, - RightBracket.lerp, - Caret.lerp, - Underscore.lerp, - Backtick.lerp, - LowerCaseA.lerp, - LowerCaseB.lerp, - LowerCaseC.lerp, - LowerCaseD.lerp, - LowerCaseE.lerp, - LowerCaseF.lerp, - LowerCaseG.lerp, - LowerCaseH.lerp, - LowerCaseI.lerp, - LowerCaseJ.lerp, - LowerCaseK.lerp, - LowerCaseL.lerp, - LowerCaseM.lerp, - LowerCaseN.lerp, - LowerCaseO.lerp, - LowerCaseP.lerp, - LowerCaseQ.lerp, - LowerCaseR.lerp, - LowerCaseS.lerp, - LowerCaseT.lerp, - LowerCaseU.lerp, - LowerCaseV.lerp, - LowerCaseW.lerp, - LowerCaseX.lerp, - LowerCaseY.lerp, - LowerCaseZ.lerp, - LeftBrace.lerp, - AsciiPipe.lerp, - RightBrace.lerp, - AsciiTilde.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp, - Unknown.lerp - ] -end diff --git a/new-fonts/dollar.sml b/new-fonts/dollar.sml deleted file mode 100644 index 78c70e5..0000000 --- a/new-fonts/dollar.sml +++ /dev/null @@ -1,257 +0,0 @@ -structure Dollar = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-a.sml b/new-fonts/lower-case-a.sml deleted file mode 100644 index 78be494..0000000 --- a/new-fonts/lower-case-a.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure LowerCaseA = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-b.sml b/new-fonts/lower-case-b.sml deleted file mode 100644 index 16150cd..0000000 --- a/new-fonts/lower-case-b.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure LowerCaseB = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-c.sml b/new-fonts/lower-case-c.sml deleted file mode 100644 index 4042e89..0000000 --- a/new-fonts/lower-case-c.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure LowerCaseC = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-d.sml b/new-fonts/lower-case-d.sml deleted file mode 100644 index 7863e2e..0000000 --- a/new-fonts/lower-case-d.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure LowerCaseD = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-e.sml b/new-fonts/lower-case-e.sml deleted file mode 100644 index 9b0a022..0000000 --- a/new-fonts/lower-case-e.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure LowerCaseE = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-f.sml b/new-fonts/lower-case-f.sml deleted file mode 100644 index d2d7880..0000000 --- a/new-fonts/lower-case-f.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure LowerCaseF = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-g.sml b/new-fonts/lower-case-g.sml deleted file mode 100644 index 964dd36..0000000 --- a/new-fonts/lower-case-g.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure LowerCaseG = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-h.sml b/new-fonts/lower-case-h.sml deleted file mode 100644 index 6407538..0000000 --- a/new-fonts/lower-case-h.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure LowerCaseH = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-i.sml b/new-fonts/lower-case-i.sml deleted file mode 100644 index a331b7b..0000000 --- a/new-fonts/lower-case-i.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure LowerCaseI = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-j.sml b/new-fonts/lower-case-j.sml deleted file mode 100644 index 187543f..0000000 --- a/new-fonts/lower-case-j.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure LowerCaseJ = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-k.sml b/new-fonts/lower-case-k.sml deleted file mode 100644 index d74ffbb..0000000 --- a/new-fonts/lower-case-k.sml +++ /dev/null @@ -1,227 +0,0 @@ -structure LowerCaseK = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-l.sml b/new-fonts/lower-case-l.sml deleted file mode 100644 index b9ba805..0000000 --- a/new-fonts/lower-case-l.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure LowerCaseL = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 1.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-m.sml b/new-fonts/lower-case-m.sml deleted file mode 100644 index 700c78a..0000000 --- a/new-fonts/lower-case-m.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure LowerCaseM = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-n.sml b/new-fonts/lower-case-n.sml deleted file mode 100644 index 9c9fc96..0000000 --- a/new-fonts/lower-case-n.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure LowerCaseN = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-o.sml b/new-fonts/lower-case-o.sml deleted file mode 100644 index ff49e3f..0000000 --- a/new-fonts/lower-case-o.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure LowerCaseO = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-p.sml b/new-fonts/lower-case-p.sml deleted file mode 100644 index d90a5cb..0000000 --- a/new-fonts/lower-case-p.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure LowerCaseP = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-q.sml b/new-fonts/lower-case-q.sml deleted file mode 100644 index 0523bcc..0000000 --- a/new-fonts/lower-case-q.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure LowerCaseQ = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 6.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 6.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 6.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-r.sml b/new-fonts/lower-case-r.sml deleted file mode 100644 index 1a0841d..0000000 --- a/new-fonts/lower-case-r.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure LowerCaseR = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-s.sml b/new-fonts/lower-case-s.sml deleted file mode 100644 index 8858742..0000000 --- a/new-fonts/lower-case-s.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure LowerCaseS = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-t.sml b/new-fonts/lower-case-t.sml deleted file mode 100644 index 665b6bf..0000000 --- a/new-fonts/lower-case-t.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure LowerCaseT = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-u.sml b/new-fonts/lower-case-u.sml deleted file mode 100644 index 4a8f892..0000000 --- a/new-fonts/lower-case-u.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure LowerCaseU = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-v.sml b/new-fonts/lower-case-v.sml deleted file mode 100644 index 4073b6c..0000000 --- a/new-fonts/lower-case-v.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure LowerCaseV = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-w.sml b/new-fonts/lower-case-w.sml deleted file mode 100644 index 5b4bc6e..0000000 --- a/new-fonts/lower-case-w.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure LowerCaseW = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-x.sml b/new-fonts/lower-case-x.sml deleted file mode 100644 index 1e96496..0000000 --- a/new-fonts/lower-case-x.sml +++ /dev/null @@ -1,287 +0,0 @@ -structure LowerCaseX = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-y.sml b/new-fonts/lower-case-y.sml deleted file mode 100644 index 20d64e0..0000000 --- a/new-fonts/lower-case-y.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure LowerCaseY = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 13.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/lower-case-z.sml b/new-fonts/lower-case-z.sml deleted file mode 100644 index d846b9d..0000000 --- a/new-fonts/lower-case-z.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure LowerCaseZ = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/question-mark.sml b/new-fonts/question-mark.sml deleted file mode 100644 index 38f37fb..0000000 --- a/new-fonts/question-mark.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure QuestionMark = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/quotes-double.sml b/new-fonts/quotes-double.sml deleted file mode 100644 index e1829b3..0000000 --- a/new-fonts/quotes-double.sml +++ /dev/null @@ -1,77 +0,0 @@ -structure QuotesDouble = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/quotes-single.sml b/new-fonts/quotes-single.sml deleted file mode 100644 index 020cfef..0000000 --- a/new-fonts/quotes-single.sml +++ /dev/null @@ -1,47 +0,0 @@ -structure QuotesSingle = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/underscore.sml b/new-fonts/underscore.sml deleted file mode 100644 index d0f228c..0000000 --- a/new-fonts/underscore.sml +++ /dev/null @@ -1,47 +0,0 @@ -structure Underscore = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 12.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-a.sml b/new-fonts/upper-case-a.sml deleted file mode 100644 index f343d2f..0000000 --- a/new-fonts/upper-case-a.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure UpperCaseA = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-b.sml b/new-fonts/upper-case-b.sml deleted file mode 100644 index 9f5ef7b..0000000 --- a/new-fonts/upper-case-b.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure UpperCaseB = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-c.sml b/new-fonts/upper-case-c.sml deleted file mode 100644 index bd6186f..0000000 --- a/new-fonts/upper-case-c.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure UpperCaseC = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-d.sml b/new-fonts/upper-case-d.sml deleted file mode 100644 index e189e43..0000000 --- a/new-fonts/upper-case-d.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure UpperCaseD = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-e.sml b/new-fonts/upper-case-e.sml deleted file mode 100644 index 50b0da8..0000000 --- a/new-fonts/upper-case-e.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure UpperCaseE = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-f.sml b/new-fonts/upper-case-f.sml deleted file mode 100644 index b44fcf5..0000000 --- a/new-fonts/upper-case-f.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure UpperCaseF = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-g.sml b/new-fonts/upper-case-g.sml deleted file mode 100644 index 2c43b58..0000000 --- a/new-fonts/upper-case-g.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure UpperCaseG = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-h.sml b/new-fonts/upper-case-h.sml deleted file mode 100644 index 797fac6..0000000 --- a/new-fonts/upper-case-h.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure UpperCaseH = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-i.sml b/new-fonts/upper-case-i.sml deleted file mode 100644 index 73c05c0..0000000 --- a/new-fonts/upper-case-i.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure UpperCaseI = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-j.sml b/new-fonts/upper-case-j.sml deleted file mode 100644 index 94f6188..0000000 --- a/new-fonts/upper-case-j.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure UpperCaseJ = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-k.sml b/new-fonts/upper-case-k.sml deleted file mode 100644 index 1e9a762..0000000 --- a/new-fonts/upper-case-k.sml +++ /dev/null @@ -1,227 +0,0 @@ -structure UpperCaseK = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-l.sml b/new-fonts/upper-case-l.sml deleted file mode 100644 index b27222a..0000000 --- a/new-fonts/upper-case-l.sml +++ /dev/null @@ -1,77 +0,0 @@ -structure UpperCaseL = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-m.sml b/new-fonts/upper-case-m.sml deleted file mode 100644 index 9a41efa..0000000 --- a/new-fonts/upper-case-m.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure UpperCaseM = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-n.sml b/new-fonts/upper-case-n.sml deleted file mode 100644 index 663cdb2..0000000 --- a/new-fonts/upper-case-n.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure UpperCaseN = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-o.sml b/new-fonts/upper-case-o.sml deleted file mode 100644 index 45a394c..0000000 --- a/new-fonts/upper-case-o.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure UpperCaseO = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-p.sml b/new-fonts/upper-case-p.sml deleted file mode 100644 index 329a43c..0000000 --- a/new-fonts/upper-case-p.sml +++ /dev/null @@ -1,137 +0,0 @@ -structure UpperCaseP = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-q.sml b/new-fonts/upper-case-q.sml deleted file mode 100644 index ab8179d..0000000 --- a/new-fonts/upper-case-q.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure UpperCaseQ = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 11.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-r.sml b/new-fonts/upper-case-r.sml deleted file mode 100644 index 280f73b..0000000 --- a/new-fonts/upper-case-r.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure UpperCaseR = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-s.sml b/new-fonts/upper-case-s.sml deleted file mode 100644 index a55b87c..0000000 --- a/new-fonts/upper-case-s.sml +++ /dev/null @@ -1,227 +0,0 @@ -structure UpperCaseS = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-t.sml b/new-fonts/upper-case-t.sml deleted file mode 100644 index f573958..0000000 --- a/new-fonts/upper-case-t.sml +++ /dev/null @@ -1,77 +0,0 @@ -structure UpperCaseT = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-u.sml b/new-fonts/upper-case-u.sml deleted file mode 100644 index e0bf366..0000000 --- a/new-fonts/upper-case-u.sml +++ /dev/null @@ -1,107 +0,0 @@ -structure UpperCaseU = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-v.sml b/new-fonts/upper-case-v.sml deleted file mode 100644 index d266c79..0000000 --- a/new-fonts/upper-case-v.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure UpperCaseV = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-w.sml b/new-fonts/upper-case-w.sml deleted file mode 100644 index 276153e..0000000 --- a/new-fonts/upper-case-w.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure UpperCaseW = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 7.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-x.sml b/new-fonts/upper-case-x.sml deleted file mode 100644 index f67e3c8..0000000 --- a/new-fonts/upper-case-x.sml +++ /dev/null @@ -1,287 +0,0 @@ -structure UpperCaseX = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-y.sml b/new-fonts/upper-case-y.sml deleted file mode 100644 index 4ef2702..0000000 --- a/new-fonts/upper-case-y.sml +++ /dev/null @@ -1,167 +0,0 @@ -structure UpperCaseY = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 5.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end diff --git a/new-fonts/upper-case-z.sml b/new-fonts/upper-case-z.sml deleted file mode 100644 index fe855f3..0000000 --- a/new-fonts/upper-case-z.sml +++ /dev/null @@ -1,197 +0,0 @@ -structure UpperCaseZ = -struct - fun xToNdc (xOffset, xpos, scale, halfWidth) = - ((xpos * scale + xOffset) - halfWidth) / halfWidth - - fun yToNdc (yOffset, ypos, scale, halfHeight) = - ~(((ypos * scale + yOffset) - halfHeight) / halfHeight) - - fun lerp (xOffset: Real32.real, yOffset, scale, windowWidth, windowHeight) = - let - val halfWidth = windowWidth / 2.0 - val halfHeight = windowHeight / 2.0 - in - #[ -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 3.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 0.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 10.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 5.000000000000000, scale, halfWidth), -yToNdc (yOffset, 9.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 1.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 8.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 2.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 6.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 3.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 4.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000, -xToNdc (xOffset, 4.000000000000000, scale, halfWidth), -yToNdc (yOffset, 2.000000000000000, scale, halfHeight), -0.000000000000000, -0.000000000000000, -0.000000000000000 - ] - end -end