discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

OpenSCAD carving plugin

HL
Hans L
Wed, Jul 18, 2018 3:16 PM

One thing which I've become curious about --- could one use OpenSCAD as a previewer for a CNC toolpath? Given an arbitrary shape (the tool definition) could one then subtract from the stock that shape moving along a path? Forgive me if there's some obvious command for this (just point me at the manual and I'll try to understand it better).

One way to generate the toolpath would be taking the cutter geometry,
and doing the hull on each consecutive pair of points along the tool
path, then union all those, and subtract from your model.  This could
end up becoming extremely computationally expensive depending on your
paths and the detail of your cutter geometry (ball end geometry much
more complex than straight end mill).

I've needed this sort of operation in the past, and I've dubbed it the
"consecutive hull" operation.  Here is a demo script for it:

module consecutive_hull() {
for (i = [1:1:$children-1])
hull() {
children(i-1);
children(i);
}
}

count = 25;
$fn=20;

xs = rands(-100,100,count);
ys = rands(-100,100,count);
zs = rands(-100,100,count);
ss = rands(-100,100,count);

consecutive_hull() {
// using loops isnt compatible with children() module used by consecutive hull
//for(i = [0:1:count-1])
//  translate([xs[i],ys[i],zs[i]]) sphere(5);

// must define each child explicitly
let(i = 0) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 1) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 2) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 3) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 4) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 5) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 6) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 7) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 8) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 9) translate([xs[i],ys[i],zs[i]]) sphere(5);

}

This could also conceptually be thought of as a sort of minkowski sum
between a 3d shape(the cutter geometry) and a 1D shape (a linear path
which exists in 3D space).
OpenSCAD minkowski currently only supports summing 3D objects with 3D,
or 2D with 2D.  No mixing 2D and 3D, and not really even the concept
of 1D geometries (paths / curves), though you can always make a vector
of points to represent such things.

I think a more comprehensive native minkowski operation including 1D
paths (as well as some ways of summing 2D with 3D) could be a very
useful addition to OpenSCAD if an efficient implementation is
possible.

> One thing which I've become curious about --- could one use OpenSCAD as a previewer for a CNC toolpath? Given an arbitrary shape (the tool definition) could one then subtract from the stock that shape moving along a path? Forgive me if there's some obvious command for this (just point me at the manual and I'll try to understand it better). One way to generate the toolpath would be taking the cutter geometry, and doing the hull on each consecutive pair of points along the tool path, then union all those, and subtract from your model. This could end up becoming extremely computationally expensive depending on your paths and the detail of your cutter geometry (ball end geometry much more complex than straight end mill). I've needed this sort of operation in the past, and I've dubbed it the "consecutive hull" operation. Here is a demo script for it: module consecutive_hull() { for (i = [1:1:$children-1]) hull() { children(i-1); children(i); } } count = 25; $fn=20; xs = rands(-100,100,count); ys = rands(-100,100,count); zs = rands(-100,100,count); ss = rands(-100,100,count); consecutive_hull() { // using loops isnt compatible with children() module used by consecutive hull //for(i = [0:1:count-1]) // translate([xs[i],ys[i],zs[i]]) sphere(5); // must define each child explicitly let(i = 0) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 1) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 2) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 3) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 4) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 5) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 6) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 7) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 8) translate([xs[i],ys[i],zs[i]]) sphere(5); let(i = 9) translate([xs[i],ys[i],zs[i]]) sphere(5); } This could also conceptually be thought of as a sort of minkowski sum between a 3d shape(the cutter geometry) and a 1D shape (a linear path which exists in 3D space). OpenSCAD minkowski currently only supports summing 3D objects with 3D, or 2D with 2D. No mixing 2D and 3D, and not really even the concept of 1D geometries (paths / curves), though you can always make a vector of points to represent such things. I think a more comprehensive native minkowski operation including 1D paths (as well as some ways of summing 2D with 3D) could be a very useful addition to OpenSCAD if an efficient implementation is possible.
WA
William Adams
Mon, Jul 23, 2018 4:19 PM

Thank you for that! It's working quite well:

http://community.carbide3d.com/t/sharing-carbide-create-dovetail-files/9371/21?u=willadams

Next up is reversing the process --- I'd like to work up a tool which would
allow one to take a G-Code file and then build a 3D preview of what will be
cut using that technique

William

On Wed, Jul 18, 2018 at 11:16 AM, Hans L thehans@gmail.com wrote:

One thing which I've become curious about --- could one use OpenSCAD as

a previewer for a CNC toolpath? Given an arbitrary shape (the tool
definition) could one then subtract from the stock that shape moving along
a path? Forgive me if there's some obvious command for this (just point me
at the manual and I'll try to understand it better).

One way to generate the toolpath would be taking the cutter geometry,
and doing the hull on each consecutive pair of points along the tool
path, then union all those, and subtract from your model.  This could
end up becoming extremely computationally expensive depending on your
paths and the detail of your cutter geometry (ball end geometry much
more complex than straight end mill).

I've needed this sort of operation in the past, and I've dubbed it the
"consecutive hull" operation.  Here is a demo script for it:

module consecutive_hull() {
for (i = [1:1:$children-1])
hull() {
children(i-1);
children(i);
}
}

count = 25;
$fn=20;

xs = rands(-100,100,count);
ys = rands(-100,100,count);
zs = rands(-100,100,count);
ss = rands(-100,100,count);

consecutive_hull() {
// using loops isnt compatible with children() module used by
consecutive hull
//for(i = [0:1:count-1])
//  translate([xs[i],ys[i],zs[i]]) sphere(5);

// must define each child explicitly
let(i = 0) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 1) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 2) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 3) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 4) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 5) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 6) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 7) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 8) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 9) translate([xs[i],ys[i],zs[i]]) sphere(5);

}

