revarbat / mandoline Goto Github PK
View Code? Open in Web Editor NEWA lightning-fast program to slice 3D STL files into GCode tool paths for FDM 3D printing. (in Alpha)
Home Page: https://github.com/revarbat/Mandoline/wiki
License: Other
A lightning-fast program to slice 3D STL files into GCode tool paths for FDM 3D printing. (in Alpha)
Home Page: https://github.com/revarbat/Mandoline/wiki
License: Other
Mandoline: A faster way to slice 3D models. Copyright 2010-2014 Belfry Software. All rights reserved. Licensing: Released under the BSD "2-clause" license. Check the LICENSE.txt file for full licensing info. Description: Mandoline is a command-line program that slices 3D files into toolpaths for home-build thermoplastic-extrusion 3D printers like the RepRap or MakerBot. It can currently parse 3D input files in the .STL binary or ASCII formats. Output is in G-Code formatted files. Compilation and Installation: UNIX, Linux and OS X: cd src ./configure make sudo make install Windows: At this point, there is not yet a GUI wrapper for Mandoline. You can compile and use it from the CygWin environment, though. You'll need CygWin installed with gcc/g++ compilers and GNUMake. cd src ./configure make Then install the mandoline.exe file someplace useful. //TODO: verify that it compiles and works under Cygwin. Calibration: Mandoline comes with reasonable starting defaults for slicing files for printing on a MakerBot Thingomatic with a Mk7 extruder. Machines vary a lot, though, so you'll need to calibrate for your machine. Usage: mandoline [OPTIONS] FILE mandoline -m MATERIAL [OPTIONS] FILE Options include: -m STRING Extruded material. (default ABS) -f FLOAT Filament diameter. (default 3.0 mm) -F FLOAT Filament feedrate. (default 0.689 mm/s) -i FLOAT Infill density. (default 0.20) -l FLOAT Slicing layer thickness. (default 0.36 mm) -p INT Number of perimeter shell layers. (default 2) -r INT Number of Raft layers. (default 2) -w FLOAT Extrusion width over thickness ratio. (default 1.75) -c DON'T center model on platform before slicing. -S FLOAT Scale model. (default 1x) -R FLOAT Rotate model about Z. (default 0 deg) -d PREFIX Dump layers to SVG files with names like PREFIX-12.34.svg. -t INT Number of threads to slice with. (default 8) Debugging: You can dump SVG files for each layer, for debugging purposes. What is implemented is the basic carve and interior infill. And that's buggy. It won't do cooling or comb or filament retraction yet.
The slicer needs to have easy to perform calibration setup.
When moving from path to path inside of an island, we should stay in the perimeter of the object.
The geometry library currently does a bad job of insetting. I think this is actually a bug in the boolean geometry code.
A GUI interface to calibration and slicing would be good.
The geometry code eats all memory when trying to slice some STL files. Something is infinite looping.
On Ubuntu 16.04:
$ ./configure
...
$ make
...
libtool: compile: g++ -DHAVE_CONFIG_H -I. -O2 -MT BGLMesh3d.lo -MD -MP -MF .deps/BGLMesh3d.Tpo -c BGLMesh3d.cc -fPIC -DPIC -o .libs/BGLMesh3d.o
BGLMesh3d.cc: In member function 'int BGL::Mesh3d::loadFromSTLFile(const char*)':
BGLMesh3d.cc:224:35: error: 'fopen' was not declared in this scope
FILE *f = fopen(fileName, "rb");
^
BGLMesh3d.cc:226:17: error: 'stderr' was not declared in this scope
fprintf(stderr, "STL read failed to open\n");
^
BGLMesh3d.cc:226:52: error: 'fprintf' was not declared in this scope
fprintf(stderr, "STL read failed to open\n");
^
BGLMesh3d.cc:230:27: error: 'fread' was not declared in this scope
if (fread(buf, 1, 5, f) < 5) {
^
BGLMesh3d.cc:231:17: error: 'stderr' was not declared in this scope
fprintf(stderr, "STL read failed read\n");
^
BGLMesh3d.cc:231:49: error: 'fprintf' was not declared in this scope
fprintf(stderr, "STL read failed read\n");
^
BGLMesh3d.cc:235:50: error: 'strncasecmp' was not declared in this scope
if (!strncasecmp((const char*)buf, "solid", 5)) {
^
BGLMesh3d.cc:241:32: error: 'fread' was not declared in this scope
if (fread(buf, 1, 75, f) < 75) {
^
BGLMesh3d.cc:242:21: error: 'stderr' was not declared in this scope
fprintf(stderr, "STL read failed header read\n");
^
BGLMesh3d.cc:242:60: error: 'fprintf' was not declared in this scope
fprintf(stderr, "STL read failed header read\n");
^
BGLMesh3d.cc:246:41: error: 'fread' was not declared in this scope
if (fread(intdata.bytes, 1, 4, f) < 4) {
^
BGLMesh3d.cc:247:21: error: 'stderr' was not declared in this scope
fprintf(stderr, "STL read failed face count read\n");
^
BGLMesh3d.cc:247:64: error: 'fprintf' was not declared in this scope
fprintf(stderr, "STL read failed face count read\n");
^
BGLMesh3d.cc:252:23: error: 'feof' was not declared in this scope
while (!feof(f) && tricount-->0) {
^
BGLMesh3d.cc:253:51: error: 'fread' was not declared in this scope
if (fread(tridata.bytes, 1, 3*4*4+2, f) < 3*4*4+2) {
^
BGLMesh3d.cc:273:17: error: 'fclose' was not declared in this scope
fclose(f);
^
BGLMesh3d.cc:277:41: error: 'fgets' was not declared in this scope
fgets((char*)buf, sizeof(buf), f);
^
BGLMesh3d.cc:280:23: error: 'feof' was not declared in this scope
while (!feof(f)) {
^
BGLMesh3d.cc:281:34: error: 'fscanf' was not declared in this scope
fscanf(f, "%80s", buf);
^
BGLMesh3d.cc:282:51: error: 'strcasecmp' was not declared in this scope
if (!strcasecmp((char*)buf, "endsolid")) {
^
BGLMesh3d.cc:305:17: error: 'fclose' was not declared in this scope
fclose(f);
^
BGLMesh3d.cc: In member function 'int BGL::Mesh3d::loadFromOBJFile(const char*)':
BGLMesh3d.cc:321:35: error: 'fopen' was not declared in this scope
FILE *f = fopen(fileName, "rb");
^
BGLMesh3d.cc:323:17: error: 'stderr' was not declared in this scope
fprintf(stderr, "OBJ file failed to open\n");
^
BGLMesh3d.cc:323:52: error: 'fprintf' was not declared in this scope
fprintf(stderr, "OBJ file failed to open\n");
^
BGLMesh3d.cc:330:19: error: 'feof' was not declared in this scope
while (!feof(f)) {
^
BGLMesh3d.cc:331:32: error: 'fscanf' was not declared in this scope
if (fscanf(f, "%s", buf) < 0) {
^
BGLMesh3d.cc:334:39: error: 'strcasecmp' was not declared in this scope
if (!strcasecmp((char*)buf,"v")) {
^
BGLMesh3d.cc:335:49: error: 'fscanf' was not declared in this scope
if (fscanf(f, "%f %f %f", &x, &y, &z) < 0) {
^
BGLMesh3d.cc:340:39: error: 'strcasecmp' was not declared in this scope
if (!strcasecmp((char*)buf,"f")) {
^
BGLMesh3d.cc:341:36: error: 'fscanf' was not declared in this scope
if (fscanf(f, "%s", buf) < 0) {
^
BGLMesh3d.cc:344:26: error: 'atoi' was not declared in this scope
v1 = atoi(buf);
^
BGLMesh3d.cc:346:36: error: 'fscanf' was not declared in this scope
if (fscanf(f, "%s", buf) < 0) {
^
BGLMesh3d.cc:351:36: error: 'fscanf' was not declared in this scope
if (fscanf(f, "%s", buf) < 0) {
^
BGLMesh3d.cc:364:13: error: 'fclose' was not declared in this scope
fclose(f);
^
Makefile:434: recipe for target 'BGLMesh3d.lo' failed
make[4]: *** [BGLMesh3d.lo] Error 1
make[4]: Leaving directory '/home/kjcole/github/Mandoline/src/BGL'
Makefile:477: recipe for target 'all-recursive' failed
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory '/home/kjcole/github/Mandoline/src/BGL'
Makefile:308: recipe for target 'all' failed
make[2]: *** [all] Error 2
make[2]: Leaving directory '/home/kjcole/github/Mandoline/src/BGL'
Makefile:454: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/kjcole/github/Mandoline/src'
Makefile:290: recipe for target 'all' failed
make: *** [all] Error 2
$
While line-level infill joining is optimized, macro scale path joining is not. We should re-order paths to reduce distance moved.
When doing infill patching, the slicer needs to be completing infill on each island before moving to the next one.
This is low hanging fruit. We should be able to read .OBJ files without much hassle.
Can't get it to compile, don't know what I need to install to get int32_t to be defined, etc...
exported test models cannot be viewed in cura or pronterface.
The current GCode output needs to be made speed aware.
Need to implement support structures.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.