discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

Module Disappears In Render

LM
Leonard Martin Struttmann
Wed, Sep 1, 2021 1:53 AM

Ok, this one has me stumped.  This is an excerpt from a larger model, I've
simplified it as much as I can.

When I Preview, both modules, board() and outerRing(), are shown. [See
attached]

When I Render, only board() is displayed. [See attached]

Obviously, I'm missing something simple here, but what?

Thanks!
Len


$fn = 48;

RPiHQcamera();

boardXYZ            = [ 38, 38, 1.4 ];
boardCornerR        = 2;
boardExtentZ        = boardXYZ.z;

outerRingPetalCount  = 48;
outerRingPetalWidth  = 360 / outerRingPetalCount;

outerRingOuterR      = 36/2;
outerRingInnerR      = 35.4/2;
outerRingPetalHeight = outerRingOuterR - outerRingInnerR;
outerRingZ          = 10.2;

p = [ [0,0], for (a=[-15:15]) let (
r = a/4,
theta = 90+(a * 180/15) )
[ (outerRingOuterR+outerRingPetalHeight*sin(theta))cos(r),
(outerRingOuterR+outerRingPetalHeight
sin(theta))*sin(r)] ];

module outerRing()
{
translate( [ 0, 0, boardExtentZ] )
linear_extrude( outerRingZ )
//  for ( i=[0:47] )
//  for ( i=[0:0] )
for ( i=[0:1] )
{
rotate( 7.5*i )
polygon( p );
}
}

module board()
{
linear_extrude( boardXYZ.z )
hull()
for (i=[-1:2:1], j=[-1:2:1] )
{
translate( [ i*(0.5boardXYZ.x-boardCornerR),
j
(0.5*boardXYZ.y-boardCornerR) ] )
circle( r=boardCornerR );
}
}

//******************************
module RPiHQcamera()
//******************************
{
board();
outerRing();
}
//******************************