This could also conceptually be thought of as a sort of minkowski sum
between a 3d shape(the cutter geometry) and a 1D shape (a linear path
which exists in 3D space).
OpenSCAD minkowski currently only supports summing 3D objects with 3D,
or 2D with 2D.  No mixing 2D and 3D, and not really even the concept
of 1D geometries (paths / curves), though you can always make a vector
of points to represent such things.

I think a more comprehensive native minkowski operation including 1D
paths (as well as some ways of summing 2D with 3D) could be a very
useful addition to OpenSCAD if an efficient implementation is
possible.


OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

Thank you for that! It's working quite well: http://community.carbide3d.com/t/sharing-carbide-create-dovetail-files/9371/21?u=willadams Next up is reversing the process --- I'd like to work up a tool which would allow one to take a G-Code file and then build a 3D preview of what will be cut using that technique William On Wed, Jul 18, 2018 at 11:16 AM, Hans L <thehans@gmail.com> wrote: > > One thing which I've become curious about --- could one use OpenSCAD as > a previewer for a CNC toolpath? Given an arbitrary shape (the tool > definition) could one then subtract from the stock that shape moving along > a path? Forgive me if there's some obvious command for this (just point me > at the manual and I'll try to understand it better). > > One way to generate the toolpath would be taking the cutter geometry, > and doing the hull on each consecutive pair of points along the tool > path, then union all those, and subtract from your model. This could > end up becoming extremely computationally expensive depending on your > paths and the detail of your cutter geometry (ball end geometry much > more complex than straight end mill). > > I've needed this sort of operation in the past, and I've dubbed it the > "consecutive hull" operation. Here is a demo script for it: > > module consecutive_hull() { > for (i = [1:1:$children-1]) > hull() { > children(i-1); > children(i); > } > } > > count = 25; > $fn=20; > > xs = rands(-100,100,count); > ys = rands(-100,100,count); > zs = rands(-100,100,count); > ss = rands(-100,100,count); > > consecutive_hull() { > // using loops isnt compatible with children() module used by > consecutive hull > //for(i = [0:1:count-1]) > // translate([xs[i],ys[i],zs[i]]) sphere(5); > > // must define each child explicitly > let(i = 0) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 1) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 2) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 3) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 4) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 5) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 6) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 7) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 8) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 9) translate([xs[i],ys[i],zs[i]]) sphere(5); > > } > > > This could also conceptually be thought of as a sort of minkowski sum > between a 3d shape(the cutter geometry) and a 1D shape (a linear path > which exists in 3D space). > OpenSCAD minkowski currently only supports summing 3D objects with 3D, > or 2D with 2D. No mixing 2D and 3D, and not really even the concept > of 1D geometries (paths / curves), though you can always make a vector > of points to represent such things. > > I think a more comprehensive native minkowski operation including 1D > paths (as well as some ways of summing 2D with 3D) could be a very > useful addition to OpenSCAD if an efficient implementation is > possible. > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org >
RD
Revar Desmera
Mon, Jul 23, 2018 7:16 PM

If you just want a good GCode previewer, I found a really nice open source cross-platform GCode simulator called CAMotics:

https://camotics.org https://camotics.org/

  • Revar

On Jul 23, 2018, at 9:19 AM, William Adams will.adams@frycomm.com wrote:

Thank you for that! It's working quite well:

http://community.carbide3d.com/t/sharing-carbide-create-dovetail-files/9371/21?u=willadams http://community.carbide3d.com/t/sharing-carbide-create-dovetail-files/9371/21?u=willadams

Next up is reversing the process --- I'd like to work up a tool which would allow one to take a G-Code file and then build a 3D preview of what will be cut using that technique

William

On Wed, Jul 18, 2018 at 11:16 AM, Hans L <thehans@gmail.com mailto:thehans@gmail.com> wrote:

One thing which I've become curious about --- could one use OpenSCAD as a previewer for a CNC toolpath? Given an arbitrary shape (the tool definition) could one then subtract from the stock that shape moving along a path? Forgive me if there's some obvious command for this (just point me at the manual and I'll try to understand it better).

One way to generate the toolpath would be taking the cutter geometry,
and doing the hull on each consecutive pair of points along the tool
path, then union all those, and subtract from your model.  This could
end up becoming extremely computationally expensive depending on your
paths and the detail of your cutter geometry (ball end geometry much
more complex than straight end mill).

I've needed this sort of operation in the past, and I've dubbed it the
"consecutive hull" operation.  Here is a demo script for it:

module consecutive_hull() {
for (i = [1:1:$children-1])
hull() {
children(i-1);
children(i);
}
}

count = 25;
$fn=20;

xs = rands(-100,100,count);
ys = rands(-100,100,count);
zs = rands(-100,100,count);
ss = rands(-100,100,count);

consecutive_hull() {
// using loops isnt compatible with children() module used by consecutive hull
//for(i = [0:1:count-1])
//  translate([xs[i],ys[i],zs[i]]) sphere(5);

// must define each child explicitly
let(i = 0) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 1) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 2) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 3) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 4) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 5) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 6) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 7) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 8) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 9) translate([xs[i],ys[i],zs[i]]) sphere(5);

}

