Krabl Mesh Library
A C# library to process meshes in Unity3D
|
Static methods to deal with marking edges as creases.
|
static |
Searches the mesh for edges that are connected to faces of different materials (submeshes). These are marked as creases.
mesh | The mesh to search. |
creaseStrength | The crease value to set the edges to. Currently only 1.0f has any effect. |
|
static |
Searches through all edges of the mesh and compares the vertex normals on each face connected to an edge. If there is a difference in the vertex normals, the edge gets marked as crease. This method is automatically executed every time a Unity mesh is converted to a Krabl Mesh Library mesh.
mesh | The mesh to search. |
creaseStrength | The crease value to set the edges to. Currently only 1.0f has any effect. |
|
static |
Searches through all edges of the mesh and calculates the angle between the faces connected to the edge. The the angle is above the threshold, the edge is marked as a crease.
mesh | The mesh to search. |
angleThreshold | All edges with angles equal or larger than this are marked as creases. |
creaseStrength | The crease value to set the edges to. Currently only 1.0f has any effect. |
|
static |
Sets the crease value of all edges in the mesh to 0.
mesh | The mesh to process. |