Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidJourdan committed Feb 26, 2024
1 parent cadb3e7 commit 0d89cc9
Show file tree
Hide file tree
Showing 2 changed files with 413 additions and 2 deletions.
21 changes: 19 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,26 @@ These libraries can downloaded for better performance:
## How to run
From the command line, specify which mesh file (stored in ```/data/```) should be opened. For example with ```beetle.obj``` simply run
```
build/shrink-morph beetle
build/shrink_morph beetle
```
To use the togcode script:
For those who prefer to use a command-line version of a the app, use the ```shrink_morph_cli``` executable:
```
build/shrink_morph_cli mesh wD width nFmin
```
with ```mesh``` the name of the input mesh, ```wD``` the smoothing factor (0 by default), ```width``` the width of the flattened plate in mm, and ```nFmin``` the minimum number of faces in the input mesh (it gets iteratively subdivided until reaching this value). For example, to generate the same results as the ```hat``` model in the paper, type:
```
build/shrink_morph_cli hat 0.1 100 10000
```

To generate the final gcode files, use the togcode.py script. Its inputs are the .path file generated by the app, the name of your printer (only a few a supported at moment), and optionally the name of the output file, here is an example:
```
python togcode.py ../data/input_file.path Creality_K1_Max -o output_file.gcode
```

## Display layers with Matplotlib
To generate SVG files showing the trajectories similar to Figure 7 in the paper, runthe ```plot-layer.py``` script:
```
cd ../data/
python plot-layer.py 1
python plot-layer.py 10
```
Loading

0 comments on commit 0d89cc9

Please sign in to comment.