Sorry nophead,
I meant that I can see that F5 tessellates a polygon with holes for use with
linear_extrude and we could use the underlying functionality to provide a
function that tesselates a 2D polygon given as list.
Btw, I see a F5 tesselation but not a F6 tesselation for
sphere(10);
Maybe OpenSCAD just doesn't display it?
--
Sent from: http://forum.openscad.org/
Parkinbot wrote
Btw, I see a F5 tesselation but not a F6 tesselation for
sphere(10);
Maybe OpenSCAD just doesn't display it?
It looks like it is only displayed when a boolean operation is involved
translate([20, 0, 0])
cube(5);
sphere(10);
--
Sent from: http://forum.openscad.org/
If you just have sphere(10) without any CSG ops CGAL is not involved.
OpenScad has its own 3D representation and when that is displayed show
edges does not work.
If you add a unit cube then CGAL generates the union and the final result
is then a CGAL object and show edges works.
[image: image.png]
It is mostly tesselated with triangles but there are some quads and
polgonal poles. Wierd, but that is probably just how it is constructed, not
by using a tessalator.
When you do F5 the tessalation is totally different. I think OpenCSG
tesselates everything to triangles when it displayes.
On Sun, 16 Dec 2018 at 23:40, Parkinbot rudolf@digitaldocument.de wrote:
Sorry nophead,
I meant that I can see that F5 tessellates a polygon with holes for use
with
linear_extrude and we could use the underlying functionality to provide a
function that tesselates a 2D polygon given as list.
Btw, I see a F5 tesselation but not a F6 tesselation for
sphere(10);
Maybe OpenSCAD just doesn't display it?
--
Sent from: http://forum.openscad.org/
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Ronaldo had noticed it some time ago that CGAL changes tesselation on its own
will.
I created a cube by means of sweep(). So I am sure that it is tesselated in
triags. See how it is displayed by F6 with a unit cube unioned.
http://forum.openscad.org/file/t887/sweep.png
--
Sent from: http://forum.openscad.org/
Looks like CGAL de-tesselates triangles in the same plane to make pologons.
That makes it hard to know what the internal representation of anything is.
It used to always be CGAL nef_polyhreda I think but now it switches back
and forth to polysets. When the result is a polyset you don't get all the
vertex / edge info and show edges does not work. Also I think it switches
from rationals to doubles for the vertices.
On Mon, 17 Dec 2018 at 00:19, Parkinbot rudolf@digitaldocument.de wrote:
Ronaldo had noticed it some time ago that CGAL changes tesselation on its
own
will.
I created a cube by means of sweep(). So I am sure that it is tesselated in
triags. See how it is displayed by F6 with a unit cube unioned.
http://forum.openscad.org/file/t887/sweep.png
--
Sent from: http://forum.openscad.org/
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
Clearly, CGAL is only called when a Boolean operation is present. Thus the
polyset to nef_polyhreda conversion is not necessary for primitives like a
polyhedron and can't be displayed.
When CGAL is called, it seems to try to reduce faces.
Nevertheless there is a tesselation of polygon with holes for F5 and this
one could be exposed to the user.
--
Sent from: http://forum.openscad.org/
Yes but I don't think tessalation is the issue with polyhedron. The problem
seems to be the interface to polyhedron has no way to express holes.
It could detect faces that are coplanar with an encolsing face pass them
through clipper to sort out the holes. Or it could allow the keyhole
contruction, detect the loops and remove the extra edges between loops. So
each face becomes a list of loops with counter clockwise ones being holes.
Tessalation should only be needed when the faces are not planar.
On Mon, 17 Dec 2018 at 00:54, Parkinbot rudolf@digitaldocument.de wrote:
Clearly, CGAL is only called when a Boolean operation is present. Thus the
polyset to nef_polyhreda conversion is not necessary for primitives like a
polyhedron and can't be displayed.
When CGAL is called, it seems to try to reduce faces.
Nevertheless there is a tesselation of polygon with holes for F5 and this
one could be exposed to the user.
--
Sent from: http://forum.openscad.org/
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
If there is a tesselation, a sweep with more than one hole can be
implemented. Wasn't this at least part the aim?
--
Sent from: http://forum.openscad.org/
I don't understand why you think it needs tesselation to represent a
polygonal face with holes in it. OpenSCAD can handle such faces no problem
and tesselates them when triangles are required, such as for STL export.
The issue is that polyhedron can't create faces with holes. It nearly can
with the keyhole method but they are not acceptable to CGAL in that format
as they are not manifold. Simply removing the connections between loops and
ensuring the correct winding order should fix that.
On Mon, 17 Dec 2018 at 10:13, Parkinbot rudolf@digitaldocument.de wrote:
If there is a tesselation, a sweep with more than one hole can be
implemented. Wasn't this at least part the aim?
--
Sent from: http://forum.openscad.org/
OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org
nophead wrote
I don't understand why you think it needs tesselation to represent a
polygonal face with holes in it. OpenSCAD can handle such faces no problem
and tesselates them when triangles are required, such as for STL export.
The issue is that polyhedron can't create faces with holes.
The target of a sweep is a polyhedron. For this it interprets a vector of
polygons. The first polygon in this vector defines the starting face, and
the last the end face. Any two consecutive polygons define a piece of wall.
If I have a function that I can use to tesselate the first and last faces, I
can implement a sweep for any tube-like structures with holes, because it is
easy for me to find holes in polygons, but very expensive to implement an
earcut with holes for 2D-polygons.
Alternatively polyhedron could allow me to use (planar) faces with holes. In
this case, polyhedron could use internally the same function that a
linear_extrude obviously uses, when it extrudes a polygon with holes. BUT: I
don't see this coming soon, because it requires a tesselation of almost
planar faces in 3D. To use the suspected given 2D tesselation, the
implementation could employ some coordinate transformation like I just
presented in the other thread
http://forum.openscad.org/Rotation-question-tp24970p24992.html , then
project the almost planar face down to xy, and finally find the tesselation
by calling this ominous function. The problem of the "almost planar" will
stay. How will you define it? How much deviation will be allowed. How will
an "alternative construction" work?
However, even if polyhedron will accept polygons with holes some day, it
would be a nice-to-have, to get an explicite tesselation of a polygon with
holes from a built-in OpenSCAD function, just like cross() and norm()
operate over a list of numbers.
--
Sent from: http://forum.openscad.org/