discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

scattered spourious polygons.....

BB
Bruno Boettcher
Fri, Mar 20, 2020 9:10 PM

Hello!

in case anyone has some time to spare..... i made for the study of my wife
these handles:
https://github.com/nohkumado/covid19_doorhandle
(https://www.thingiverse.com/thing:4233677 for some pictures)

i remove from a cylinder the shape of my doorknob, done with a
rotate_extrude circle, i am maybe getting tired of looking at the thing :D
but i don't get it why there's stuff hanging in the air on both ends of the
clamp? the thing i used for difference is longer than the cylinder i am
excavacating, this should do the job?

and another question:
is there a way to pass the knob module a shape to extrude?
if someone wants to make that handle with some other strange shape, he will
have to dig into the module.... passing the shape as argument to the
module, is that somehow possible?

thanks in advance!

--
ciao
Bruno

---==========
http://nohkumado.eu/, http://bboett.free.frhttp://aikido.nohkumado.eu/,
http://bboett.free.fr
http://aikido.zorn.free.fr

Hello! in case anyone has some time to spare..... i made for the study of my wife these handles: https://github.com/nohkumado/covid19_doorhandle (https://www.thingiverse.com/thing:4233677 for some pictures) i remove from a cylinder the shape of my doorknob, done with a rotate_extrude circle, i am maybe getting tired of looking at the thing :D but i don't get it why there's stuff hanging in the air on both ends of the clamp? the thing i used for difference is longer than the cylinder i am excavacating, this should do the job? and another question: is there a way to pass the knob module a shape to extrude? if someone wants to make that handle with some other strange shape, he will have to dig into the module.... passing the shape as argument to the module, is that somehow possible? thanks in advance! -- ciao Bruno =========================================== http://nohkumado.eu/, <http://bboett.free.fr>http://aikido.nohkumado.eu/, <http://bboett.free.fr> http://aikido.zorn.free.fr
JB
Jordan Brown
Fri, Mar 20, 2020 9:56 PM

On 3/20/2020 2:10 PM, Bruno Boettcher wrote:

Hello!

in case anyone has some time to spare..... i made for the study of my
wife these handles:
https://github.com/nohkumado/covid19_doorhandle
(https://www.thingiverse.com/thing:4233677 for some pictures)

i remove from a cylinder the shape of my doorknob, done with a
rotate_extrude circle, i am maybe getting tired of looking at the
thing :D but i don't get it why there's stuff hanging in the air on
both ends of the clamp? the thing i used for difference is longer than
the cylinder i am excavacating, this should do the job?

No, the thing you're subtracting out isn't longer than the thing you're
extracting it from.

For your knob() module, when knobrad is non-zero (as it is here), you
drop into the curved-part handling at 52-57, and there the "length" is
based on "alpha", not based on "len".  The two use the same "alpha" and
so you end up with the issues you see here.

and another question:
is there a way to pass the knob module a shape to extrude?
if someone wants to make that handle with some other strange shape, he
will have to dig into the module.... passing the shape as argument to
the module, is that somehow possible?

Yes, though it might be a little tricky - especially when you want it to
fix into the rest of the device.

Did you mean to pass a 2D shape to knob(), or a 3D shape to doorknob()? 
The concepts are the same.

You use the children() feature.

For instance, you might want something sort of like this:

module handle(len) {
    difference() {
        linear_extrude(height=len) {
            offset(r=2) children();
        }
        translate([0,0,-1]) linear_extrude(height=len+2) {
            children();
        }
    }
}

handle(10) {
    circle(d=20);
}

translate([40,0,0]) handle(10) {
    square(20, center=true);
}

translate([80,0,0]) handle(10) {
    circle(d=20, $fn=6);
}

yields:

On 3/20/2020 2:10 PM, Bruno Boettcher wrote: > Hello! > > in case anyone has some time to spare..... i made for the study of my > wife these handles: > https://github.com/nohkumado/covid19_doorhandle > (https://www.thingiverse.com/thing:4233677 for some pictures) > > i remove from a cylinder the shape of my doorknob, done with a > rotate_extrude circle, i am maybe getting tired of looking at the > thing :D but i don't get it why there's stuff hanging in the air on > both ends of the clamp? the thing i used for difference is longer than > the cylinder i am excavacating, this should do the job? No, the thing you're subtracting out isn't longer than the thing you're extracting it from. For your knob() module, when knobrad is non-zero (as it is here), you drop into the curved-part handling at 52-57, and there the "length" is based on "alpha", not based on "len".  The two use the same "alpha" and so you end up with the issues you see here. > > and another question: > is there a way to pass the knob module a shape to extrude? > if someone wants to make that handle with some other strange shape, he > will have to dig into the module.... passing the shape as argument to > the module, is that somehow possible? Yes, though it might be a little tricky - especially when you want it to fix into the rest of the device. Did you mean to pass a 2D shape to knob(), or a 3D shape to doorknob()?  The concepts are the same. You use the children() feature. For instance, you might want something sort of like this: module handle(len) { difference() { linear_extrude(height=len) { offset(r=2) children(); } translate([0,0,-1]) linear_extrude(height=len+2) { children(); } } } handle(10) { circle(d=20); } translate([40,0,0]) handle(10) { square(20, center=true); } translate([80,0,0]) handle(10) { circle(d=20, $fn=6); } yields:
RP
Ronaldo Persiano
Fri, Mar 20, 2020 10:06 PM

i remove from a cylinder the shape of my doorknob, done with a
rotate_extrude circle, i am maybe getting tired of looking at the thing :D
but i don't get it why there's stuff hanging in the air on both ends of the
clamp? the thing i used for difference is longer than the cylinder i am
excavacating, this should do the job?

I have gotten a clean shape by  changing the code line:

knob(knobdia+luft, knoblen+2,knobrad);

to

knob(knobdia+luft, knoblen+2,knobrad+2);

in the doorknob() module.

and another question:

is there a way to pass the knob module a shape to extrude?

Yes, as a children()

> > i remove from a cylinder the shape of my doorknob, done with a > rotate_extrude circle, i am maybe getting tired of looking at the thing :D > but i don't get it why there's stuff hanging in the air on both ends of the > clamp? the thing i used for difference is longer than the cylinder i am > excavacating, this should do the job? > I have gotten a clean shape by changing the code line: knob(knobdia+luft, knoblen+2,knobrad); to knob(knobdia+luft, knoblen+2,knobrad+2); in the doorknob() module. and another question: > is there a way to pass the knob module a shape to extrude? > Yes, as a children()
BB
Bruno Boettcher
Sat, Mar 21, 2020 8:08 AM

awesome thanks ,to both, too much looking sometime impaires the brain :D
i will try with the children, and Jordan yes for starters i have one door
where the knob has a form like a sort of F shape....
lets see if i manage that one
but for the moment the printer is busy printing the handles for the main
doors....

if ever someone wants to make look this thing better (smoother), feel free
:) its on github....
ciao
Bruno
ciao

Am Fr., 20. März 2020 um 23:07 Uhr schrieb Ronaldo Persiano <
rcmpersiano@gmail.com>:

i remove from a cylinder the shape of my doorknob, done with a

rotate_extrude circle, i am maybe getting tired of looking at the thing :D
but i don't get it why there's stuff hanging in the air on both ends of the
clamp? the thing i used for difference is longer than the cylinder i am
excavacating, this should do the job?

I have gotten a clean shape by  changing the code line:

knob(knobdia+luft, knoblen+2,knobrad);

to

knob(knobdia+luft, knoblen+2,knobrad+2);

in the doorknob() module.

and another question:

is there a way to pass the knob module a shape to extrude?

awesome thanks ,to both, too much looking sometime impaires the brain :D i will try with the children, and Jordan yes for starters i have one door where the knob has a form like a sort of F shape.... lets see if i manage that one but for the moment the printer is busy printing the handles for the main doors.... if ever someone wants to make look this thing better (smoother), feel free :) its on github.... ciao Bruno ciao Am Fr., 20. März 2020 um 23:07 Uhr schrieb Ronaldo Persiano < rcmpersiano@gmail.com>: > i remove from a cylinder the shape of my doorknob, done with a >> rotate_extrude circle, i am maybe getting tired of looking at the thing :D >> but i don't get it why there's stuff hanging in the air on both ends of the >> clamp? the thing i used for difference is longer than the cylinder i am >> excavacating, this should do the job? >> > > I have gotten a clean shape by changing the code line: > > knob(knobdia+luft, knoblen+2,knobrad); > > to > > knob(knobdia+luft, knoblen+2,knobrad+2); > > in the doorknob() module. > > and another question: >> is there a way to pass the knob module a shape to extrude? >> > > Yes, as a children() > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org > -- ciao Bruno =========================================== http://nohkumado.eu/, <http://bboett.free.fr>http://aikido.nohkumado.eu/, <http://bboett.free.fr> http://aikido.zorn.free.fr