Skip to content

Commit 4f871c7

Browse files
committed
remove the triangulated check
1 parent 76a6909 commit 4f871c7

File tree

1 file changed

+10
-10
lines changed
  • src/main/java/eu/mihosoft/vrl/v3d

1 file changed

+10
-10
lines changed

src/main/java/eu/mihosoft/vrl/v3d/CSG.java

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ public class CSG implements IuserAPI, Serializable {
168168
private ArrayList<Transform> slicePlanes = null;
169169
private ArrayList<String> exportFormats = null;
170170
private ArrayList<Transform> datumReferences = null;
171-
private boolean triangulated;
171+
//private boolean triangulated;
172172
private static boolean needsDegeneratesPruned = false;
173173
private static boolean useStackTraces = true;
174174
private static boolean preventNonManifoldTriangles = false;
@@ -838,13 +838,13 @@ public CSG union(CSG csg) {
838838
* @return a csg consisting of the polygons of this csg and the specified csg
839839
*/
840840
public CSG dumbUnion(CSG csg) {
841-
boolean tri = triangulated && csg.triangulated;
841+
//boolean tri = triangulated && csg.triangulated;
842842
CSG result = this.clone();
843843
CSG other = csg.clone();
844844

845845
result.getPolygons().addAll(other.getPolygons());
846846
bounds = null;
847-
result.triangulated = tri;
847+
//result.triangulated = tri;
848848
return result.historySync(other);
849849
}
850850

@@ -1571,17 +1571,17 @@ public CSG triangulate() {
15711571
}
15721572

15731573
public CSG triangulate(boolean fix) {
1574-
if (fix && needsDegeneratesPruned)
1575-
triangulated = false;
1576-
if (triangulated)
1577-
return this;
1574+
// if (fix && needsDegeneratesPruned)
1575+
// triangulated = false;
1576+
// if (triangulated)
1577+
// return this;
15781578
if (this.polygons.size() > getMinPolygonsForOffloading())
15791579
if (CSGClient.isRunning()) {
15801580
ArrayList<CSG> go = new ArrayList<CSG>(Arrays.asList(this));
15811581
try {
15821582
CSG csg = CSGClient.getClient().triangulate(go).get(0);
15831583
setPolygons(csg.getPolygons());
1584-
triangulated = true;
1584+
// triangulated = true;
15851585
return csg;
15861586
} catch (Exception e) {
15871587
// TODO Auto-generated catch block
@@ -1603,7 +1603,7 @@ public CSG triangulate(boolean fix) {
16031603
}
16041604
performTriangulation();
16051605
// now all polygons are definantly triangles
1606-
triangulated = true;
1606+
//triangulated = true;
16071607
Debug3dProvider.setProvider(start);
16081608
return this;
16091609
}
@@ -2197,7 +2197,7 @@ public CSG setOptType(OptType optType) {
21972197
*/
21982198
public CSG setPolygons(List<Polygon> polygons) {
21992199
bounds = null;
2200-
triangulated = false;
2200+
//triangulated = false;
22012201
this.polygons = polygons;
22022202
return this;
22032203
}

0 commit comments

Comments
 (0)