-
-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Faces with holes #21
Comments
Update on this topic: FOLD 1.2 supports |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@amandaghassaei points out that the current spec does not deal with holes in faces (without subdividing them somehow), e.g.
We should extend the spec to handle this. The tricky part is doing so in a backwards-compatible way.
Proposal 1:
faces_boundaries
: for each face, list of boundaries, first of which is outside and rest are interior holesboundaries_vertices
/edges
: counterclockwise (?) order of vertices/edges for the boundary, similar to currentfaces_vertices
/edges
faces_vertices
/edges
: can still list all vertices/edges on boundary of face (union of face's boundaries), but order is no longer particularly useful.boundaries
listed, assume each face is a single boundary and already in ccw order. So this makes everything backward-compatible: when not using holes, can use FOLD as is, but when dealing with holes, work withboundaries
structures instead offaces_vertices
/edges
.frame_attributes
ofholey
(?) andnonHoley
(?) to specify whether boundaries are in useThe downside of this approach is unneeded complexity: boundaries don't really need to be first-class, because will generally be used by exactly one face.
Proposal 2:
faces_vertices
becomes an array of array of vertex indices, one array per boundary, where first boundary is exterior and ccw, and other boundaries are holes and cwfaces_edges
(optional) similarly becomes an array of array of edge indicesKey question for this approach: do we want v2 to allow both forms (each element of
faces_vertices
is an array of indices, or an array of array of indices), or just the hole-supporting form (each element offaces_vertices
is an array of array of indices)?The text was updated successfully, but these errors were encountered: