discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

Re: YAPDOR (yet another part disappears on render) question

RW
Ray West
Wed, Nov 10, 2021 1:15 AM

Hi, the polygon has an error. select 'thrown together', it will show it
in mauve. You may be able to work out where, and change the numbers. It
looks like the line from the lowest -x and -y point.

On 09/11/2021 23:26, Gryffyn via Discuss wrote:


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

Hi, the polygon has an error. select 'thrown together', it will show it in mauve. You may be able to work out where, and change the numbers. It looks like the line from the lowest -x and -y point. On 09/11/2021 23:26, Gryffyn via Discuss wrote: > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org
G
Gryffyn
Wed, Nov 10, 2021 2:11 AM

First, thanks for the prompt and thoughtful replies.  I really appreciate it as I learn the ins and outs of OpenSCAD.
To address what's been mentioned already:

  1. Thanks for pointing out the caching. I saw mention of it, but assumed rendering would re-render it and not pull from cache.  For all the tests I just did, I flushed cache before each.  I see the error now, when only one of the two objects renders, but not when I render either of them by themselves. 2. Points having really similar values - Individually, the shapes seem to render properly, though.  And one is a polygon that's been extruded.  One is a polygon with a cutout polygon (where the first polygon pokes through so I was wondering if the vertices were too close and causing issues? but removing the cutout had the same issue).   Pasted below is two parallel "tree branches", not touching.  I also increased the scale so they're bigger/vertices further apart.  And it still does the same thing.  One renders fine by itself, but both together fail to render both.   I founded the values so they're not quite as gnarly.3. "Thrown together" shows me nothing.  I render, either one object or both, then select Thrown Together view and the object disappears.  It's just weird that each renders fine, but together there's some conflict, even when the objects don't intersect.
    That third object (1 = stick, 2 = large tree branches, 3 = small tree branches) is causing the issue.  
    Thanks again, everyone.  Again, I'm sure it's something stupid.    Just so you know my main goal, I was trying to scale the original data up so it displayed in OpenSCAD without having to zoom in/out.  Make it as simple to use for non OpenSCAD users.  BUT...  if scaling things up or putting the values within certain bounds might fix things, that's fine too. 
    // 1, 2, 3 - 1, 2 render (1 error)// 2, 3 - 2 renders (1 error)// 1, 3 - 1 renders (1 error)// 1, 2 or 3 - each renders fineone();two();three();
    module one() {    translate([0, 0, 0])    linear_extrude(height=48)    polygon(points= [[0, 0],[-2.25, -2.25],[0, -4.5],[2.25, -2.25],[0, 0]]);}
    module two() {    obj_points0 =[[-85.5, -6.75],[-40.5, -15.75],[-40.5, -18],[-56.25, -22.5],[-47.25, -22.5],[-81, -45],[-15.75, -33.75],[-60.75, -78.75],[-27, -56.25],[-67.5, -105.75],[-6.75, -60.75],[-6.75, -72],[-2.25, -58.5],[9, -49.5],[22.5, -94.5],[27, -67.5],[47.25, -94.5],[29.25, -56.25],[38.25, -65.25],[31.5, -45],[60.75, -45],[81, -54],[65.25, -45],[110.25, -45],[90, -40.5],[69.75, -31.5],[74.25, -31.5],[67.5, -31.5],[42.75, -20.25],[58.5, -6.75],[103.5, 0],[69.75, 0],[96.75, 22.5],[51.75, 4.5],[72, 22.5],[38.25, 2.25],[33.75, 2.25],[40.5, 31.5],[42.75, 38.25],[54, 58.5],[42.75, 45],[49.5, 72],[9, 20.25],[-2.25, 81],[-2.25, 60.75],[-9, 78.75],[-4.5, 36],[-4.5, 33.75],[-13.5, 45],[-6.75, 20.25],[-6.75, 13.5],[-67.5, 63],[-31.5, 15.75],[-31.5, 15.75],[-67.5, 38.25],[-54, 24.75],[-56.25, 27],[-51.75, 22.5],[-42.75, 15.75],[-54, 18],[-27, 2.25],[-22.5, -4.5],[-29.25, -9],[-85.5, -6.75],[-2.25, -2.25],[0, 0],[2.25, -2.25],[0, -4.5],[-2.25, -2.25]];        obj_paths0 =[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63],[64,65,66,67,68]];        translate([0, 0, 3])    linear_extrude(height=0.6)    polygon(obj_points0, obj_paths0);}
    module three() {    obj_points1 =[[-15.75, -13.5],[-2.25, -9],[-4.5, -11.25],[-2.25, -9],[0, -9],[0, -15.75],[2.25, -11.25],[2.25, -15.75],[2.25, -9],[2.25, -11.25],[2.25, -9],[9, -9],[11.25, -11.25],[9, -9],[15.75, -11.25],[13.5, -11.25],[9, -9],[11.25, -9],[9, -6.75],[6.75, -4.5],[9, -4.5],[15.75, -4.5],[11.25, -2.25],[15.75, 0],[9, -2.25],[13.5, 0],[6.75, -2.25],[6.75, -2.25],[9, 2.25],[9, 4.5],[11.25, 6.75],[9, 4.5],[11.25, 9],[2.25, 2.25],[4.5, 11.25],[2.25, 9],[2.25, 11.25],[2.25, 4.5],[2.25, 4.5],[0, 6.75],[0, 2.25],[0, 2.25],[-6.75, 11.25],[-2.25, 4.5],[-4.5, 4.5],[-6.75, 9],[-6.75, 6.75],[-6.75, 6.75],[-6.75, 4.5],[-4.5, 4.5],[-6.75, 4.5],[-4.5, 2.25],[-2.25, 0],[-4.5, 0],[-13.5, 2.25],[-6.75, 0],[-6.75, 0],[-9, 0],[-6.75, -2.25],[-13.5, -4.5],[-4.5, -4.5],[-13.5, -9],[-6.75, -6.75],[-15.75, -13.5],[-2.25, -2.25],[0, 0],[2.25, -2.25],[0, -4.5],[-2.25, -2.25]];        obj_paths1 =[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63],[64,65,66,67,68]];        translate([0, 0, 6])    linear_extrude(height=0.6)    polygon(obj_points1, obj_paths1);}
    On Tuesday, November 9, 2021, 08:15:58 PM EST, Ray West raywest@raywest.com wrote:

