# Programmatically generating mesh (STL) 3D object files

**URL:** <https://forum.codeselfstudy.com/t/programmatically-generating-mesh-stl-3d-object-files/1818>\
**Category:** General Discussion\
**Tags:** command-line, javascript\
**Created:** [September 11, 2019, 10:01pm UTC](https://forum.codeselfstudy.com/t/programmatically-generating-mesh-stl-3d-object-files/1818 "2019-09-11T22:01:43Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![OutsourcedGuru](https://forum.codeselfstudy.com/user_avatar/forum.codeselfstudy.com/outsourcedguru/32/983_2.png) [@OutsourcedGuru](https://forum.codeselfstudy.com/u/OutsourcedGuru)\
**Post date:** [September 11, 2019, 10:01pm UTC](https://forum.codeselfstudy.com/t/programmatically-generating-mesh-stl-3d-object-files/1818/1 "2019-09-11T22:01:43Z")

</div>

I did something clever a while back that I wanted to share. I wanted to use the `three.js` module in JavaScript _server-side_ in Node which is problematic since there’s no Window and therefore no Canvas object to render to.

Working around those limitations, I then created a CLI app to accept text to render into a 3D context then convert into a mesh file, suitable for importing into a CAD app or slicing directly in Cura, for example, then ready-to-print on a 3D printer. The JavaScript translates the incoming text into character representations within the scene (to the accepted **braille** standards).

 ![](https://forum.codeselfstudy.com/uploads/default/original/1X/215e1cdae1f44dfc56ddfb0d2dd8d6a7deea71a2.png)

[https://github.com/OutsourcedGuru/3d-braille](https://github.com/OutsourcedGuru/3d-braille)

---

<div class="post-metadata">

**Author:** ![Josh](https://forum.codeselfstudy.com/user_avatar/forum.codeselfstudy.com/josh/32/4_2.png) [@Josh](https://forum.codeselfstudy.com/u/Josh)\
**Post date:** [September 12, 2019, 2:57am UTC](https://forum.codeselfstudy.com/t/programmatically-generating-mesh-stl-3d-object-files/1818/2 "2019-09-12T02:57:45Z")

</div>

Nice, I’ve been meaning to learn Braille, but I’m not sure where to start.

---

<div class="post-metadata">

**Author:** ![OutsourcedGuru](https://forum.codeselfstudy.com/user_avatar/forum.codeselfstudy.com/outsourcedguru/32/983_2.png) [@OutsourcedGuru](https://forum.codeselfstudy.com/u/OutsourcedGuru)\
**Post date:** [September 12, 2019, 3:42pm UTC](https://forum.codeselfstudy.com/t/programmatically-generating-mesh-stl-3d-object-files/1818/3 "2019-09-12T15:42:28Z")

</div>

I think I’d start from the left… and then work your way to the right.

---

<div class="post-metadata">

**Author:** ![OutsourcedGuru](https://forum.codeselfstudy.com/user_avatar/forum.codeselfstudy.com/outsourcedguru/32/983_2.png) [@OutsourcedGuru](https://forum.codeselfstudy.com/u/OutsourcedGuru)\
**Post date:** [September 12, 2019, 6:09pm UTC](https://forum.codeselfstudy.com/t/programmatically-generating-mesh-stl-3d-object-files/1818/4 "2019-09-12T18:09:55Z")

</div>

One of the projects I’d like to build would be a bluetooth braille glove with a tactile array for index and middle fingers as well as accelerometers. You could then gesture with two fingers left-to-right and it would tactilely create the impression of feeling three or four braille characters. You could pair this with either a webcam with OCR feature or perhaps webpages could embed braille objects to be “spoken” like this.