Ok, this one has me stumped. This is an excerpt from a larger model, I've simplified it as much as I can. When I Preview, both modules, board() and outerRing(), are shown. [See attached] When I Render, only board() is displayed. [See attached] Obviously, I'm missing something simple here, but what? Thanks! Len ------------------------------------------------------- $fn = 48; RPiHQcamera(); boardXYZ = [ 38, 38, 1.4 ]; boardCornerR = 2; boardExtentZ = boardXYZ.z; outerRingPetalCount = 48; outerRingPetalWidth = 360 / outerRingPetalCount; outerRingOuterR = 36/2; outerRingInnerR = 35.4/2; outerRingPetalHeight = outerRingOuterR - outerRingInnerR; outerRingZ = 10.2; p = [ [0,0], for (a=[-15:15]) let ( r = a/4, theta = 90+(a * 180/15) ) [ (outerRingOuterR+outerRingPetalHeight*sin(theta))*cos(r), (outerRingOuterR+outerRingPetalHeight*sin(theta))*sin(r)] ]; module outerRing() { translate( [ 0, 0, boardExtentZ] ) linear_extrude( outerRingZ ) // for ( i=[0:47] ) // for ( i=[0:0] ) for ( i=[0:1] ) { rotate( 7.5*i ) polygon( p ); } } module board() { linear_extrude( boardXYZ.z ) hull() for (i=[-1:2:1], j=[-1:2:1] ) { translate( [ i*(0.5*boardXYZ.x-boardCornerR), j*(0.5*boardXYZ.y-boardCornerR) ] ) circle( r=boardCornerR ); } } //****************************** module RPiHQcamera() //****************************** { board(); outerRing(); } //******************************
M
MichaelAtOz
Wed, Sep 1, 2021 4:02 AM

The multiple polygons are sharing an edge which is not manifold.

Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the first polygons face.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Wed, 1 Sep 2021 11:53
To: OpenSCAD general discussion
Subject: [OpenSCAD] Module Disappears In Render

Ok, this one has me stumped.  This is an excerpt from a larger model, I've simplified it as much as I can.

When I Preview, both modules, board() and outerRing(), are shown. [See attached]

When I Render, only board() is displayed. [See attached]

Obviously, I'm missing something simple here, but what?

Thanks!

Len


$fn = 48;

RPiHQcamera();

boardXYZ            = [ 38, 38, 1.4 ];
boardCornerR        = 2;
boardExtentZ        = boardXYZ.z;

outerRingPetalCount  = 48;
outerRingPetalWidth  = 360 / outerRingPetalCount;

outerRingOuterR      = 36/2;
outerRingInnerR      = 35.4/2;
outerRingPetalHeight = outerRingOuterR - outerRingInnerR;
outerRingZ          = 10.2;

p = [ [0,0], for (a=[-15:15]) let (
r = a/4,
theta = 90+(a * 180/15) )
[ (outerRingOuterR+outerRingPetalHeight*sin(theta))cos(r), (outerRingOuterR+outerRingPetalHeightsin(theta))*sin(r)] ];

module outerRing()
{
translate( [ 0, 0, boardExtentZ] )
linear_extrude( outerRingZ )
//  for ( i=[0:47] )
//  for ( i=[0:0] )
for ( i=[0:1] )
{
rotate( 7.5*i )
polygon( p );
}
}

module board()
{
linear_extrude( boardXYZ.z )
hull()
for (i=[-1:2:1], j=[-1:2:1] )
{
translate( [ i*(0.5boardXYZ.x-boardCornerR), j(0.5*boardXYZ.y-boardCornerR) ] )
circle( r=boardCornerR );
}
}

//******************************
module RPiHQcamera()
//******************************
{
board();
outerRing();
}
//******************************

--
This email has been checked for viruses by AVG.
https://www.avg.com

The multiple polygons are sharing an edge which is not manifold. Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the first polygons face. _____ From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] Sent: Wed, 1 Sep 2021 11:53 To: OpenSCAD general discussion Subject: [OpenSCAD] Module Disappears In Render Ok, this one has me stumped. This is an excerpt from a larger model, I've simplified it as much as I can. When I Preview, both modules, board() and outerRing(), are shown. [See attached] When I Render, only board() is displayed. [See attached] Obviously, I'm missing something simple here, but what? Thanks! Len ------------------------------------------------------- $fn = 48; RPiHQcamera(); boardXYZ = [ 38, 38, 1.4 ]; boardCornerR = 2; boardExtentZ = boardXYZ.z; outerRingPetalCount = 48; outerRingPetalWidth = 360 / outerRingPetalCount; outerRingOuterR = 36/2; outerRingInnerR = 35.4/2; outerRingPetalHeight = outerRingOuterR - outerRingInnerR; outerRingZ = 10.2; p = [ [0,0], for (a=[-15:15]) let ( r = a/4, theta = 90+(a * 180/15) ) [ (outerRingOuterR+outerRingPetalHeight*sin(theta))*cos(r), (outerRingOuterR+outerRingPetalHeight*sin(theta))*sin(r)] ]; module outerRing() { translate( [ 0, 0, boardExtentZ] ) linear_extrude( outerRingZ ) // for ( i=[0:47] ) // for ( i=[0:0] ) for ( i=[0:1] ) { rotate( 7.5*i ) polygon( p ); } } module board() { linear_extrude( boardXYZ.z ) hull() for (i=[-1:2:1], j=[-1:2:1] ) { translate( [ i*(0.5*boardXYZ.x-boardCornerR), j*(0.5*boardXYZ.y-boardCornerR) ] ) circle( r=boardCornerR ); } } //****************************** module RPiHQcamera() //****************************** { board(); outerRing(); } //****************************** -- This email has been checked for viruses by AVG. https://www.avg.com
LM
Leonard Martin Struttmann
Wed, Sep 1, 2021 1:47 PM

"The multiple polygons are sharing an edge which is not manifold.

*Use rotate( (7.5-0.1)i ) which moves the second polygons face inside the
first polygons face."

Thanks, but I do not think that is the ultimate solution.  What if I wanted
the polygons to be separated and put

rotate( 10*i )

?  Then I'm back to the same problem.

Additional info:  When done individually, both board() and outerRing()
render fine.  It's only when I have both of them that the problem occurs.

On Tue, Aug 31, 2021 at 11:03 PM MichaelAtOz oz.at.michael@gmail.com
wrote:

The multiple polygons are sharing an edge which is not manifold.

Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the
first polygons face.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Wed, 1 Sep 2021 11:53
To: OpenSCAD general discussion
Subject: [OpenSCAD] Module Disappears In Render

Ok, this one has me stumped.  This is an excerpt from a larger model, I've
simplified it as much as I can.

When I Preview, both modules, board() and outerRing(), are shown. [See
attached]

When I Render, only board() is displayed. [See attached]

Obviously, I'm missing something simple here, but what?

Thanks!

Len


$fn = 48;

RPiHQcamera();

boardXYZ            = [ 38, 38, 1.4 ];
boardCornerR        = 2;
boardExtentZ        = boardXYZ.z;

outerRingPetalCount  = 48;
outerRingPetalWidth  = 360 / outerRingPetalCount;

outerRingOuterR      = 36/2;
outerRingInnerR      = 35.4/2;
outerRingPetalHeight = outerRingOuterR - outerRingInnerR;
outerRingZ          = 10.2;

p = [ [0,0], for (a=[-15:15]) let (
r = a/4,
theta = 90+(a * 180/15) )
[ (outerRingOuterR+outerRingPetalHeight*sin(theta))cos(r),
(outerRingOuterR+outerRingPetalHeight
sin(theta))*sin(r)] ];

module outerRing()
{
translate( [ 0, 0, boardExtentZ] )
linear_extrude( outerRingZ )
//  for ( i=[0:47] )
//  for ( i=[0:0] )
for ( i=[0:1] )
{
rotate( 7.5*i )
polygon( p );
}
}

module board()
{
linear_extrude( boardXYZ.z )
hull()
for (i=[-1:2:1], j=[-1:2:1] )
{
translate( [ i*(0.5boardXYZ.x-boardCornerR),
j
(0.5*boardXYZ.y-boardCornerR) ] )
circle( r=boardCornerR );
}
}

//******************************
module RPiHQcamera()
//******************************
{
board();
outerRing();
}
//******************************

http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient Virus-free.
www.avg.com
http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
<#m_-6044723767729359281_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

*"The multiple polygons are sharing an edge which is not manifold.* *Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the first polygons face."* Thanks, but I do not think that is the ultimate solution. What if I wanted the polygons to be separated and put rotate( 10*i ) ? Then I'm back to the same problem. Additional info: When done individually, both board() and outerRing() render fine. It's only when I have both of them that the problem occurs. On Tue, Aug 31, 2021 at 11:03 PM MichaelAtOz <oz.at.michael@gmail.com> wrote: > The multiple polygons are sharing an edge which is not manifold. > > > > Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the > first polygons face. > > > > > ------------------------------ > > *From:* Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] > *Sent:* Wed, 1 Sep 2021 11:53 > *To:* OpenSCAD general discussion > *Subject:* [OpenSCAD] Module Disappears In Render > > > > Ok, this one has me stumped. This is an excerpt from a larger model, I've > simplified it as much as I can. > > > > When I Preview, both modules, board() and outerRing(), are shown. [See > attached] > > > > When I Render, only board() is displayed. [See attached] > > > > Obviously, I'm missing something simple here, but what? > > > > Thanks! > > Len > > > > ------------------------------------------------------- > > $fn = 48; > > RPiHQcamera(); > > boardXYZ = [ 38, 38, 1.4 ]; > boardCornerR = 2; > boardExtentZ = boardXYZ.z; > > outerRingPetalCount = 48; > outerRingPetalWidth = 360 / outerRingPetalCount; > > outerRingOuterR = 36/2; > outerRingInnerR = 35.4/2; > outerRingPetalHeight = outerRingOuterR - outerRingInnerR; > outerRingZ = 10.2; > > p = [ [0,0], for (a=[-15:15]) let ( > r = a/4, > theta = 90+(a * 180/15) ) > [ (outerRingOuterR+outerRingPetalHeight*sin(theta))*cos(r), > (outerRingOuterR+outerRingPetalHeight*sin(theta))*sin(r)] ]; > > > module outerRing() > { > translate( [ 0, 0, boardExtentZ] ) > linear_extrude( outerRingZ ) > // for ( i=[0:47] ) > // for ( i=[0:0] ) > for ( i=[0:1] ) > { > rotate( 7.5*i ) > polygon( p ); > } > } > > > module board() > { > linear_extrude( boardXYZ.z ) > hull() > for (i=[-1:2:1], j=[-1:2:1] ) > { > translate( [ i*(0.5*boardXYZ.x-boardCornerR), > j*(0.5*boardXYZ.y-boardCornerR) ] ) > circle( r=boardCornerR ); > } > } > > > //****************************** > module RPiHQcamera() > //****************************** > { > board(); > outerRing(); > } > //****************************** > > > > > > <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> Virus-free. > www.avg.com > <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> > <#m_-6044723767729359281_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >
M
MichaelAtOz
Wed, Sep 1, 2021 2:11 PM

When done individually, both board() and outerRing() render fine.  It's only when I have both of them that the problem occurs.

When you have one object, you do not get a implicit union, so there is no conflict, try adding cube(1) or square(1) and you will see.

What if I wanted the polygons to be separated

Fine. As long as they do not share a face/line.

Your original code had the right face of one polygon, identical to the left face of the next one. Either trust me that they can't coexist, or research 'nonmanifold'.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Wed, 1 Sep 2021 23:48
To: OpenSCAD general discussion
Subject: [OpenSCAD] Re: Module Disappears In Render

"The multiple polygons are sharing an edge which is not manifold.

Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the first polygons face."

Thanks, but I do not think that is the ultimate solution.  What if I wanted the polygons to be separated and put

rotate( 10*i )

?  Then I'm back to the same problem.

Additional info:  When done individually, both board() and outerRing() render fine.  It's only when I have both of them that the problem occurs.

On Tue, Aug 31, 2021 at 11:03 PM MichaelAtOz oz.at.michael@gmail.com wrote:

The multiple polygons are sharing an edge which is not manifold.

Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the first polygons face.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Wed, 1 Sep 2021 11:53
To: OpenSCAD general discussion
Subject: [OpenSCAD] Module Disappears In Render

Ok, this one has me stumped.  This is an excerpt from a larger model, I've simplified it as much as I can.

When I Preview, both modules, board() and outerRing(), are shown. [See attached]

When I Render, only board() is displayed. [See attached]

Obviously, I'm missing something simple here, but what?

Thanks!

Len


$fn = 48;

RPiHQcamera();

boardXYZ            = [ 38, 38, 1.4 ];
boardCornerR        = 2;
boardExtentZ        = boardXYZ.z;

outerRingPetalCount  = 48;
outerRingPetalWidth  = 360 / outerRingPetalCount;

outerRingOuterR      = 36/2;
outerRingInnerR      = 35.4/2;
outerRingPetalHeight = outerRingOuterR - outerRingInnerR;
outerRingZ          = 10.2;

p = [ [0,0], for (a=[-15:15]) let (
r = a/4,
theta = 90+(a * 180/15) )
[ (outerRingOuterR+outerRingPetalHeight*sin(theta))cos(r), (outerRingOuterR+outerRingPetalHeightsin(theta))*sin(r)] ];

module outerRing()
{
translate( [ 0, 0, boardExtentZ] )
linear_extrude( outerRingZ )
//  for ( i=[0:47] )
//  for ( i=[0:0] )
for ( i=[0:1] )
{
rotate( 7.5*i )
polygon( p );
}
}

module board()
{
linear_extrude( boardXYZ.z )
hull()
for (i=[-1:2:1], j=[-1:2:1] )
{
translate( [ i*(0.5boardXYZ.x-boardCornerR), j(0.5*boardXYZ.y-boardCornerR) ] )
circle( r=boardCornerR );
}
}

//******************************
module RPiHQcamera()
//******************************
{
board();
outerRing();
}
//******************************

http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient

Virus-free.  http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient www.avg.com


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

--
This email has been checked for viruses by AVG.
https://www.avg.com

> When done individually, both board() and outerRing() render fine. It's only when I have both of them that the problem occurs. When you have one object, you do not get a implicit union, so there is no conflict, try adding cube(1) or square(1) and you will see. > What if I wanted the polygons to be separated Fine. As long as they do not share a face/line. Your original code had the right face of one polygon, identical to the left face of the next one. Either trust me that they can't coexist, or research 'nonmanifold'. _____ From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] Sent: Wed, 1 Sep 2021 23:48 To: OpenSCAD general discussion Subject: [OpenSCAD] Re: Module Disappears In Render "The multiple polygons are sharing an edge which is not manifold. Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the first polygons face." Thanks, but I do not think that is the ultimate solution. What if I wanted the polygons to be separated and put rotate( 10*i ) ? Then I'm back to the same problem. Additional info: When done individually, both board() and outerRing() render fine. It's only when I have both of them that the problem occurs. On Tue, Aug 31, 2021 at 11:03 PM MichaelAtOz <oz.at.michael@gmail.com> wrote: The multiple polygons are sharing an edge which is not manifold. Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the first polygons face. _____ From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] Sent: Wed, 1 Sep 2021 11:53 To: OpenSCAD general discussion Subject: [OpenSCAD] Module Disappears In Render Ok, this one has me stumped. This is an excerpt from a larger model, I've simplified it as much as I can. When I Preview, both modules, board() and outerRing(), are shown. [See attached] When I Render, only board() is displayed. [See attached] Obviously, I'm missing something simple here, but what? Thanks! Len ------------------------------------------------------- $fn = 48; RPiHQcamera(); boardXYZ = [ 38, 38, 1.4 ]; boardCornerR = 2; boardExtentZ = boardXYZ.z; outerRingPetalCount = 48; outerRingPetalWidth = 360 / outerRingPetalCount; outerRingOuterR = 36/2; outerRingInnerR = 35.4/2; outerRingPetalHeight = outerRingOuterR - outerRingInnerR; outerRingZ = 10.2; p = [ [0,0], for (a=[-15:15]) let ( r = a/4, theta = 90+(a * 180/15) ) [ (outerRingOuterR+outerRingPetalHeight*sin(theta))*cos(r), (outerRingOuterR+outerRingPetalHeight*sin(theta))*sin(r)] ]; module outerRing() { translate( [ 0, 0, boardExtentZ] ) linear_extrude( outerRingZ ) // for ( i=[0:47] ) // for ( i=[0:0] ) for ( i=[0:1] ) { rotate( 7.5*i ) polygon( p ); } } module board() { linear_extrude( boardXYZ.z ) hull() for (i=[-1:2:1], j=[-1:2:1] ) { translate( [ i*(0.5*boardXYZ.x-boardCornerR), j*(0.5*boardXYZ.y-boardCornerR) ] ) circle( r=boardCornerR ); } } //****************************** module RPiHQcamera() //****************************** { board(); outerRing(); } //****************************** <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> Virus-free. <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> www.avg.com _______________________________________________ OpenSCAD mailing list To unsubscribe send an email to discuss-leave@lists.openscad.org -- This email has been checked for viruses by AVG. https://www.avg.com
LM
Leonard Martin Struttmann
Wed, Sep 1, 2021 3:18 PM

Thanks!  So, merely separating the polygons with rotate( 10*i ) did NOT
solve the problem, since all of the polygons started at [0,0].

Two solutions:

  1. Move the center point ever so slightly:

p = [ [0.001,0], for (a=[-15:15]) let (
r = a/4,
theta = 90+(a * 180/15) )
[ (outerRingOuterR+outerRingPetalHeight*sin(theta))cos(r),
(outerRingOuterR+outerRingPetalHeight
sin(theta))*sin(r)] ];

module outerRing()
{
translate( [ 0, 0, boardExtentZ] )
linear_extrude( outerRingZ, convexity=100 )
for ( i=[0:47] )
{
rotate( 7.5*i )
polygon( p );
}
}

  1. Just make one polygon:

p = [ for (a=[-1804:1804]) let (
r = a/4,
theta = 90+(a * 180/15) )
[ (outerRingOuterR+outerRingPetalHeight*sin(theta))cos(r),
(outerRingOuterR+outerRingPetalHeight
sin(theta))*sin(r)] ];

module outerRing()
{
translate( [ 0, 0, boardExtentZ] )
linear_extrude( outerRingZ, convexity=100 )
polygon( p );
}

My only questions, then, are: Why did outerRing(), by itself, render
successfully and produce an STL that Cura is happy with?  That is, why did
the problem only occur when another module is introduced?  Also, why are
there no warnings or errors?

On Wed, Sep 1, 2021 at 9:12 AM MichaelAtOz oz.at.michael@gmail.com wrote:

When done individually, both board() and outerRing() render fine.  It's

only when I have both of them that the problem occurs.

When you have one object, you do not get a implicit union, so there is no
conflict, try adding cube(1) or square(1) and you will see.

What if I wanted the polygons to be separated

Fine. As long as they do not share a face/line.

Your original code had the right face of one polygon, identical to the
left face of the next one. Either trust me that they can't coexist, or
research 'nonmanifold'.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Wed, 1 Sep 2021 23:48
To: OpenSCAD general discussion
Subject: [OpenSCAD] Re: Module Disappears In Render

*"*The multiple polygons are sharing an edge which is not manifold.

*Use rotate( (7.5-0.1)i ) which moves the second polygons face inside the
first polygons face.**"

Thanks, but I do not think that is the ultimate solution.  What if I
wanted the polygons to be separated and put

rotate( 10*i )

?  Then I'm back to the same problem.

Additional info:  When done individually, both board() and outerRing()
render fine.  It's only when I have both of them that the problem occurs.

On Tue, Aug 31, 2021 at 11:03 PM MichaelAtOz oz.at.michael@gmail.com
wrote:

The multiple polygons are sharing an edge which is not manifold.

Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the
first polygons face.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Wed, 1 Sep 2021 11:53
To: OpenSCAD general discussion
Subject: [OpenSCAD] Module Disappears In Render

Ok, this one has me stumped.  This is an excerpt from a larger model, I've
simplified it as much as I can.

When I Preview, both modules, board() and outerRing(), are shown. [See
attached]

When I Render, only board() is displayed. [See attached]

Obviously, I'm missing something simple here, but what?

Thanks!

Len


$fn = 48;

RPiHQcamera();

boardXYZ            = [ 38, 38, 1.4 ];
boardCornerR        = 2;
boardExtentZ        = boardXYZ.z;

outerRingPetalCount  = 48;
outerRingPetalWidth  = 360 / outerRingPetalCount;

outerRingOuterR      = 36/2;
outerRingInnerR      = 35.4/2;
outerRingPetalHeight = outerRingOuterR - outerRingInnerR;
outerRingZ          = 10.2;

p = [ [0,0], for (a=[-15:15]) let (
r = a/4,
theta = 90+(a * 180/15) )
[ (outerRingOuterR+outerRingPetalHeight*sin(theta))cos(r),
(outerRingOuterR+outerRingPetalHeight
sin(theta))*sin(r)] ];

module outerRing()
{
translate( [ 0, 0, boardExtentZ] )
linear_extrude( outerRingZ )
//  for ( i=[0:47] )
//  for ( i=[0:0] )
for ( i=[0:1] )
{
rotate( 7.5*i )
polygon( p );
}
}

module board()
{
linear_extrude( boardXYZ.z )
hull()
for (i=[-1:2:1], j=[-1:2:1] )
{
translate( [ i*(0.5boardXYZ.x-boardCornerR),
j
(0.5*boardXYZ.y-boardCornerR) ] )
circle( r=boardCornerR );
}
}

//******************************
module RPiHQcamera()
//******************************
{
board();
outerRing();
}
//******************************

http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient

Virus-free. www.avg.com
http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient

<#m_-8402297447628402683_m_-6044723767729359281_DAB4FAD8-2DD7-40>


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

Thanks! So, merely separating the polygons with rotate( 10*i ) did NOT solve the problem, since all of the polygons started at [0,0]. Two solutions: 1) Move the center point ever so slightly: p = [ [0.001,0], for (a=[-15:15]) let ( r = a/4, theta = 90+(a * 180/15) ) [ (outerRingOuterR+outerRingPetalHeight*sin(theta))*cos(r), (outerRingOuterR+outerRingPetalHeight*sin(theta))*sin(r)] ]; module outerRing() { translate( [ 0, 0, boardExtentZ] ) linear_extrude( outerRingZ, convexity=100 ) for ( i=[0:47] ) { rotate( 7.5*i ) polygon( p ); } } 2) Just make one polygon: p = [ for (a=[-180*4:180*4]) let ( r = a/4, theta = 90+(a * 180/15) ) [ (outerRingOuterR+outerRingPetalHeight*sin(theta))*cos(r), (outerRingOuterR+outerRingPetalHeight*sin(theta))*sin(r)] ]; module outerRing() { translate( [ 0, 0, boardExtentZ] ) linear_extrude( outerRingZ, convexity=100 ) polygon( p ); } My only questions, then, are: Why did outerRing(), by itself, render successfully and produce an STL that Cura is happy with? That is, why did the problem only occur when another module is introduced? Also, why are there no warnings or errors? On Wed, Sep 1, 2021 at 9:12 AM MichaelAtOz <oz.at.michael@gmail.com> wrote: > > When done individually, both board() and outerRing() render fine. It's > only when I have both of them that the problem occurs. > > When you have one object, you do not get a implicit union, so there is no > conflict, try adding cube(1) or square(1) and you will see. > > > > > What if I wanted the polygons to be separated > > > > Fine. As long as they do not share a face/line. > > Your original code had the right face of one polygon, identical to the > left face of the next one. Either trust me that they can't coexist, or > research 'nonmanifold'. > > > > > ------------------------------ > > *From:* Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] > *Sent:* Wed, 1 Sep 2021 23:48 > *To:* OpenSCAD general discussion > *Subject:* [OpenSCAD] Re: Module Disappears In Render > > > > *"**The multiple polygons are sharing an edge which is not manifold.* > > > > *Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the > first polygons face.**"* > > > > Thanks, but I do not think that is the ultimate solution. What if I > wanted the polygons to be separated and put > > > > rotate( 10*i ) > > > > ? Then I'm back to the same problem. > > > > Additional info: When done individually, both board() and outerRing() > render fine. It's only when I have both of them that the problem occurs. > > > > > > > > On Tue, Aug 31, 2021 at 11:03 PM MichaelAtOz <oz.at.michael@gmail.com> > wrote: > > The multiple polygons are sharing an edge which is not manifold. > > > > Use rotate( (7.5-0.1)*i ) which moves the second polygons face inside the > first polygons face. > > > > > ------------------------------ > > *From:* Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] > *Sent:* Wed, 1 Sep 2021 11:53 > *To:* OpenSCAD general discussion > *Subject:* [OpenSCAD] Module Disappears In Render > > > > Ok, this one has me stumped. This is an excerpt from a larger model, I've > simplified it as much as I can. > > > > When I Preview, both modules, board() and outerRing(), are shown. [See > attached] > > > > When I Render, only board() is displayed. [See attached] > > > > Obviously, I'm missing something simple here, but what? > > > > Thanks! > > Len > > > > ------------------------------------------------------- > > $fn = 48; > > RPiHQcamera(); > > boardXYZ = [ 38, 38, 1.4 ]; > boardCornerR = 2; > boardExtentZ = boardXYZ.z; > > outerRingPetalCount = 48; > outerRingPetalWidth = 360 / outerRingPetalCount; > > outerRingOuterR = 36/2; > outerRingInnerR = 35.4/2; > outerRingPetalHeight = outerRingOuterR - outerRingInnerR; > outerRingZ = 10.2; > > p = [ [0,0], for (a=[-15:15]) let ( > r = a/4, > theta = 90+(a * 180/15) ) > [ (outerRingOuterR+outerRingPetalHeight*sin(theta))*cos(r), > (outerRingOuterR+outerRingPetalHeight*sin(theta))*sin(r)] ]; > > > module outerRing() > { > translate( [ 0, 0, boardExtentZ] ) > linear_extrude( outerRingZ ) > // for ( i=[0:47] ) > // for ( i=[0:0] ) > for ( i=[0:1] ) > { > rotate( 7.5*i ) > polygon( p ); > } > } > > > module board() > { > linear_extrude( boardXYZ.z ) > hull() > for (i=[-1:2:1], j=[-1:2:1] ) > { > translate( [ i*(0.5*boardXYZ.x-boardCornerR), > j*(0.5*boardXYZ.y-boardCornerR) ] ) > circle( r=boardCornerR ); > } > } > > > //****************************** > module RPiHQcamera() > //****************************** > { > board(); > outerRing(); > } > //****************************** > > > > > > <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> > > Virus-free. www.avg.com > <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> > > <#m_-8402297447628402683_m_-6044723767729359281_DAB4FAD8-2DD7-40> > > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org > > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >
JB
Jordan Brown
Wed, Sep 1, 2021 4:20 PM

On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote:

My only questions, then, are: Why did outerRing(), by itself, render
successfully and produce an STL that Cura is happy with?  That is, why
did the problem only occur when another module is introduced?

CGAL is what really dislikes objects that aren't perfectly formed, and
doesn't get involved unless there's more than one object.

  Also, why are there no warnings or errors?

In 2021.01 I get:

Parsing design (AST generation)...
Saved backup file:
C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad
Compiling design (CSG Tree generation)...
Rendering Polygon Mesh using CGAL...
ERROR: The given mesh is not closed! Unable to convert to
CGAL_Nef_Polyhedron.
Geometries in cache: 19
Geometry cache size in bytes: 1412968
CGAL Polyhedrons in cache: 1
[...]

But I don't get the error when I F6 again.  I assume that either the bad
result has been cached, or the "suppress duplicate error reports" stuff
is getting involved.

I have one suggestion and a pointless rant:

Suggestion:  caching the results of renders that encountered errors is
probably bad.

Pointless rant:  CGL is too darned picky about its polyhedra.

On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote: > My only questions, then, are: Why did outerRing(), by itself, render > successfully and produce an STL that Cura is happy with?  That is, why > did the problem only occur when another module is introduced? CGAL is what really dislikes objects that aren't perfectly formed, and doesn't get involved unless there's more than one object. >   Also, why are there no warnings or errors? In 2021.01 I get: Parsing design (AST generation)... Saved backup file: C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad Compiling design (CSG Tree generation)... Rendering Polygon Mesh using CGAL... ERROR: The given mesh is not closed! Unable to convert to CGAL_Nef_Polyhedron. Geometries in cache: 19 Geometry cache size in bytes: 1412968 CGAL Polyhedrons in cache: 1 [...] But I don't get the error when I F6 again.  I assume that either the bad result has been cached, or the "suppress duplicate error reports" stuff is getting involved. I have one suggestion and a pointless rant: Suggestion:  caching the results of renders that encountered errors is probably bad. Pointless rant:  CGL is too darned picky about its polyhedra.
LM
Leonard Martin Struttmann
Wed, Sep 1, 2021 7:45 PM

Wow!  Yes, just that single error the first time.

Thanks, everyone!

On Wed, Sep 1, 2021 at 11:20 AM Jordan Brown openscad@jordan.maileater.net
wrote:

On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote:

My only questions, then, are: Why did outerRing(), by itself, render
successfully and produce an STL that Cura is happy with?  That is, why did
the problem only occur when another module is introduced?

CGAL is what really dislikes objects that aren't perfectly formed, and
doesn't get involved unless there's more than one object.

Also, why are there no warnings or errors?

In 2021.01 I get:

Parsing design (AST generation)...
Saved backup file:
C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad
Compiling design (CSG Tree generation)...
Rendering Polygon Mesh using CGAL...
ERROR: The given mesh is not closed! Unable to convert to
CGAL_Nef_Polyhedron.
Geometries in cache: 19
Geometry cache size in bytes: 1412968
CGAL Polyhedrons in cache: 1
[...]

But I don't get the error when I F6 again.  I assume that either the bad
result has been cached, or the "suppress duplicate error reports" stuff is
getting involved.

I have one suggestion and a pointless rant:

Suggestion:  caching the results of renders that encountered errors is
probably bad.

Pointless rant:  CGL is too darned picky about its polyhedra.

Wow! Yes, just that single error the first time. Thanks, everyone! On Wed, Sep 1, 2021 at 11:20 AM Jordan Brown <openscad@jordan.maileater.net> wrote: > On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote: > > My only questions, then, are: Why did outerRing(), by itself, render > successfully and produce an STL that Cura is happy with? That is, why did > the problem only occur when another module is introduced? > > > CGAL is what really dislikes objects that aren't perfectly formed, and > doesn't get involved unless there's more than one object. > > Also, why are there no warnings or errors? > > > In 2021.01 I get: > > Parsing design (AST generation)... > Saved backup file: > C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad > Compiling design (CSG Tree generation)... > Rendering Polygon Mesh using CGAL... > ERROR: The given mesh is not closed! Unable to convert to > CGAL_Nef_Polyhedron. > Geometries in cache: 19 > Geometry cache size in bytes: 1412968 > CGAL Polyhedrons in cache: 1 > [...] > > But I don't get the error when I F6 again. I assume that either the bad > result has been cached, or the "suppress duplicate error reports" stuff is > getting involved. > > I have one suggestion and a pointless rant: > > Suggestion: caching the results of renders that encountered errors is > probably bad. > > Pointless rant: CGL is too darned picky about its polyhedra. > > > >
M
MichaelAtOz
Wed, Sep 1, 2021 10:41 PM

Yes, as that node was evaluated (and got an error) the node was then cached, so subsequent F6 don't get evaluated again, so no error.

If you think something is strange, it is always worth doing Design/Flush-cache.

So, merely separating the polygons with rotate( 10*i ) did NOT solve the problem, since all of the polygons started at [0,0].

Sharing a point (2D) is also non-manifold, as is sharing a single edge (3D).

The rule of thumb with multiple objects, either clearly separated or embed part of one within the other, don't just park them touching side to side.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Thu, 2 Sep 2021 05:45
To: OpenSCAD general discussion
Subject: [OpenSCAD] Re: Module Disappears In Render

Wow!  Yes, just that single error the first time.

Thanks, everyone!

On Wed, Sep 1, 2021 at 11:20 AM Jordan Brown openscad@jordan.maileater.net wrote:

On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote:

My only questions, then, are: Why did outerRing(), by itself, render successfully and produce an STL that Cura is happy with?  That is, why did the problem only occur when another module is introduced?

CGAL is what really dislikes objects that aren't perfectly formed, and doesn't get involved unless there's more than one object.

Also, why are there no warnings or errors?

In 2021.01 I get:

Parsing design (AST generation)...
Saved backup file: C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad
Compiling design (CSG Tree generation)...
Rendering Polygon Mesh using CGAL...
ERROR: The given mesh is not closed! Unable to convert to CGAL_Nef_Polyhedron.
Geometries in cache: 19
Geometry cache size in bytes: 1412968
CGAL Polyhedrons in cache: 1
[...]

But I don't get the error when I F6 again.  I assume that either the bad result has been cached, or the "suppress duplicate error reports" stuff is getting involved.

I have one suggestion and a pointless rant:

Suggestion:  caching the results of renders that encountered errors is probably bad.

Pointless rant:  CGL is too darned picky about its polyhedra.

--
This email has been checked for viruses by AVG.
https://www.avg.com

Yes, as that node was evaluated (and got an error) the node was then cached, so subsequent F6 don't get evaluated again, so no error. If you think something is strange, it is always worth doing Design/Flush-cache. > So, merely separating the polygons with rotate( 10*i ) did NOT solve the problem, since all of the polygons started at [0,0]. Sharing a point (2D) is also non-manifold, as is sharing a single edge (3D). The rule of thumb with multiple objects, either clearly separated or embed part of one within the other, don't just park them touching side to side. _____ From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] Sent: Thu, 2 Sep 2021 05:45 To: OpenSCAD general discussion Subject: [OpenSCAD] Re: Module Disappears In Render Wow! Yes, just that single error the first time. Thanks, everyone! On Wed, Sep 1, 2021 at 11:20 AM Jordan Brown <openscad@jordan.maileater.net> wrote: On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote: My only questions, then, are: Why did outerRing(), by itself, render successfully and produce an STL that Cura is happy with? That is, why did the problem only occur when another module is introduced? CGAL is what really dislikes objects that aren't perfectly formed, and doesn't get involved unless there's more than one object. Also, why are there no warnings or errors? In 2021.01 I get: Parsing design (AST generation)... Saved backup file: C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad Compiling design (CSG Tree generation)... Rendering Polygon Mesh using CGAL... ERROR: The given mesh is not closed! Unable to convert to CGAL_Nef_Polyhedron. Geometries in cache: 19 Geometry cache size in bytes: 1412968 CGAL Polyhedrons in cache: 1 [...] But I don't get the error when I F6 again. I assume that either the bad result has been cached, or the "suppress duplicate error reports" stuff is getting involved. I have one suggestion and a pointless rant: Suggestion: caching the results of renders that encountered errors is probably bad. Pointless rant: CGL is too darned picky about its polyhedra. -- This email has been checked for viruses by AVG. https://www.avg.com
LM
Leonard Martin Struttmann
Thu, Sep 2, 2021 5:55 PM