Hi, the polygon has an error. select 'thrown together', it will show it
in mauve. You may be able to work out where, and change the numbers. It
looks like the line from the lowest -x and -y point.

On 09/11/2021 23:26, Gryffyn via Discuss wrote:


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

First, thanks for the prompt and thoughtful replies.  I really appreciate it as I learn the ins and outs of OpenSCAD. To address what's been mentioned already: 1. Thanks for pointing out the caching. I saw mention of it, but assumed rendering would re-render it and not pull from cache.  For all the tests I just did, I flushed cache before each.  I see the error now, when only one of the two objects renders, but not when I render either of them by themselves. 2. Points having really similar values - Individually, the shapes seem to render properly, though.  And one is a polygon that's been extruded.  One is a polygon with a cutout polygon (where the first polygon pokes through so I was wondering if the vertices were too close and causing issues? but removing the cutout had the same issue).   Pasted below is two parallel "tree branches", not touching.  I also increased the scale so they're bigger/vertices further apart.  And it still does the same thing.  One renders fine by itself, but both together fail to render both.   I founded the values so they're not quite as gnarly.3. "Thrown together" shows me nothing.  I render, either one object or both, then select Thrown Together view and the object disappears.  It's just weird that each renders fine, but together there's some conflict, even when the objects don't intersect. That third object (1 = stick, 2 = large tree branches, 3 = small tree branches) is causing the issue.   Thanks again, everyone.  Again, I'm sure it's something stupid.    Just so you know my main goal, I was trying to scale the original data up so it displayed in OpenSCAD without having to zoom in/out.  Make it as simple to use for non OpenSCAD users.  BUT...  if scaling things up or putting the values within certain bounds might fix things, that's fine too.  // 1, 2, 3 - 1, 2 render (1 error)// 2, 3 - 2 renders (1 error)// 1, 3 - 1 renders (1 error)// 1, 2 or 3 - each renders fineone();two();three(); module one() {    translate([0, 0, 0])    linear_extrude(height=48)    polygon(points= [[0, 0],[-2.25, -2.25],[0, -4.5],[2.25, -2.25],[0, 0]]);} module two() {    obj_points0 =[[-85.5, -6.75],[-40.5, -15.75],[-40.5, -18],[-56.25, -22.5],[-47.25, -22.5],[-81, -45],[-15.75, -33.75],[-60.75, -78.75],[-27, -56.25],[-67.5, -105.75],[-6.75, -60.75],[-6.75, -72],[-2.25, -58.5],[9, -49.5],[22.5, -94.5],[27, -67.5],[47.25, -94.5],[29.25, -56.25],[38.25, -65.25],[31.5, -45],[60.75, -45],[81, -54],[65.25, -45],[110.25, -45],[90, -40.5],[69.75, -31.5],[74.25, -31.5],[67.5, -31.5],[42.75, -20.25],[58.5, -6.75],[103.5, 0],[69.75, 0],[96.75, 22.5],[51.75, 4.5],[72, 22.5],[38.25, 2.25],[33.75, 2.25],[40.5, 31.5],[42.75, 38.25],[54, 58.5],[42.75, 45],[49.5, 72],[9, 20.25],[-2.25, 81],[-2.25, 60.75],[-9, 78.75],[-4.5, 36],[-4.5, 33.75],[-13.5, 45],[-6.75, 20.25],[-6.75, 13.5],[-67.5, 63],[-31.5, 15.75],[-31.5, 15.75],[-67.5, 38.25],[-54, 24.75],[-56.25, 27],[-51.75, 22.5],[-42.75, 15.75],[-54, 18],[-27, 2.25],[-22.5, -4.5],[-29.25, -9],[-85.5, -6.75],[-2.25, -2.25],[0, 0],[2.25, -2.25],[0, -4.5],[-2.25, -2.25]];        obj_paths0 =[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63],[64,65,66,67,68]];        translate([0, 0, 3])    linear_extrude(height=0.6)    polygon(obj_points0, obj_paths0);} module three() {    obj_points1 =[[-15.75, -13.5],[-2.25, -9],[-4.5, -11.25],[-2.25, -9],[0, -9],[0, -15.75],[2.25, -11.25],[2.25, -15.75],[2.25, -9],[2.25, -11.25],[2.25, -9],[9, -9],[11.25, -11.25],[9, -9],[15.75, -11.25],[13.5, -11.25],[9, -9],[11.25, -9],[9, -6.75],[6.75, -4.5],[9, -4.5],[15.75, -4.5],[11.25, -2.25],[15.75, 0],[9, -2.25],[13.5, 0],[6.75, -2.25],[6.75, -2.25],[9, 2.25],[9, 4.5],[11.25, 6.75],[9, 4.5],[11.25, 9],[2.25, 2.25],[4.5, 11.25],[2.25, 9],[2.25, 11.25],[2.25, 4.5],[2.25, 4.5],[0, 6.75],[0, 2.25],[0, 2.25],[-6.75, 11.25],[-2.25, 4.5],[-4.5, 4.5],[-6.75, 9],[-6.75, 6.75],[-6.75, 6.75],[-6.75, 4.5],[-4.5, 4.5],[-6.75, 4.5],[-4.5, 2.25],[-2.25, 0],[-4.5, 0],[-13.5, 2.25],[-6.75, 0],[-6.75, 0],[-9, 0],[-6.75, -2.25],[-13.5, -4.5],[-4.5, -4.5],[-13.5, -9],[-6.75, -6.75],[-15.75, -13.5],[-2.25, -2.25],[0, 0],[2.25, -2.25],[0, -4.5],[-2.25, -2.25]];        obj_paths1 =[[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63],[64,65,66,67,68]];        translate([0, 0, 6])    linear_extrude(height=0.6)    polygon(obj_points1, obj_paths1);} On Tuesday, November 9, 2021, 08:15:58 PM EST, Ray West <raywest@raywest.com> wrote: Hi, the polygon has an error. select 'thrown together', it will show it in mauve. You may be able to work out where, and change the numbers. It looks like the line from the lowest -x and -y point. On 09/11/2021 23:26, Gryffyn via Discuss wrote: > _______________________________________________ > 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