

I don't know. I will do some experiments tomorrow. Odd it needs to be one more on Intel graphics.
Is there a significant penalty to setting it to a large number, like
10? That's what I usually do when I notice a rendering problem, and
I haven't noticed any performance problems, but maybe I've been
working with simple cases.
_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


Incredible. I was sort of accepting the idea that previewing objects with parts cut out of them
was going to just give me a mess because that's the way Preview is. Thank You! Now I can
do this sort of thing a WHOLE lot easier.
On 13 Jun 2019 at 14:55, adrianv wrote:
> I hadn't really paid attention to convexity and hadn't realized that there
> was a solution to my models having sections that disappear as I rotate them
> in preview. I did a test run and found that setting convexity to 10 had no
> effect on my run time and it increased the geometry cache by about 10%.
> Basically, no obvious penalty.
> 
> Sent from: http://forum.openscad.org/>
> _______________________________________________
> OpenSCAD mailing list
> [hidden email]
> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org>

Magic trumps science for most people,
and wishful thinking drives a lot of decisionmaking.
 Joe Haldeman
_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


This is a distilled version of the code I was having a problem with:
for(c = [1:4]) translate([c * 40, 0]) difference () { linear_extrude(height = 50, center = true, convexity = c) difference() { circle(5); circle(4); } translate([0, 0, 20]) cube(20, center = true); }
This is how it looks on my old laptop:
And this is how it looks on my normal desktop machine, which also has Intel graphics but it never gives me problems. Goldfeather makes no difference.
It seems 2 is sufficient on this machine but the old machine needs 4.
The manual says "Integer number of "inward" curves, ie. expected path crossings of an arbitrary line through the polygon." in one place and "The convexity parameter specifies the maximum number of front sides (back sides) a ray intersecting the object might penetrate" in another.
Neither statement is clear to me. What does " front sides (back sides)" mean?
If it is simply the maximum number of edges a line can pass through then I agree it should be 4 for a tube.
_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


However if that was the case why doesn't it default to 2, because for a convex shape 2 in the minimum. And why isn't it called concavity as it is concave shapes that go wrong? This is a distilled version of the code I was having a problem with:
for(c = [1:4]) translate([c * 40, 0]) difference () { linear_extrude(height = 50, center = true, convexity = c) difference() { circle(5); circle(4); } translate([0, 0, 20]) cube(20, center = true); }
This is how it looks on my old laptop:
And this is how it looks on my normal desktop machine, which also has Intel graphics but it never gives me problems. Goldfeather makes no difference.
It seems 2 is sufficient on this machine but the old machine needs 4.
The manual says "Integer number of "inward" curves, ie. expected path crossings of an arbitrary line through the polygon." in one place and "The convexity parameter specifies the maximum number of front sides (back sides) a ray intersecting the object might penetrate" in another.
Neither statement is clear to me. What does " front sides (back sides)" mean?
If it is simply the maximum number of edges a line can pass through then I agree it should be 4 for a tube.
_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


Two outer walls, plus two inner walls for the tube.
 Revar
RevarBat wrote A line could possibly pass through a maximum of four walls of a tube, so convexity should be 4.
I can't see how a straight line could pass through more than two walls. How would it pass through four???  Sent from: http://forum.openscad.org/_______________________________________________ OpenSCAD mailing list [hidden email]http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


This is what OpenCSG says:
"The convexity of a primitive is the maximum number of front (or back) faces of the primitive at a single position. For example, the convexity of a sphere is one and the convexity of a torus is two. "
So it it seems 2 is the correct value for a tube and the OpenSCAD manual is misleading. However if that was the case why doesn't it default to 2, because for a convex shape 2 in the minimum. And why isn't it called concavity as it is concave shapes that go wrong?
This is a distilled version of the code I was having a problem with:
for(c = [1:4]) translate([c * 40, 0]) difference () { linear_extrude(height = 50, center = true, convexity = c) difference() { circle(5); circle(4); } translate([0, 0, 20]) cube(20, center = true); }
This is how it looks on my old laptop:
And this is how it looks on my normal desktop machine, which also has Intel graphics but it never gives me problems. Goldfeather makes no difference.
It seems 2 is sufficient on this machine but the old machine needs 4.
The manual says "Integer number of "inward" curves, ie. expected path crossings of an arbitrary line through the polygon." in one place and "The convexity parameter specifies the maximum number of front sides (back sides) a ray intersecting the object might penetrate" in another.
Neither statement is clear to me. What does " front sides (back sides)" mean?
If it is simply the maximum number of edges a line can pass through then I agree it should be 4 for a tube.
_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org


I found on my dodgy machine having convexity higher goes wrong again.
Here is it swept from 1 to 10
4, 5, 8 and 9 work.
The actual tube is correct for 2 onward, as it should be, but the back faces of the subtrahend get displayed for some values of convexity. That never happens on my good machine. This is what OpenCSG says:
"The convexity of a primitive is the maximum number of front (or back) faces of the primitive at a single position. For example, the convexity of a sphere is one and the convexity of a torus is two. "
So it it seems 2 is the correct value for a tube and the OpenSCAD manual is misleading.
However if that was the case why doesn't it default to 2, because for a convex shape 2 in the minimum. And why isn't it called concavity as it is concave shapes that go wrong?
This is a distilled version of the code I was having a problem with:
for(c = [1:4]) translate([c * 40, 0]) difference () { linear_extrude(height = 50, center = true, convexity = c) difference() { circle(5); circle(4); } translate([0, 0, 20]) cube(20, center = true); }
This is how it looks on my old laptop:
And this is how it looks on my normal desktop machine, which also has Intel graphics but it never gives me problems. Goldfeather makes no difference.
It seems 2 is sufficient on this machine but the old machine needs 4.
The manual says "Integer number of "inward" curves, ie. expected path crossings of an arbitrary line through the polygon." in one place and "The convexity parameter specifies the maximum number of front sides (back sides) a ray intersecting the object might penetrate" in another.
Neither statement is clear to me. What does " front sides (back sides)" mean?
If it is simply the maximum number of edges a line can pass through then I agree it should be 4 for a tube.
_______________________________________________
OpenSCAD mailing list
[hidden email]
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