"The rule of thumb with multiple objects, either clearly separated or
embed part of one within the other, don't just park them touching side to
side."

MichaelAtOz, this statement confuses me.  I stack objects, face-to-face,
vertically and horizontally all the time with no problems.  Have I just
been lucky up until now? Or, is there a specific context that I'm missing?

On Wed, Sep 1, 2021 at 5:42 PM MichaelAtOz oz.at.michael@gmail.com wrote:

Yes, as that node was evaluated (and got an error) the node was then
cached, so subsequent F6 don't get evaluated again, so no error.

If you think something is strange, it is always worth doing
Design/Flush-cache.

So, merely separating the polygons with rotate( 10*i ) did NOT solve

the problem, since all of the polygons started at [0,0].

Sharing a point (2D) is also non-manifold, as is sharing a single edge
(3D).

The rule of thumb with multiple objects, either clearly separated or embed
part of one within the other, don't just park them touching side to side.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Thu, 2 Sep 2021 05:45
To: OpenSCAD general discussion
Subject: [OpenSCAD] Re: Module Disappears In Render

Wow!  Yes, just that single error the first time.

Thanks, everyone!

On Wed, Sep 1, 2021 at 11:20 AM Jordan Brown <
openscad@jordan.maileater.net> wrote:

On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote:

My only questions, then, are: Why did outerRing(), by itself, render
successfully and produce an STL that Cura is happy with?  That is, why did
the problem only occur when another module is introduced?

CGAL is what really dislikes objects that aren't perfectly formed, and
doesn't get involved unless there's more than one object.

Also, why are there no warnings or errors?

In 2021.01 I get:

Parsing design (AST generation)...
Saved backup file:
C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad
Compiling design (CSG Tree generation)...
Rendering Polygon Mesh using CGAL...
ERROR: The given mesh is not closed! Unable to convert to
CGAL_Nef_Polyhedron.
Geometries in cache: 19
Geometry cache size in bytes: 1412968
CGAL Polyhedrons in cache: 1
[...]

But I don't get the error when I F6 again.  I assume that either the bad
result has been cached, or the "suppress duplicate error reports" stuff is
getting involved.

I have one suggestion and a pointless rant:

Suggestion:  caching the results of renders that encountered errors is
probably bad.

Pointless rant:  CGL is too darned picky about its polyhedra.

http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient Virus-free.
www.avg.com
http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
<#m_2747962184919274479_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

*"The rule of thumb with multiple objects, either clearly separated or embed part of one within the other, don't just park them touching side to side."* MichaelAtOz, this statement confuses me. I stack objects, face-to-face, vertically and horizontally all the time with no problems. Have I just been lucky up until now? Or, is there a specific context that I'm missing? On Wed, Sep 1, 2021 at 5:42 PM MichaelAtOz <oz.at.michael@gmail.com> wrote: > Yes, as that node was evaluated (and got an error) the node was then > cached, so subsequent F6 don't get evaluated again, so no error. > > If you think something is strange, it is always worth doing > Design/Flush-cache. > > > > > So, merely separating the polygons with rotate( 10*i ) did NOT solve > the problem, since all of the polygons started at [0,0]. > > > > Sharing a point (2D) is also non-manifold, as is sharing a single edge > (3D). > > The rule of thumb with multiple objects, either clearly separated or embed > part of one within the other, don't just park them touching side to side. > > > ------------------------------ > > *From:* Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] > *Sent:* Thu, 2 Sep 2021 05:45 > *To:* OpenSCAD general discussion > *Subject:* [OpenSCAD] Re: Module Disappears In Render > > > > Wow! Yes, just that single error the first time. > > > > Thanks, everyone! > > > > > > On Wed, Sep 1, 2021 at 11:20 AM Jordan Brown < > openscad@jordan.maileater.net> wrote: > > On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote: > > My only questions, then, are: Why did outerRing(), by itself, render > successfully and produce an STL that Cura is happy with? That is, why did > the problem only occur when another module is introduced? > > > CGAL is what really dislikes objects that aren't perfectly formed, and > doesn't get involved unless there's more than one object. > > > Also, why are there no warnings or errors? > > > In 2021.01 I get: > > Parsing design (AST generation)... > Saved backup file: > C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad > Compiling design (CSG Tree generation)... > Rendering Polygon Mesh using CGAL... > ERROR: The given mesh is not closed! Unable to convert to > CGAL_Nef_Polyhedron. > Geometries in cache: 19 > Geometry cache size in bytes: 1412968 > CGAL Polyhedrons in cache: 1 > [...] > > But I don't get the error when I F6 again. I assume that either the bad > result has been cached, or the "suppress duplicate error reports" stuff is > getting involved. > > I have one suggestion and a pointless rant: > > Suggestion: caching the results of renders that encountered errors is > probably bad. > > Pointless rant: CGL is too darned picky about its polyhedra. > > > > > > > > <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> Virus-free. > www.avg.com > <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> > <#m_2747962184919274479_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >
NH
nop head
Thu, Sep 2, 2021 6:03 PM

