[World] First Boolean Solid

Daniel Phillips phillips at phunq.net
Sat Jun 23 01:32:19 PDT 2012


Here is my first successful boolean solid construction ever. Not really all 
that complex is it? While not particularly challenging, this would still be 
tedious - boring even - to construct one polygonal face at a time. Using 
boolean solid modeling it is easy.

The second image shows that this is not merely two interpenetrating objects 
rendered together with z-buffering, which could indeed produce the same image. 
So why is solid modeling better than z-buffering? Well, though I did not show 
it here, you can create holes in things with boolean modeling but not with z-
buffering. There are many other advantages. You could do architectural modeling 
in the interior space, which otherwise would be obstructed by simple z-buffer 
rendering. We can also do physical things like calculate interior volume, and 
maybe add physical properties to the walls. That is for later. In the 
immediate future the biggest use will be making holes in things and finding 
complex intersection arcs, which are already well worth the effort.

In addition to having some success putting all the little solid modeling 
pieces together, I also hit my first degenerate vertex alignment bug. Which was 
predicted, and it was predicted that it would be exactly this bug, but I did 
not really expect to hit it so soon. Well, it turns out that the simple math 
one typically uses for simple examples greatly increases the probability of 
exact geometric alignment, and that is just what happened here. In this case I 
worked around it by making a tiny change in the alignment to remove the 
geometric ambiguity. But that will not do in the long run. It seems I need to 
jump straight into the robustness work, whereas I had been hoping to move onto 
something a little more interesting like actual game graphics around now. Oh 
well. Having a robust solid modeling algorithm will be way better than having 
a flaky one. Even some high end commercial products like 3D Max are not really 
any more reliable than I have right now. But this is Open Source! Less than 
perfectly reliable is just not good enough.

One new component is working very nicely: the polygon triangulator. It was 
used here to triangulate the non-convex faces where the tetrahedra 
interpenetrate. It does this job automatically. For such a complex algorithm, 
it is very easy to use. As it should be.

I will try some slightly more complex models just to get an idea how frequent 
the degenerate alignment bugs are, then I will just straight into the theory 
and practice of making this algorithm work all the time, not just most of the 
time.

Regards,

Daniel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://phunq.net/pipermail/world/attachments/20120623/af439e0a/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: solid21.jpg
Type: image/jpeg
Size: 47660 bytes
Desc: not available
URL: <http://phunq.net/pipermail/world/attachments/20120623/af439e0a/attachment-0002.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: solid22.jpg
Type: image/jpeg
Size: 61771 bytes
Desc: not available
URL: <http://phunq.net/pipermail/world/attachments/20120623/af439e0a/attachment-0003.jpg>


More information about the World mailing list