# Papercraft Unfold
This tool converts a STL/OFF/PLY/OBJ into binary STL Format. The STL then gets unfolded (flattened) to make a papercraft model. It utilizes [https://github.com/osresearch/papercraft](https://github.com/osresearch/papercraft) and [https://github.com/admesh/admesh](https://github.com/admesh/admesh)

Avoid importing STL files with a lot of surfaces. Larger files require intense computing power. It's better to use simplified low-poly models (with a decent amount of triangles). See [Simplification and remeshing of STL parts](https://old.stadtfabrikanten.org/display/AFUS/Simplification+and+remeshing+of+STL+parts)

**3D STL preview****Papercraft Unfold output**
[![grafik.png](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/scaled-1680-/Y2PSRgDKSIawk3x7-grafik.png)](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/Y2PSRgDKSIawk3x7-grafik.png)[![grafik.png](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/scaled-1680-/sdYFyHndO22UcKA5-grafik.png)](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/sdYFyHndO22UcKA5-grafik.png)
## Usage [![grafik.png](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/scaled-1680-/WqHOLILD6yVfrhqe-grafik.png)](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/WqHOLILD6yVfrhqe-grafik.png) [![grafik.png](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/scaled-1680-/SzmkiZNQtC6oJcMK-grafik.png)](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/SzmkiZNQtC6oJcMK-grafik.png) ## Manual steps ### PaperCraft Unfold tool compilation on Windows (and Linux) The folowing steps how to compile `unfold` binary which is used for the upper mentioned Inkscape plugin. ### Start Cygwin (Windows) or use your regular bash shell (Linux) On Linux we can easily compile using `gcc` and `make`. For Windows executable we can use cygwin with installed `gcc` and `make` libraries. ### Compile ```bash cd /c/ git clone https://github.com/osresearch/papercraft cd papercraft make cp C:\Babun\.babun\cygwin\bin /c/papercraft/ explorer . ```

Papercraft Unfold supports option to generate labels for edges. We can make separate compilations to have both variants. (variable: `static int draw_labels = 0;`)

### Start cmd shell ```bash cd C:\papercraft unfold < Bunny-LowPoly.stl > bunny.svg #or explicitely with extension .exe unfold.exe < Bunny-LowPoly.stl > bunny.svg ``` ### Check output and compare with input
**Bunny-LowPoly.stl****unfold < Bunny-LowPoly.stl > bunny.svg****bunny.svg**
[![grafik.png](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/scaled-1680-/PbAYTCLPz8YtuQ70-grafik.png)](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/PbAYTCLPz8YtuQ70-grafik.png)[![grafik.png](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/scaled-1680-/hTx6DPXNCJiFPoFf-grafik.png)](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/hTx6DPXNCJiFPoFf-grafik.png)[![grafik.png](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/scaled-1680-/2ucgXa03AA5QZccb-grafik.png)](https://wiki.stadtfabrikanten.org/uploads/images/gallery/2025-05/2ucgXa03AA5QZccb-grafik.png)