Tootfinder

Opt-in global Mastodon full text search. Join the index!

@toxi@mastodon.thi.ng
2026-09-01 11:31:12

A small #ThingUmbrella code snippet for a current shop admin task, to help me with preparing different print size options in both inches and centimeters, grouped by landscape, portrait or square format.
The script illustrates how to functionally iterate over all possible sizes in a min/max range, converting & formatting units and grouping sizes based on their aspect ratio. All mo…

Syntax colored TypeScript source code. Full version here: https://gist.github.com/postspectacular/a122ab9c1cd52934b8093461231c6044
Resulting text output of print sizes grouped by aspect ratio. Full source: https://gist.github.com/postspectacular/a122ab9c1cd52934b8093461231c6044

Excerpt:

square:
4 × 4 inch (10 × 10 cm)
5 × 5 inch (13 × 13 cm)
6 × 6 inch (15 × 15 cm)
...

landscape:
5 × 4 inch (13 × 10 cm)
6 × 4 inch (15 × 10 cm)
7 × 4 inch (18 × 10 cm)
...

portrait:
4 × 5 inch (10 × 13 cm)
4 × 6 inch (10 × 15 cm)
5 × 6 inch (13 × 15 cm)
...
@toxi@mastodon.thi.ng
2026-07-30 15:32:24

Heads up for those who care: A flurry of #ThingUmbrella updates/additions incoming, incl. new nD spatial hash table (with 2D/3D optimizations), indexed mesh data structure, updates to thi.ng/vectors and

Screenshot of the linked example project, showing a multi-colored Phong-shaded Stanford bunny.
@toxi@mastodon.thi.ng
2026-07-16 21:41:24

New #ThingUmbrella release(s): Updated the thi.ng/geom-io-obj OBJ mesh parser to support stream parsing using async iterables. This allows direct piping fetch() responses to the parser.

Screenshot of the linked demo project, showing a gray Lambert-shaded Stanford bunny on light blue background.
@toxi@mastodon.thi.ng
2026-07-17 08:17:57

Another #ThingUmbrella release cycle this AM: