Clean Geometry

As good as a geometry can look, it is still worth double-checking for any holes in it, correct winding order/normals and remove inter-penetrating polygons.

Holes/Non-Manifold Geometry

As seen in the Tessellation, the Carbon Cloth Guide Geometry offers a variety of helpful visualization tools. Another one is the Open Edges option. This geometry guide shows open edges, which can occur on borders and holes, in yellow color. Additionally, it also highlights non-manifold edges in red. You can set it up as explained in Tessellation.

_images/tutorial_geometry_clean_open_edges.png

Visualizing open edges.

Note

Houdini’s Tetrahedralize node does only accept closed geometry, i.e. no open edges.

Winding Order

It can happen that some of the polygons have incorrect winding order (e.g polygon lists points 7 5 8 instead of 8 5 7). It can often be easily detected because when this happens the geometry normals look wrong. This must fixed for both, Carbon Cloth and Carbon Tetra.

Note

Carbon internally recalculates normals, i.e. there will be no impact on the simulation for wrong normal vectors as long as the winding order of the polygon is correct.

Warning

If the winding order of a geometry passed to Carbon is wrong, it can lead to the simulation blowing up.

Carbon Cloth

_images/tutorial_geometry_clean_winding.png

Surface geometry with wrong winding order.

There are three main Houdini nodes that help clean up geometry: Clean, Facet, and PolyDoctor. All three produce the same result for this example but it is good to remember all of them in case there are other specific problems within a given geometry.

Note

The Houdini Facet node issues a warning that the Houdini PolyDoctor node is a better choice.

_images/tutorial_geometry_clean_winding_repair.png

Repairing the geometry winding order with a Clean, Facet and PolyDoctor node.

Carbon Tetra

Wrong winding order on a tetrahedron means that its volume is inverted (negative volume). This has a strong negative effect on the simulation. Unlike for surface geometry, Houdini’s Clean, Facet, and PolyDoctor nodes do not work on tetrahedral meshes.

_images/tutorial_geometry_clean_winding_tetra.png

Tetrahedron geometry with wrong winding order.

The best option to repair the node is to add a Tetrahedralize node and tick Refine Existing Tetrahedron Mesh. This will solve the problem in most cases.

_images/tutorial_geometry_clean_winding_tetra_repair.png

Repairing the geometry winding order with a Tetrahedralize node.

Inter-Penetration

It is very important that the starting geometry for any Carbon scene is free from inter-penetrations and self-penetrations. If any of these occur, they are permanent at best and cause the simulation to blow up at worst.

Houdini offers tools to help with self-penetrating geometry. Checking for inter-penetration is best done by merging the individual pieces into one geometry and continuing as if they were one.

After the Merge, add a PolyDoctor node.

_images/tutorial_geometry_clean_penetrate.png

Creating and marking penetrating geometry.

Per default, the PolyDoctor node marks self-penetrating geometry. Using a blast node and a simple expression allows to remove either the self-penetrating polygons or the non self-penetrating polygons.

_images/tutorial_geometry_clean_penetrate_blast.png

Removing all but the overlapping geometry with a Blast node.

Unfortunately, there is no easy way to repair the overlapping geometry. Once the problematic polygons are known, one needs to manually edit the point positions until there are no more intersections.

Note

  • The Houdini Tetrahedralize node will only accept surface geometry which is free from self-intersections.
  • The Houdini PolyDoctor node will not work on tetrahedral geometry.