PrettyBool - Boolean modeling and unified mesh export
While testing the Windows user interface for the new Booleans, I created this pretty object:
This was exported from Groboto as unified mesh, then subdivided and rendered in ZBrush. After smooth subdivision you get these realistic-looking rounded edges, unlike the original Groboto model, which is all sharp edges. However, once the unified mesh is created, it's easy to change the edges from sharp to rounded, bevelled, beaded, etc. We expect pretty soon to be able to perform this type of edge modification inside Groboto itself, before exporting the mesh.
To build this model we begin in Groboto with a simple boolean idea, subtracting a sphere from a cube. We drag a cube (box) from the primitive library on the left, scale it to the desired size (Global Scale in the Edit panel), then right-click on it and choose Send Object Home. This is the easiest way to create symmetric objects in Groboto - place primitives in the center of the world, then move them from there as necessary.
Now drag a sphere from the library, make it about the same size as the cube (Global Scale or Radius) and also Send Home. If it's smaller than the cube it will disappear. But it's still selected, so increase its radius until it pokes through the sides of the cube. We also need to move it a bit downwards. Click on Move in the Edit panel and choose Space: Global below. Now click on Y near Move and drag downwards. This moves the sphere only along the vertical axis in the World space. We get something like this (left):
At this point we just have two regular objects, a cube and a sphere. Now we make a Boolean Cluster out of them. Select them both, right-click on either, and choose Boolean Clusters->New Cluster from Selected (choose Yes in the dialog box).
Now that we've associated these two objects with each other, we assign them their boolean roles. We want to subtract the sphere from the cube. Deselect, then right-click on the cube and choose Boolean Roles->Primary. Right-click on the sphere and choose Boolean Roles->Outside Body. Then right-click anywhere and choose Toggle Booleans. We get something like above (right). You can Toggle Booleans on/off any time. When it's 'off' you see all the objects as regular objects, when it's 'on' they play their assigned boolean roles.
Next we want to add another sphere to our cluster, to trim away most of the upper part of the cube. The new sphere will be concentric with the first one, somewhat larger and its boolean role will be Inside Body. This will only leave the parts of the cube which lie between the spheres, in the spherical slice. We can do this in a variety of ways. For instance, Toggle Booleans off, right-click on the sphere and choose Duplicate Object in Place (choose No in the dialog box - we are duplicating into the same cluster), then increase the radius of the new sphere in the Edit panel a little bit (so that the edges of the cube are still outside of it). This new sphere already has the boolean ID of our cluster, but we need to set its boolean role. Right-click on it and choose Boolean Roles->Inside Body. Now if you Toggle Booleans 'on' you'll see this (left):
Next we want to create the round hole in the dome with another subtractive sphere. This time we choose a more fun and interactive way of editing a trim object. Instead of editing it as a regular object and then toggling booleans on, we will edit it dynamically while it's playing its role as a trim. Right-click anywhere on our boolean object and choose Activate Object's Boolean Editing. You'll see this (left):
In the boolean edit mode the trim objects are shown as line cross-sections. We have double blue lines here because we have two spheres. We want to click on the inner sphere with the Select tool (the inner and outer sphere lines are close, so it will be necessary to zoom in using camera controls). The selected sphere lines become red. If there is solid object under the line you have to use Alt when clicking (otherwise solid object will be selected, not line). If there is no solid object underneath, using Alt is not necessary. Now right-click on the red line and choose Duplicate Object in Place (again, No new cluster).
We've created yet another trim sphere, which has the same boolean role as our first inner sphere - Outside Body. Now select Move in the Edit panel (Space: Global), click on Y and drag upward until you see something like above right. Half-way through dragging this sphere will be consuming most of the object. Don't worry - it will come back as you move the sphere higher. You might also play with the radius of the sphere - this will create a different slope on the edge of the hole. Once you're done, right-click anywhere and choose Deactivate Boolean Editing.
Continued in the next post...
Last edited by boris; 11-25-2010 at 02:30 PM.
Next we want to add the ring at the base, from which the columns rise seamlessly.
This can be done by adding another primary object to the cluster. Because of our two trim spheres all that is left from any primary object in this cluster is what's inside the spherical slice between them (the third trim sphere above does not reach the base and has no effect there). Thus to create this kind of a ring any flat round primary object will do, a disk (cylinder) or a flat button ellipsoid. Here on the left we see our cluster (Toggle Booleans is off) as it was before, on the right - with flat button ellipsoid added.
We drag the ellipsoid from the library, make it somewhat larger than the lower sphere (anything outside of that sphere will be trimmed away), Send it Home, then Move it along the Y axis as usual. To achieve continuity between the columns and the base ring this ellipsoid must overlap a little with the cube. So far this ellipsoid is just a regular object, it's not a member of our cluster (will not be trimmed by our spheres if we Toggle Booleans on). To assign to it the boolean ID of our cluster left-click on it with the Select tool to select it, then right-click on any object in our cluster and choose Boolean Clusters->Add Selected to Clicked. Next right-ckick on the ellipsoid and choose Boolean Roles->Primary. Now if you Toggle Booleans 'on', you get the ring at the base.
Now we add the base below the ring. This a disk (cylinder), and it's just a regular object, not a member of our cluster (we don't want it to be trimmed by the spheres). Same here - drag a cylinder from the library, make it short and wide, Send it Home, then Move it along Y so it overlaps the base ring a little.
Continued in the next post...
Last edited by boris; 11-25-2010 at 02:32 PM.
Next we add the middle ring:
Same as the lower ring, add to the cluster another flat button ellipsoid as a Primary object. Here on the left we have the scene (Toggle Booleans off) with this new ellipsoid. On the right it shows only the new ellipsoid.
This ellipsoid is thicker, and only slightly larger than the outer trim sphere, which accounts for the trapezoidal cross-section of the ring it creates. Finally we add the loop that replaces the intersection of the middle ring and the column (left):
We do this by adding two small ellipsoids to the cluster, as seen on the right with Toggle Booleans off. The larger one is primary, the smaller one is trim (Outside Body). Probably the easiest way to position the ellipsoids exactly on the column is this: working with Toggle Booleans off, drag the seed ellipsoid from the library, size it roughly like the larger of these two ellipsoids, then Send it Home. To make it visible right-click anywhere and choose Hide Unselected. Click Rotate in the Edit panel (Space: Global) and choose 45 degree snap. Click Y near Rotate and drag it to the right until the ellipsoid turns once (45 degrees). Now click Move and choose Space: Object below. If you click on Z and drag, the ellipsoid will move straight towards one of the columns. Right-click anywhere and choose Reveal All. You can drag in Z and Y to position the ellipsoid as in the picture above. Don't move in X to avoid losing symmetry. You can adjust all three ellipsoid sizes. Width and Length control the outer dimensions of the loop, while Depth (in the radial direction) is basically irrelevant, since it will be trimmed by the spheres.
Once this ellipsoid is positioned and sized it should be Duplicated in Place and this new ellipsoid should be made smaller in Width and Length, but thicker in Depth, as in the picture above. Now we are ready to bring these ellipsoids into our boolean cluster. Select both ellipsoids, right-click on the cube or any other object already in cluster and choose Boolean Clusters->Add Selected to Clicked. Deselect, right-click on the wider ellipsoid and choose Boolean Roles->Primary. Right-click on the smaller one and choose Boolean Roles->Outside Body. Now you can Toggle Booleans on and see the result.
Of course, the position and size of these new ellipsoids could be set only very roughly before we could see their effect with Toggle Booleans 'on'. Now is the time to do more subtle adjustments. Right-click on the cluster and choose Activate Object's Boolean Editing. There are many primary and trim objects here, so the lines are pretty confusing. It helps to zoom in and move the camera so that the lines representing the trim (smaller) ellipsoid stick out against the clear background, as we see here on the left:
Originally these lines appear blue, they become red after we click on them with the Select tool to select the small trim ellipsoid (use Alt if there is solid object where you click). Now we can edit the Width, Length and Depth of this ellipsoid, move it in Z and Y, and rotate around the X axis, all without losing symmetry. Selecting the primary (larger) ellipsoid is easier - just click on the solid body of the loop (above right). This ellipsoid is also represented by the green lines and could be selected by clicking on them. This might come very handy, since while editing booleans the solid body might disappear completely (try making this ellipsoid smaller).
Continued in the next post...
Last edited by boris; 11-25-2010 at 02:36 PM.
Now we duplicate this pair of ellipsoids for the other three columns. Right-click anywhere and choose Deactivate Boolean Editing. Toggle Booleans 'off' and select the two ellipsoids. You'll notice that clicking on either ellipsoid with the Select tool selects the entire cluster. This is normally what you want - this makes the entire cluster behave like a single object when moving and rotating (otherwise the cluster will fall apart). However in this case we want to select only the ellipsoids. This is done by Alt-clicking on one of the ellipsoids, then Alt-Shift-clicking on the other to add to the selection.
Now right-click on either ellipsoid and choose Duplicate Objects in Place (confirm that you want to duplicate both ellipsoids). In the second dialog box choose No - we are duplicating within the same cluster, not creating a new one. Make sure that Lock Selection in the Edit panel is enabled. Click Rotate, choose Space: Global and 45 degree Snap, and click Y. Now click on any object of revolution in the scene - the large flat ellipsoid at the base is the most convenient - and drag to the right until our small ellipsoids snap twice (90 degrees). Our selected objects are orbiting around the Y axis of the object we clicked on. Repeat this two more times, moving the camera as necessary - right-click on either ellipsoid and duplicate, drag on the base ellipsoid to orbit.
Both Boolean Cluster IDs and Roles (Primary or Trim) are copied when duplicating ellipsoids, so everything is already set correctly. Toggle Booleans 'on' to see the final result:
What we have inside Groboto is a perfect non-polygonal quadric boolean model. It's clean and free of any defects - but we cannot smooth its edges, deform its surfaces or do any number of other interesting things. For that it has to be turned into unified mesh. Choose Export in the File menu to open the Export panel. The main issue with polygonal export is density, the size of the quads in the exported mesh. Density needs to be carefully chosen. If it's too low, the mesh will be crude, not representing the clean Groboto model well. However, Groboto meshes are usually well-structured, so there is no need to set the density very high, producing meshes with millions of quads.
For thick blobby models even low density can produce nice results. Models like this one are more challenging, because booleans can produce thin delicate lacework. Choose Density Type Fixed - Circumference from the drop-down on the left, set the Density to 40 with the top slider and click Preview on the right. We get something like this (left):
40 means we get 40 quads around the circumference on each object. This is a pretty crude mesh. Now move the top slider to 120 and click Refresh on the right (above right). This density is pretty nice, but if we look closely, there is a problem (left):
On the inside of the loops the density now is very high (same on the outside). Such significant differences in mesh density are always undesirable, especially if you plan to work on this mesh in a sculpting program. Here it happens because this surface comes from the small trim ellipsoid responsible for the hole in the loop, and Fixed Circumference density type means that all objects, large and small, get the same 120 subdivisions around the circumference. The other two density types are helpful in this respect - they increase the number of divisions with object size, thus reducing quad size discrepancy.
Another way to address this problem is to set mesh density manually for specific objects. Here it's easy enough - we have 8 small ellipsoids in the scene which can use the same density setting, while all the other objects are large - for them the global setting 120 will remain in effect. Click on Preview in the Export panel to get out of mesh preview and Toggle Booleans 'off'. Alt-click on one of the small ellipsoids with the Select tool, then Alt-Shift-click on all the others to add them to the selection (orbit the camera as necessary). Now click on the Selected Object Properties tab (leftmost) in the Groboto Main panel:
It should show the number of selected objects as 8. In the UniMesh Export Overrides section check the Density checkbox and set the density to 24 with the top slider. Toggle Booleans 'on' and click Preview in the Export panel. Now the density is much lower on the inside loop surface (above right). You can also see the density difference on the outside loop surface of another loop, visible in the upper left corner of the picture.
Continued in the next post...
Last edited by boris; 11-02-2010 at 09:51 AM.
For now we want to direct most of our efforts at modeling - for rendering there are other options, while in modeling Groboto's approach is unique. But I agree - it would be nice to have Groboto-style clean rendering with reflections, glass, etc. Some day!
Importing into ZBrush was straightforward (I have ZBrush 3.5R3). You click on the PolySphere icon at top right and choose PolyMesh3D (the star) in the menu. Then click the Import button at top right and load the OBJ file exported from Groboto. That's it!
Last edited by boris; 10-25-2010 at 10:21 AM.
3D modeler / worldbuilder
Oh man, this is fantastic! When will the new beta including these booleans released for Windows? Can't wait!
Last edited by boris; 10-25-2010 at 09:05 PM.
3D modeler / worldbuilder
Good! Going to get it now!
Tags for this Thread