Hi,
the mirror() command is basically a method that moves and transforms an
object. I wish there was a way to also say that the initial object should
remain in place, while creating a mirrored copy.
Perhaps the mirror() command could have an optional copy=true parameter ?
mirror([0,1,0], copy=true)
union() {
cube([10,30,2]);
translate([5, 25, 0]) cylinder(h=10, d=6);
}
Wouldn't that be useful?
--
View this message in context: http://forum.openscad.org/Wish-mirror-copy-true-tp10681.html
Sent from the OpenSCAD mailing list archive at Nabble.com.
Can't you just make a module that does that? Something like:
module copy_mirror(vec=[0,1,0])
{
children();
mirror(vec) children();
}
Sent from my iPhone
On 21 Dec 2014, at 10:17 pm, Scalpel78 frode@lillerud.no wrote:
Hi,
the mirror() command is basically a method that moves and transforms an
object. I wish there was a way to also say that the initial object should
remain in place, while creating a mirrored copy.
Perhaps the mirror() command could have an optional copy=true parameter ?
mirror([0,1,0], copy=true)
union() {
cube([10,30,2]);
translate([5, 25, 0]) cylinder(h=10, d=6);
}
Wouldn't that be useful?
--
View this message in context: http://forum.openscad.org/Wish-mirror-copy-true-tp10681.html
Sent from the OpenSCAD mailing list archive at Nabble.com.
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
+1
2014-12-21 13:03 GMT+01:00 Greg Frost gregorybartonfrost@gmail.com:
Can't you just make a module that does that? Something like:
module copy_mirror(vec=[0,1,0])
{
children();
mirror(vec) children();
}
Sent from my iPhone
On 21 Dec 2014, at 10:17 pm, Scalpel78 frode@lillerud.no wrote:
Hi,
the mirror() command is basically a method that moves and transforms an
object. I wish there was a way to also say that the initial object should
remain in place, while creating a mirrored copy.
Perhaps the mirror() command could have an optional copy=true parameter ?
mirror([0,1,0], copy=true)
union() {
cube([10,30,2]);
translate([5, 25, 0]) cylinder(h=10, d=6);
}
Wouldn't that be useful?
--
View this message in context:
Sent from the OpenSCAD mailing list archive at Nabble.com.
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
--
stempeldergeschichte@googlemail.com karsten@rohrbach.de
P.S. Falls meine E-Mail kürzer ausfällt als Dir angenehm ist:
Ich probiere gerade aus kurze Antworten statt gar keine Antworten zu
schreiben.
Wenn Du gerne mehr lesen möchtest, dann lass es mich bitte wissen.
P.S. In case my e-mail is shorter than you enjoy:
I am currently trying short replies instead of no replies at all.
Please let me know, if you like to read more.
Enjoy!
Greg Frost wrote
Can't you just make a module that does that? Something like:
module copy_mirror(vec=[0,1,0])
{
children();
mirror(vec) children();
}
Absolutely, good idea! Thanks!
--
View this message in context: http://forum.openscad.org/Wish-mirror-copy-true-tp10681p10687.html
Sent from the OpenSCAD mailing list archive at Nabble.com.
You will find that Gregs approach can be used for a lot of what, on initial
view, seem to be shortcomings of the language.
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. This work is published globally via the internet. :) Inclusion of works of previous authors is not included in the above.
View this message in context: http://forum.openscad.org/Wish-mirror-copy-true-tp10681p10694.html
Sent from the OpenSCAD mailing list archive at Nabble.com.
Thanks again, this is becoming one of my new favorite modules.
Michael, yes I need to adjust to how you can use modules and the children
keyword for making useful methods.
--
View this message in context: http://forum.openscad.org/Wish-mirror-copy-true-tp10681p10697.html
Sent from the OpenSCAD mailing list archive at Nabble.com.