You have probably been lucky. For example if you stack integer sized cubes
face to face CGAL can union them but if you stack 0.1mm cubes it will
likely fail because 0.1 cannot be represented exactly in floating point.

On Thu, 2 Sept 2021 at 18:55, Leonard Martin Struttmann <
lenstruttmann@gmail.com> wrote:

"The rule of thumb with multiple objects, either clearly separated or
embed part of one within the other, don't just park them touching side to
side."

MichaelAtOz, this statement confuses me.  I stack objects, face-to-face,
vertically and horizontally all the time with no problems.  Have I just
been lucky up until now? Or, is there a specific context that I'm missing?

On Wed, Sep 1, 2021 at 5:42 PM MichaelAtOz oz.at.michael@gmail.com
wrote:

Yes, as that node was evaluated (and got an error) the node was then
cached, so subsequent F6 don't get evaluated again, so no error.

If you think something is strange, it is always worth doing
Design/Flush-cache.

So, merely separating the polygons with rotate( 10*i ) did NOT solve

the problem, since all of the polygons started at [0,0].

Sharing a point (2D) is also non-manifold, as is sharing a single edge
(3D).

The rule of thumb with multiple objects, either clearly separated or
embed part of one within the other, don't just park them touching side to
side.


From: Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com]
Sent: Thu, 2 Sep 2021 05:45
To: OpenSCAD general discussion
Subject: [OpenSCAD] Re: Module Disappears In Render

