1
0
mirror of https://github.com/nophead/NopSCADlib.git synced 2025-09-24 22:21:28 +02:00

stl() and dxf() can now have the code to make the STL or DXF as a child.

This allows them to be replaced by the STL or DXF when making assembly views.

use_dxf() and use_stl() make use of $cwd and $target, so can be in bom.scad
and be documented.

Corrected the spelling of widget in BOM test.
This commit is contained in:
Chris Palmer
2021-02-06 15:23:10 +00:00
parent 079168142b
commit 5bac2bf46d
4 changed files with 64 additions and 40 deletions

View File

@@ -25,15 +25,3 @@ include <../../global_defs.scad>
// Global functions and modules
//
use <global.scad>
module use_stl(name) { //! Import an STL to make a build platter
stl(name);
path = is_undef($target) ? "../stls/" : str("../", $target, "/stls/");
import(str(path, name, ".stl"));
}
module use_dxf(name) { //! Import a DXF to make a build panel
dxf(name);
path = is_undef($target) ? "../dxfs/" : str("../", $target, "/dxfs/");
import(str(path, name, ".dxf"));
}