This could also conceptually be thought of as a sort of minkowski sum
between a 3d shape(the cutter geometry) and a 1D shape (a linear path
which exists in 3D space).
OpenSCAD minkowski currently only supports summing 3D objects with 3D,
or 2D with 2D.  No mixing 2D and 3D, and not really even the concept
of 1D geometries (paths / curves), though you can always make a vector
of points to represent such things.

I think a more comprehensive native minkowski operation including 1D
paths (as well as some ways of summing 2D with 3D) could be a very
useful addition to OpenSCAD if an efficient implementation is
possible.


OpenSCAD mailing list
Discuss@lists.openscad.org mailto:Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

If you just want a good GCode previewer, I found a really nice open source cross-platform GCode simulator called CAMotics: https://camotics.org <https://camotics.org/> - Revar > On Jul 23, 2018, at 9:19 AM, William Adams <will.adams@frycomm.com> wrote: > > Thank you for that! It's working quite well: > > http://community.carbide3d.com/t/sharing-carbide-create-dovetail-files/9371/21?u=willadams <http://community.carbide3d.com/t/sharing-carbide-create-dovetail-files/9371/21?u=willadams> > > Next up is reversing the process --- I'd like to work up a tool which would allow one to take a G-Code file and then build a 3D preview of what will be cut using that technique > > William > > > On Wed, Jul 18, 2018 at 11:16 AM, Hans L <thehans@gmail.com <mailto:thehans@gmail.com>> wrote: > > One thing which I've become curious about --- could one use OpenSCAD as a previewer for a CNC toolpath? Given an arbitrary shape (the tool definition) could one then subtract from the stock that shape moving along a path? Forgive me if there's some obvious command for this (just point me at the manual and I'll try to understand it better). > > One way to generate the toolpath would be taking the cutter geometry, > and doing the hull on each consecutive pair of points along the tool > path, then union all those, and subtract from your model. This could > end up becoming extremely computationally expensive depending on your > paths and the detail of your cutter geometry (ball end geometry much > more complex than straight end mill). > > I've needed this sort of operation in the past, and I've dubbed it the > "consecutive hull" operation. Here is a demo script for it: > > module consecutive_hull() { > for (i = [1:1:$children-1]) > hull() { > children(i-1); > children(i); > } > } > > count = 25; > $fn=20; > > xs = rands(-100,100,count); > ys = rands(-100,100,count); > zs = rands(-100,100,count); > ss = rands(-100,100,count); > > consecutive_hull() { > // using loops isnt compatible with children() module used by consecutive hull > //for(i = [0:1:count-1]) > // translate([xs[i],ys[i],zs[i]]) sphere(5); > > // must define each child explicitly > let(i = 0) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 1) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 2) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 3) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 4) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 5) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 6) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 7) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 8) translate([xs[i],ys[i],zs[i]]) sphere(5); > let(i = 9) translate([xs[i],ys[i],zs[i]]) sphere(5); > > } > > > This could also conceptually be thought of as a sort of minkowski sum > between a 3d shape(the cutter geometry) and a 1D shape (a linear path > which exists in 3D space). > OpenSCAD minkowski currently only supports summing 3D objects with 3D, > or 2D with 2D. No mixing 2D and 3D, and not really even the concept > of 1D geometries (paths / curves), though you can always make a vector > of points to represent such things. > > I think a more comprehensive native minkowski operation including 1D > paths (as well as some ways of summing 2D with 3D) could be a very > useful addition to OpenSCAD if an efficient implementation is > possible. > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org <mailto:Discuss@lists.openscad.org> > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org <http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org> > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
WA
William Adams
Mon, Jul 23, 2018 7:31 PM

