3DCoat  3D-COAT 4.9.xx
3DCoat is the one application that has all the tools you need to take your 3D idea from a block of digital clay all the way to a production ready, fully textured organic or hard surface model.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
TriPatch Class Reference

The class to fill triangle with good quality triangles. More...

#include <TriangularPatch.h>

Public Member Functions

void PreLoadMeshes ()
 try to load .triangle files from the folder ToolsPresets/Triangles/ More...
 
void SaveAll (const char *name)
 save all patches to single binary file More...
 
void LoadAll (const char *name)
 load all patches from the single binary file More...
 
tMiniMeshCalculatePatch (int n1, int n2, int n3)
 create patch from scratch More...
 
tMiniMeshTriangulatePatch (int n1, int n2, int n3)
 triangulate patch. First - seek in hash, if not present - calculate More...
 

Detailed Description

The class to fill triangle with good quality triangles.

Member Function Documentation

tMiniMesh * TriPatch::CalculatePatch ( int  n1,
int  n2,
int  n3 
)

create patch from scratch

never allow bad triangle, should ba A < B + C

normalize first edge

adding contour points

use chunked triangulation

References tMiniMesh::frommc(), comms::cMeshContainer::GetPosition(), comms::cMeshContainer::OptimizeTriangularMesh(), and tMiniMesh::save().

Referenced by TriangulatePatch().

void TriPatch::LoadAll ( const char *  name)

load all patches from the single binary file

References tMiniMesh::load_one(), and tMiniMesh::n1.

void TriPatch::PreLoadMeshes ( )

try to load .triangle files from the folder ToolsPresets/Triangles/

add only if such element does not exist

References tMiniMesh::load(), and tMiniMesh::n1.

void TriPatch::SaveAll ( const char *  name)

save all patches to single binary file

tMiniMesh * TriPatch::TriangulatePatch ( int  n1,
int  n2,
int  n3 
)

triangulate patch. First - seek in hash, if not present - calculate

sorting n1, n2, n3

trying different transforms to fit vertex order

References CalculatePatch(), tMiniMesh::Flip(), tMiniMesh::RotateCCW(), and tMiniMesh::RotateCW().

Referenced by comms::cMeshContainer::PatchedDivision().


The documentation for this class was generated from the following files: