View previous topic :: View next topic |
Author |
Message |
Tristan DeleD PRO user
Joined: 16 Dec 2006 Posts: 56
|
Posted: Sat Dec 30, 2006 9:59 pm Post subject: Union problem |
|
|
Well I ge this problem way too often. Where there are surfaces that aren't covered leaving a blank spot. Which is quite annoying, any plans to fix this? It's not like this has any complexity what so ever.
Un-Unioned
As you can see all faces are inside of others.. ect. It's not the first problem I have with the union tool.
http://www.gamingtwilight.com/downloads/testo.dmf |
|
Back to top |
|
|
Paul-Jan Site Admin
Joined: 08 Aug 2004 Posts: 3066 Location: Lage Zwaluwe
|
Posted: Sun Dec 31, 2006 10:13 am Post subject: |
|
|
Thanks for the detailed report and the example file! Jeroen maintains the CSG routines, I'm sure he'll be put it to good use.
As fas as I know, there currently are known problems with coplanar polygons. Looks like that (known, but needs-to-be-fixed) issue covers most of the problems with this scene. |
|
Back to top |
|
|
Tristan DeleD PRO user
Joined: 16 Dec 2006 Posts: 56
|
Posted: Sun Dec 31, 2006 5:03 pm Post subject: |
|
|
Yeah, it NEEDS to be fixed soon, I mean I get this problem wayyy tooo often. Every time anything goes diagonal there's a 99% chance it'll do that. And even non-diagonals do that sometimes... If it stops a user from making models then it should be considered top priority. |
|
Back to top |
|
|
Jeroen Site Admin
Joined: 07 Aug 2004 Posts: 5332 Location: The Netherlands
|
Posted: Sun Dec 31, 2006 6:37 pm Post subject: |
|
|
Sure thing! Thanks for providing an example scene, I'll get into this a.s.a.p.
First testresults: it looks like the problem is twofold. Having auto-optimize turned off, the Union command somehow fails to create 4 needed polygons. Runnning the Optimize routine mannually after that removes too many polygons because of those 4 missing polygons. If I manually repair the 4 missing polygons first (by using Vertex Fill) and then run the Optimize function again, I get a good result. I'll get into why the Union doesn't produce those particular 4 polygons now. |
|
Back to top |
|
|
Jeroen Site Admin
Joined: 07 Aug 2004 Posts: 5332 Location: The Netherlands
|
Posted: Mon Jan 01, 2007 1:44 pm Post subject: |
|
|
I think I figured out what the problem is. Take a look at the following picture:
I have selected two primitives of the scene and seperated them from the other primitives in the right picture. The two primitives both have a rectangular polygon at the back and a triangular polygon on the front. This is causing the highlighted polygons (which connect the back- and front polygons) to get skewed. Same goes for the polygons on the other side (I didn't highlight those). To be more exact: those polygons are not flat. A polygon is flat when all vertices of the polygon are in the same plane. For example, if you create a polyline consisting out of 4 or more vertices, the polygon is flat. If you move one of the vertices upwards, the polygon isn't flat anymore. This is the case with the highlighted polygons in the picture.
The thing is: CSG routines depend heavily on plane-calculations. Therefor, they need all polygons in the primitive to be flat. If you alter the primitives being show here so that the highlighted polygons truly are flat, Union will work correctly. Optimize will also do its job just fine then too. You could simply create two cubes and scale the bottom polygons inwards a bit. Alternately, simply weld the bottom vertices to achieve a triangular effect or use a pyramid primitive to get to the same result.
The "problem" here is this: we choose to create a modeler that gives the user total freedom about the kind of geometry he/she wishes to create (open/closed, flat/non-flat etcetera). But, non-flat polygons cause the CSG routines to fail so I think we should make our CSG routines more robust by checking for non-flat polygons and other types of geometry that might cause a CSG failure before actually applying the CSG commands. If faulty geometry is detected, CSG should not be applied and, preferably, the offending polygons should be highlighted.
Thanks for pointing out this problem - we will handle this in the next release of DeleD. In the mean time, you can handle possible problems yourself by carefully creating your geometry on which to apply CSG routines on. We'll mention this in the Help file too. |
|
Back to top |
|
|
Tristan DeleD PRO user
Joined: 16 Dec 2006 Posts: 56
|
Posted: Mon Jan 01, 2007 5:26 pm Post subject: |
|
|
Not only should it highlight it, there should be if there isnt, a tool to fix the problem just by pressing it that would be sweet, so making abnormal polygones wouldn't be a problem and it would ease our burden. |
|
Back to top |
|
|
csp Member
Joined: 06 Jan 2007 Posts: 4 Location: Zürich, Switzerland
|
Posted: Sat Jan 06, 2007 2:26 am Post subject: |
|
|
I'm currently trying Deled lite 1.53 and I had some missing little triangles after a union. Union is the only thing I can test in the lite version. So you say its not a problem of all CSG ops ?
Maybe you should add a "Cap Holes" tool as in 3dsmax.
BTW I was making a union with a sphere and a torus that was intersecting the sphere somewhere in the upper part. |
|
Back to top |
|
|
jwatte DeleD PRO user
Joined: 26 Apr 2006 Posts: 513
|
Posted: Sat Jan 06, 2007 4:08 am Post subject: |
|
|
A reasonable work-around would be to detect non-flat polygons, and tesselating them before doing the union. Of course, there are two ways to tesselate a quad, and you have to pick one -- but that's better than trying to union a non-flat polygon. |
|
Back to top |
|
|
Jeroen Site Admin
Joined: 07 Aug 2004 Posts: 5332 Location: The Netherlands
|
Posted: Sat Jan 06, 2007 12:57 pm Post subject: |
|
|
jwatte wrote: |
A reasonable work-around would be to detect non-flat polygons, and tesselating them before doing the union. Of course, there are two ways to tesselate a quad, and you have to pick one -- but that's better than trying to union a non-flat polygon. |
A problem here might be that the polygon to be tesselated is connected to other polygons. Tesselating that polygon might result in the other polygon(s) becoming non-flat or, at least, deformed in such a way the artist didn't intend. Any thoughts on this one?
@csp: what does the Cap Holes tool in 3dsmax do? |
|
Back to top |
|
|
csp Member
Joined: 06 Jan 2007 Posts: 4 Location: Zürich, Switzerland
|
Posted: Sat Jan 06, 2007 5:19 pm Post subject: |
|
|
cap holes will close little gaps and holes like missing triangles in a mesh. It may use some parameters to detect things that may be "holes".
Flat polygons? Isn't a triangle flat anyway? Does Deled use other polygons than Triangles? well if so, then a triangulation maybe would help. |
|
Back to top |
|
|
jwatte DeleD PRO user
Joined: 26 Apr 2006 Posts: 513
|
Posted: Sun Jan 07, 2007 9:12 pm Post subject: |
|
|
Jeroen wrote: |
A problem here might be that the polygon to be tesselated is connected to other polygons. Tesselating that polygon might result in the other polygon(s) becoming non-flat |
Sorry, I meant "triangulating" the polygon. You do not need to add any vertices. |
|
Back to top |
|
|
|