HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GU_EdgeUtils.h File Reference
#include "GU_API.h"
#include <GA/GA_Edge.h>
#include <GA/GA_ElementWrangler.h>
#include <UT/UT_Vector3.h>
#include <UT/UT_Vector4.h>
#include <stddef.h>
+ Include dependency graph for GU_EdgeUtils.h:

Go to the source code of this file.

Classes

class  GU_EdgeDiv
 
class  GU_LoopFinder
 
class  GU_PolySplitHelper
 

Macros

#define __GU_EdgeUtils_h__
 

Functions

GU_API UT_Vector3 GUcomputeInsetPos (const GEO_Face &face, int vtx, float inset)
 
GU_API bool GUisPointInline (const UT_Vector3 &start, const UT_Vector3 &mid, const UT_Vector3 &end, float tol)
 
GU_API bool GUgetEdgePoints (const GEO_Face &face, int edgenum, GA_Offset &p0, GA_Offset &p1)
 
GU_API void GUfindUnsharedEdges (const GEO_Detail &detail, GA_EdgeGroup &edges, const GA_PrimitiveGroup *primgroup=NULL, bool prims_on_edges=false)
 
GU_API void GUedgeLoopSplit (GU_Detail &gdp, GA_Offset pt0, GA_Offset pt1, fpreal u, exint splits=0, bool parallel=false, GA_EdgeGroup *edgeGroup=NULL, UT_Fpreal32Array *warningCoords=NULL)
 
GU_API void GUcircleEdges (UT_Map< GA_Offset, UT_Vector3 > &edits, const GU_Detail &gdp, const UT_Set< GA_Edge > &gaedges)
 
GU_API void GUevenlySpaceEdges (UT_Map< GA_Offset, UT_Vector3 > &edits, const GU_Detail &gdp, const UT_Set< GA_Edge > &gaedges)
 
GU_API void GUstraightenEdges (UT_Map< GA_Offset, UT_Vector3 > &edits, const GU_Detail &gdp, const UT_Set< GA_Edge > &gaedges, const UT_Vector3 *constrain_nml)
 
GU_API void GUfindUnsharedEdges (const GEO_Detail &detail, GA_DirectedEdgeSet &edges, const GA_PrimitiveGroup *primgroup=NULL)
 
GU_API void GUfindUnsharedEdges (const GEO_Detail &detail, UT_Array< GA_DirectedEdge > &edges, const GA_PrimitiveGroup *primgroup=NULL)
 

Macro Definition Documentation

#define __GU_EdgeUtils_h__

Definition at line 15 of file GU_EdgeUtils.h.

Function Documentation

GU_API void GUcircleEdges ( UT_Map< GA_Offset, UT_Vector3 > &  edits,
const GU_Detail gdp,
const UT_Set< GA_Edge > &  gaedges 
)
GU_API UT_Vector3 GUcomputeInsetPos ( const GEO_Face face,
int  vtx,
float  inset 
)
GU_API void GUedgeLoopSplit ( GU_Detail gdp,
GA_Offset  pt0,
GA_Offset  pt1,
fpreal  u,
exint  splits = 0,
bool  parallel = false,
GA_EdgeGroup edgeGroup = NULL,
UT_Fpreal32Array warningCoords = NULL 
)
GU_API void GUevenlySpaceEdges ( UT_Map< GA_Offset, UT_Vector3 > &  edits,
const GU_Detail gdp,
const UT_Set< GA_Edge > &  gaedges 
)
GU_API void GUfindUnsharedEdges ( const GEO_Detail detail,
GA_EdgeGroup edges,
const GA_PrimitiveGroup primgroup = NULL,
bool  prims_on_edges = false 
)

Iterates through the primitives of the detail, calling edgeApply on each primitive to count the number of times each (unordered) edge is present, and adds any edges that appear only once. If prims_on_edges is true, each edge in the edge group will reference the primitive it's associated with. WARNING: A lot of things can go bonkers if you use prims_on_edges! For example, toggling the edge group will result in a group that contains all of the original edges plus every edge, so more edges than the total number.

GU_API void GUfindUnsharedEdges ( const GEO_Detail detail,
GA_DirectedEdgeSet edges,
const GA_PrimitiveGroup primgroup = NULL 
)

Iterates through the primitives of the detail, calling edgeApply on each primitive to count the number of times each (unordered) edge is present, and adds any edges that appear only once, in the direction they appear. WARNING: GA_DirectedEdgeSet is an unordered set, so iteration order can't be relied upon if you use that version.

GU_API void GUfindUnsharedEdges ( const GEO_Detail detail,
UT_Array< GA_DirectedEdge > &  edges,
const GA_PrimitiveGroup primgroup = NULL 
)

Iterates through the primitives of the detail, calling edgeApply on each primitive to count the number of times each (unordered) edge is present, and adds any edges that appear only once, in the direction they appear. WARNING: GA_DirectedEdgeSet is an unordered set, so iteration order can't be relied upon if you use that version.

GU_API bool GUgetEdgePoints ( const GEO_Face face,
int  edgenum,
GA_Offset p0,
GA_Offset p1 
)
GU_API bool GUisPointInline ( const UT_Vector3 start,
const UT_Vector3 mid,
const UT_Vector3 end,
float  tol 
)
GU_API void GUstraightenEdges ( UT_Map< GA_Offset, UT_Vector3 > &  edits,
const GU_Detail gdp,
const UT_Set< GA_Edge > &  gaedges,
const UT_Vector3 constrain_nml 
)