Thanks! I've been using it, but was stumped by getting a dovetail preview
out of it --- turns out one can do so by appropriately changing the
settings for a Stub endmill, so I should be good to go on that front.

Next up is METAPOST to draw up toolpaths now that I've drawn a set up by
hand to compare against.

William

On Mon, Jul 23, 2018 at 3:16 PM, Revar Desmera revarbat@gmail.com wrote:

If you just want a good GCode previewer, I found a really nice open source
cross-platform GCode simulator called CAMotics:

https://camotics.org

  • Revar

On Jul 23, 2018, at 9:19 AM, William Adams will.adams@frycomm.com wrote:

Thank you for that! It's working quite well:

http://community.carbide3d.com/t/sharing-carbide-create-
dovetail-files/9371/21?u=willadams

Next up is reversing the process --- I'd like to work up a tool which
would allow one to take a G-Code file and then build a 3D preview of what
will be cut using that technique

William

On Wed, Jul 18, 2018 at 11:16 AM, Hans L thehans@gmail.com wrote:

One thing which I've become curious about --- could one use OpenSCAD as

a previewer for a CNC toolpath? Given an arbitrary shape (the tool
definition) could one then subtract from the stock that shape moving along
a path? Forgive me if there's some obvious command for this (just point me
at the manual and I'll try to understand it better).

One way to generate the toolpath would be taking the cutter geometry,
and doing the hull on each consecutive pair of points along the tool
path, then union all those, and subtract from your model.  This could
end up becoming extremely computationally expensive depending on your
paths and the detail of your cutter geometry (ball end geometry much
more complex than straight end mill).

I've needed this sort of operation in the past, and I've dubbed it the
"consecutive hull" operation.  Here is a demo script for it:

module consecutive_hull() {
for (i = [1:1:$children-1])
hull() {
children(i-1);
children(i);
}
}

count = 25;
$fn=20;

xs = rands(-100,100,count);
ys = rands(-100,100,count);
zs = rands(-100,100,count);
ss = rands(-100,100,count);

consecutive_hull() {
// using loops isnt compatible with children() module used by
consecutive hull
//for(i = [0:1:count-1])
//  translate([xs[i],ys[i],zs[i]]) sphere(5);

// must define each child explicitly
let(i = 0) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 1) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 2) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 3) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 4) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 5) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 6) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 7) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 8) translate([xs[i],ys[i],zs[i]]) sphere(5);
let(i = 9) translate([xs[i],ys[i],zs[i]]) sphere(5);

}

This could also conceptually be thought of as a sort of minkowski sum
between a 3d shape(the cutter geometry) and a 1D shape (a linear path
which exists in 3D space).
OpenSCAD minkowski currently only supports summing 3D objects with 3D,
or 2D with 2D.  No mixing 2D and 3D, and not really even the concept
of 1D geometries (paths / curves), though you can always make a vector
of points to represent such things.

I think a more comprehensive native minkowski operation including 1D
paths (as well as some ways of summing 2D with 3D) could be a very
useful addition to OpenSCAD if an efficient implementation is
possible.


OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

Thanks! I've been using it, but was stumped by getting a dovetail preview out of it --- turns out one can do so by appropriately changing the settings for a Stub endmill, so I should be good to go on that front. Next up is METAPOST to draw up toolpaths now that I've drawn a set up by hand to compare against. William On Mon, Jul 23, 2018 at 3:16 PM, Revar Desmera <revarbat@gmail.com> wrote: > If you just want a good GCode previewer, I found a really nice open source > cross-platform GCode simulator called CAMotics: > > https://camotics.org > > - Revar > > > > On Jul 23, 2018, at 9:19 AM, William Adams <will.adams@frycomm.com> wrote: > > Thank you for that! It's working quite well: > > http://community.carbide3d.com/t/sharing-carbide-create- > dovetail-files/9371/21?u=willadams > > Next up is reversing the process --- I'd like to work up a tool which > would allow one to take a G-Code file and then build a 3D preview of what > will be cut using that technique > > William > > > On Wed, Jul 18, 2018 at 11:16 AM, Hans L <thehans@gmail.com> wrote: > >> > One thing which I've become curious about --- could one use OpenSCAD as >> a previewer for a CNC toolpath? Given an arbitrary shape (the tool >> definition) could one then subtract from the stock that shape moving along >> a path? Forgive me if there's some obvious command for this (just point me >> at the manual and I'll try to understand it better). >> >> One way to generate the toolpath would be taking the cutter geometry, >> and doing the hull on each consecutive pair of points along the tool >> path, then union all those, and subtract from your model. This could >> end up becoming extremely computationally expensive depending on your >> paths and the detail of your cutter geometry (ball end geometry much >> more complex than straight end mill). >> >> I've needed this sort of operation in the past, and I've dubbed it the >> "consecutive hull" operation. Here is a demo script for it: >> >> module consecutive_hull() { >> for (i = [1:1:$children-1]) >> hull() { >> children(i-1); >> children(i); >> } >> } >> >> count = 25; >> $fn=20; >> >> xs = rands(-100,100,count); >> ys = rands(-100,100,count); >> zs = rands(-100,100,count); >> ss = rands(-100,100,count); >> >> consecutive_hull() { >> // using loops isnt compatible with children() module used by >> consecutive hull >> //for(i = [0:1:count-1]) >> // translate([xs[i],ys[i],zs[i]]) sphere(5); >> >> // must define each child explicitly >> let(i = 0) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 1) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 2) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 3) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 4) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 5) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 6) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 7) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 8) translate([xs[i],ys[i],zs[i]]) sphere(5); >> let(i = 9) translate([xs[i],ys[i],zs[i]]) sphere(5); >> >> } >> >> >> This could also conceptually be thought of as a sort of minkowski sum >> between a 3d shape(the cutter geometry) and a 1D shape (a linear path >> which exists in 3D space). >> OpenSCAD minkowski currently only supports summing 3D objects with 3D, >> or 2D with 2D. No mixing 2D and 3D, and not really even the concept >> of 1D geometries (paths / curves), though you can always make a vector >> of points to represent such things. >> >> I think a more comprehensive native minkowski operation including 1D >> paths (as well as some ways of summing 2D with 3D) could be a very >> useful addition to OpenSCAD if an efficient implementation is >> possible. >> >> _______________________________________________ >> OpenSCAD mailing list >> Discuss@lists.openscad.org >> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org >> > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org > > > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org > >