Wow!  Yes, just that single error the first time.

Thanks, everyone!

On Wed, Sep 1, 2021 at 11:20 AM Jordan Brown <
openscad@jordan.maileater.net> wrote:

On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote:

My only questions, then, are: Why did outerRing(), by itself, render
successfully and produce an STL that Cura is happy with?  That is, why did
the problem only occur when another module is introduced?

CGAL is what really dislikes objects that aren't perfectly formed, and
doesn't get involved unless there's more than one object.

Also, why are there no warnings or errors?

In 2021.01 I get:

Parsing design (AST generation)...
Saved backup file:
C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad
Compiling design (CSG Tree generation)...
Rendering Polygon Mesh using CGAL...
ERROR: The given mesh is not closed! Unable to convert to
CGAL_Nef_Polyhedron.
Geometries in cache: 19
Geometry cache size in bytes: 1412968
CGAL Polyhedrons in cache: 1
[...]

But I don't get the error when I F6 again.  I assume that either the bad
result has been cached, or the "suppress duplicate error reports" stuff is
getting involved.

I have one suggestion and a pointless rant:

Suggestion:  caching the results of renders that encountered errors is
probably bad.

Pointless rant:  CGL is too darned picky about its polyhedra.

http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient Virus-free.
www.avg.com
http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient
<#m_-1479010006593396921_m_2747962184919274479_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

You have probably been lucky. For example if you stack integer sized cubes face to face CGAL can union them but if you stack 0.1mm cubes it will likely fail because 0.1 cannot be represented exactly in floating point. On Thu, 2 Sept 2021 at 18:55, Leonard Martin Struttmann < lenstruttmann@gmail.com> wrote: > *"The rule of thumb with multiple objects, either clearly separated or > embed part of one within the other, don't just park them touching side to > side."* > > MichaelAtOz, this statement confuses me. I stack objects, face-to-face, > vertically and horizontally all the time with no problems. Have I just > been lucky up until now? Or, is there a specific context that I'm missing? > > > On Wed, Sep 1, 2021 at 5:42 PM MichaelAtOz <oz.at.michael@gmail.com> > wrote: > >> Yes, as that node was evaluated (and got an error) the node was then >> cached, so subsequent F6 don't get evaluated again, so no error. >> >> If you think something is strange, it is always worth doing >> Design/Flush-cache. >> >> >> >> > So, merely separating the polygons with rotate( 10*i ) did NOT solve >> the problem, since all of the polygons started at [0,0]. >> >> >> >> Sharing a point (2D) is also non-manifold, as is sharing a single edge >> (3D). >> >> The rule of thumb with multiple objects, either clearly separated or >> embed part of one within the other, don't just park them touching side to >> side. >> >> >> ------------------------------ >> >> *From:* Leonard Martin Struttmann [mailto:lenstruttmann@gmail.com] >> *Sent:* Thu, 2 Sep 2021 05:45 >> *To:* OpenSCAD general discussion >> *Subject:* [OpenSCAD] Re: Module Disappears In Render >> >> >> >> Wow! Yes, just that single error the first time. >> >> >> >> Thanks, everyone! >> >> >> >> >> >> On Wed, Sep 1, 2021 at 11:20 AM Jordan Brown < >> openscad@jordan.maileater.net> wrote: >> >> On 9/1/2021 8:18 AM, Leonard Martin Struttmann wrote: >> >> My only questions, then, are: Why did outerRing(), by itself, render >> successfully and produce an STL that Cura is happy with? That is, why did >> the problem only occur when another module is introduced? >> >> >> CGAL is what really dislikes objects that aren't perfectly formed, and >> doesn't get involved unless there's more than one object. >> >> >> Also, why are there no warnings or errors? >> >> >> In 2021.01 I get: >> >> Parsing design (AST generation)... >> Saved backup file: >> C:/Users/Jordan/Documents/OpenSCAD/backups/unsaved-backup-QApaZXoi.scad >> Compiling design (CSG Tree generation)... >> Rendering Polygon Mesh using CGAL... >> ERROR: The given mesh is not closed! Unable to convert to >> CGAL_Nef_Polyhedron. >> Geometries in cache: 19 >> Geometry cache size in bytes: 1412968 >> CGAL Polyhedrons in cache: 1 >> [...] >> >> But I don't get the error when I F6 again. I assume that either the bad >> result has been cached, or the "suppress duplicate error reports" stuff is >> getting involved. >> >> I have one suggestion and a pointless rant: >> >> Suggestion: caching the results of renders that encountered errors is >> probably bad. >> >> Pointless rant: CGL is too darned picky about its polyhedra. >> >> >> >> >> >> >> >> <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> Virus-free. >> www.avg.com >> <http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=emailclient> >> <#m_-1479010006593396921_m_2747962184919274479_DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org >> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >