commit 9e5dfd0b080d84b76b51e689af52cc0c513a19e8
parent 230008e60500a5ca03cee2b0a131bb00d7aaf3f3
Author: Christophe Coustet <christophe.coustet@meso-star.com>
Date: Tue, 5 Sep 2023 15:35:32 +0200
Remove dead code and fix comment
Diffstat:
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/scad.c b/src/scad.c
@@ -495,6 +495,7 @@ scad_stl_sort_orientation
ERR(sg3d_geometry_reserve(geom, vcount_in, tcount_in, 0));
ERR(sg3d_geometry_add(geom, vcount_in, tcount_in, &callbacks, coord));
+
ERR(sg3d_geometry_get_unique_vertices_count(geom, &vcount));
ERR(sg3d_geometry_get_unique_triangles_count(geom, &tcount));
if(tcount != tcount_in) {
@@ -504,7 +505,6 @@ scad_stl_sort_orientation
"in set '%s'.\n",
tcount_in - tcount, tcount_in, set_name);
}
- /* If orientation is 'unchanged' convention has no effect on the result */
if(orientation == Scad_force_normals_outward)
convention = SENC3D_CONVENTION_NORMAL_BACK | SENC3D_CONVENTION_NORMAL_OUTSIDE;
else
@@ -517,7 +517,7 @@ scad_stl_sort_orientation
vcount, sg3d_sencXd_geometry_get_position, geom, &senc3d_scn));
ERR(senc3d_scene_get_enclosure_count(senc3d_scn, &ecount));
- if(orientation != Scad_keep_normals_unchanged && ecount < 2) {
+ if(ecount < 2) {
/* Must define a closed volume */
log_error(get_device(),
"Triangle set '%s' doesn't define a closed volume.\n", set_name);