module implies union?

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

module implies union?

marhar
Is there any difference, either practical or theoretical, between the
following two module definitions?


module hole() {
         translate([0,0,-1])          cylinder(fwthickness+1,d=screwsz);
         translate([0,0,fwthickness]) cylinder(100,d=screwhd);
}


module hole() {
     union() {
         translate([0,0,-1])          cylinder(fwthickness+1,d=screwsz);
         translate([0,0,fwthickness]) cylinder(100,d=screwhd);
     }
}

_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Reply | Threaded
Open this post in threaded view
|

Re: module implies union?

MichaelAtOz
Administrator
ATM no.

At some time in the misty future, the implicit union will be removed, possibly in some fashion that preserves backward compatibility.
With that, a non unioned group() [the first of your cases] will exist as two child objects, v's the union()'d case will be one object.
Thus allowing the first case, each object can be accessed via children() individually.
It may also have performance implications, but that is less clear ATM.
Admin - PM me if you need anything,
or if I've done something stupid...

Unless specifically shown otherwise above, my contribution is in the Public Domain; to the extent possible under law, I have waived all copyright and related or neighbouring rights to this work.
Obviously inclusion of works of previous authors is not included in the above.


The TPP is no simple “trade agreement.” Fight it! http://www.ourfairdeal.org/ time is running out!