diff --git a/dotscape b/dotscape index d82b79b..dd33a02 100755 Binary files a/dotscape and b/dotscape differ diff --git a/fonts/unknown-char.dsc b/fonts/unknown-char.dsc new file mode 100644 index 0000000..a3831e1 --- /dev/null +++ b/fonts/unknown-char.dsc @@ -0,0 +1,8 @@ +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 new file mode 100644 index 0000000..47dd9fd --- /dev/null +++ b/fonts/unknown-char.sml @@ -0,0 +1,63 @@ +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/imperative-shell/file-thread.sml b/imperative-shell/file-thread.sml index 2320fc1..5551cb8 100644 --- a/imperative-shell/file-thread.sml +++ b/imperative-shell/file-thread.sml @@ -10,9 +10,9 @@ struct datatype parse_result = OK of AppType.triangle list | PARSE_ERROR - val structureName = "UpperCaseZ" - val filename = "fonts/upper-case-z.dsc" - val exportFilename = "fonts/upper-case-z.sml" + val structureName = "UnknownChar" + val filename = "fonts/unknown-char.dsc" + val exportFilename = "fonts/unknown-char.sml" fun ndcToLerpX num = let