|
Blender
V3.3
|
#include "CCGSubSurf_inline.h"Go to the source code of this file.
Classes | |
| struct | _EHEntry |
| struct | _EHash |
| struct | CCGVert |
| struct | CCGEdge |
| struct | CCGFace |
| struct | CCGSubSurf |
Macros | |
| #define | EPSILON (1.0e-35f) |
| #define | CCGSUBSURF_LEVEL_MAX 11 |
| #define | EHASH_alloc(eh, nb) ((eh)->allocatorIFC.alloc((eh)->allocator, nb)) |
| #define | EHASH_free(eh, ptr) ((eh)->allocatorIFC.free((eh)->allocator, ptr)) |
| #define | EHASH_hash(eh, item) (((uintptr_t)(item)) % ((unsigned int)(eh)->curSize)) |
| #define | CCGSUBSURF_alloc(ss, nb) ((ss)->allocatorIFC.alloc((ss)->allocator, nb)) |
| #define | CCGSUBSURF_realloc(ss, ptr, nb, ob) ((ss)->allocatorIFC.realloc((ss)->allocator, ptr, nb, ob)) |
| #define | CCGSUBSURF_free(ss, ptr) ((ss)->allocatorIFC.free((ss)->allocator, ptr)) |
| #define | VERT_getCo(v, lvl) ccg_vert_getCo(v, lvl, vertDataSize) |
| #define | VERT_getNo(v, lvl) ccg_vert_getNo(v, lvl, vertDataSize, normalDataOffset) |
| #define | EDGE_getCo(e, lvl, x) ccg_edge_getCo(e, lvl, x, vertDataSize) |
| #define | EDGE_getNo(e, lvl, x) ccg_edge_getNo(e, lvl, x, vertDataSize, normalDataOffset) |
| #define | FACE_getIFNo(f, lvl, S, x, y) ccg_face_getIFNo(f, lvl, S, x, y, subdivLevels, vertDataSize, normalDataOffset) |
| #define | FACE_getIENo(f, lvl, S, x) ccg_face_getIENo(f, lvl, S, x, subdivLevels, vertDataSize, normalDataOffset) |
| #define | FACE_getIECo(f, lvl, S, x) ccg_face_getIECo(f, lvl, S, x, subdivLevels, vertDataSize) |
| #define | FACE_getIFCo(f, lvl, S, x, y) ccg_face_getIFCo(f, lvl, S, x, y, subdivLevels, vertDataSize) |
| #define | NormZero(av) |
| #define | NormCopy(av, bv) |
| #define | NormAdd(av, bv) |
Typedefs | |
| typedef unsigned char | byte |
| typedef struct _EHEntry | EHEntry |
| typedef struct _EHash | EHash |
| typedef void(* | EHEntryFreeFP) (EHEntry *, void *) |
Enumerations | |
| enum | { Vert_eEffected = (1 << 0) , Vert_eChanged = (1 << 1) , Vert_eSeam = (1 << 2) } |
| enum | { Edge_eEffected = (1 << 0) } |
| enum | { Face_eEffected = (1 << 0) } |
| enum | SyncState { eSyncState_None = 0 , eSyncState_Vert , eSyncState_Edge , eSyncState_Face , eSyncState_Partial } |
| #define CCGSUBSURF_alloc | ( | ss, | |
| nb | |||
| ) | ((ss)->allocatorIFC.alloc((ss)->allocator, nb)) |
Definition at line 191 of file CCGSubSurf_intern.h.
| #define CCGSUBSURF_free | ( | ss, | |
| ptr | |||
| ) | ((ss)->allocatorIFC.free((ss)->allocator, ptr)) |
Definition at line 194 of file CCGSubSurf_intern.h.
| #define CCGSUBSURF_LEVEL_MAX 11 |
Definition at line 21 of file CCGSubSurf_intern.h.
| #define CCGSUBSURF_realloc | ( | ss, | |
| ptr, | |||
| nb, | |||
| ob | |||
| ) | ((ss)->allocatorIFC.realloc((ss)->allocator, ptr, nb, ob)) |
Definition at line 192 of file CCGSubSurf_intern.h.
Definition at line 198 of file CCGSubSurf_intern.h.
Definition at line 199 of file CCGSubSurf_intern.h.
| #define EHASH_alloc | ( | eh, | |
| nb | |||
| ) | ((eh)->allocatorIFC.alloc((eh)->allocator, nb)) |
Definition at line 48 of file CCGSubSurf_intern.h.
| #define EHASH_free | ( | eh, | |
| ptr | |||
| ) | ((eh)->allocatorIFC.free((eh)->allocator, ptr)) |
Definition at line 49 of file CCGSubSurf_intern.h.
Definition at line 50 of file CCGSubSurf_intern.h.
| #define EPSILON (1.0e-35f) |
Definitions which defines internal behavior of CCGSubSurf.
Definition at line 18 of file CCGSubSurf_intern.h.
| #define FACE_getIECo | ( | f, | |
| lvl, | |||
| S, | |||
| x | |||
| ) | ccg_face_getIECo(f, lvl, S, x, subdivLevels, vertDataSize) |
Definition at line 208 of file CCGSubSurf_intern.h.
| #define FACE_getIENo | ( | f, | |
| lvl, | |||
| S, | |||
| x | |||
| ) | ccg_face_getIENo(f, lvl, S, x, subdivLevels, vertDataSize, normalDataOffset) |
Definition at line 206 of file CCGSubSurf_intern.h.
| #define FACE_getIFCo | ( | f, | |
| lvl, | |||
| S, | |||
| x, | |||
| y | |||
| ) | ccg_face_getIFCo(f, lvl, S, x, y, subdivLevels, vertDataSize) |
Definition at line 209 of file CCGSubSurf_intern.h.
| #define FACE_getIFNo | ( | f, | |
| lvl, | |||
| S, | |||
| x, | |||
| y | |||
| ) | ccg_face_getIFNo(f, lvl, S, x, y, subdivLevels, vertDataSize, normalDataOffset) |
Definition at line 200 of file CCGSubSurf_intern.h.
| #define NormAdd | ( | av, | |
| bv | |||
| ) |
Definition at line 225 of file CCGSubSurf_intern.h.
| #define NormCopy | ( | av, | |
| bv | |||
| ) |
Definition at line 217 of file CCGSubSurf_intern.h.
| #define NormZero | ( | av | ) |
Definition at line 211 of file CCGSubSurf_intern.h.
| #define VERT_getCo | ( | v, | |
| lvl | |||
| ) | ccg_vert_getCo(v, lvl, vertDataSize) |
Definition at line 196 of file CCGSubSurf_intern.h.
| #define VERT_getNo | ( | v, | |
| lvl | |||
| ) | ccg_vert_getNo(v, lvl, vertDataSize, normalDataOffset) |
Definition at line 197 of file CCGSubSurf_intern.h.
| typedef unsigned char byte |
Common type definitions.
Definition at line 27 of file CCGSubSurf_intern.h.
Definition at line 46 of file CCGSubSurf_intern.h.
| anonymous enum |
| Enumerator | |
|---|---|
| Vert_eEffected | |
| Vert_eChanged | |
| Vert_eSeam | |
Definition at line 84 of file CCGSubSurf_intern.h.
| anonymous enum |
| Enumerator | |
|---|---|
| Edge_eEffected | |
Definition at line 90 of file CCGSubSurf_intern.h.
| anonymous enum |
| Enumerator | |
|---|---|
| Face_eEffected | |
Definition at line 94 of file CCGSubSurf_intern.h.
| enum SyncState |
| Enumerator | |
|---|---|
| eSyncState_None | |
| eSyncState_Vert | |
| eSyncState_Edge | |
| eSyncState_Face | |
| eSyncState_Partial | |
Definition at line 139 of file CCGSubSurf_intern.h.
| void ccg_ehash_free | ( | EHash * | eh, |
| EHEntryFreeFP | freeEntry, | ||
| void * | userData | ||
| ) |
Definition at line 50 of file CCGSubSurf_util.c.
References _EHash::buckets, _EHash::curSize, EHASH_free, _EHEntry::next, and next.
Referenced by ccgSubSurf_free(), ccgSubSurf_processSync(), and ccgSubSurf_setSubdivisionLevels().
Definition at line 70 of file CCGSubSurf_util.c.
References _EHash::buckets, _EHash::curSize, _EHash::curSizeIdx, EHASH_alloc, EHASH_free, EHASH_hash, hash, _EHEntry::key, kHashSizes, _EHEntry::next, next, _EHash::numEntries, and UNLIKELY.
Referenced by ccgSubSurf_syncEdge(), ccgSubSurf_syncFace(), and ccgSubSurf_syncVert().
Definition at line 117 of file CCGSubSurf_util.c.
References _EHash::buckets, EHASH_hash, hash, _EHEntry::key, and _EHEntry::next.
Referenced by ccgSubSurf_getEdge(), ccgSubSurf_getFace(), ccgSubSurf_getVert(), ccgSubSurf_syncEdge(), and ccgSubSurf_syncFace().
Definition at line 101 of file CCGSubSurf_util.c.
References _EHash::buckets, EHASH_hash, hash, and NULL.
Referenced by ccgSubSurf_syncEdge(), ccgSubSurf_syncEdgeDel(), ccgSubSurf_syncFace(), ccgSubSurf_syncFaceDel(), ccgSubSurf_syncVert(), and ccgSubSurf_syncVertDel().
| EHash* ccg_ehash_new | ( | int | estimatedNumEntries, |
| CCGAllocatorIFC * | allocatorIFC, | ||
| CCGAllocatorHDL | allocator | ||
| ) |
Definition at line 31 of file CCGSubSurf_util.c.
References CCGAllocatorIFC::alloc, _EHash::allocator, _EHash::allocatorIFC, _EHash::buckets, _EHash::curSize, _EHash::curSizeIdx, EHASH_alloc, kHashSizes, and _EHash::numEntries.
Referenced by ccgSubSurf_initFullSync(), ccgSubSurf_new(), and ccgSubSurf_setSubdivisionLevels().
| void* ccg_ehashIterator_getCurrent | ( | EHashIterator * | ehi | ) |
Definition at line 149 of file CCGSubSurf_util.c.
References _EHashIterator::curEntry.
Referenced by ccgEdgeIterator_getCurrent(), ccgFaceIterator_getCurrent(), and ccgVertIterator_getCurrent().
| void ccg_ehashIterator_init | ( | EHash * | eh, |
| EHashIterator * | ehi | ||
| ) |
Definition at line 133 of file CCGSubSurf_util.c.
References _EHash::buckets, _EHashIterator::curBucket, _EHashIterator::curEntry, _EHash::curSize, _EHashIterator::eh, and NULL.
Referenced by ccgSubSurf_initEdgeIterator(), ccgSubSurf_initFaceIterator(), and ccgSubSurf_initVertIterator().
| int ccg_ehashIterator_isStopped | ( | EHashIterator * | ehi | ) |
Definition at line 167 of file CCGSubSurf_util.c.
References _EHashIterator::curEntry.
Referenced by ccgEdgeIterator_isStopped(), ccgFaceIterator_isStopped(), and ccgVertIterator_isStopped().
| void ccg_ehashIterator_next | ( | EHashIterator * | ehi | ) |
Definition at line 154 of file CCGSubSurf_util.c.
References _EHash::buckets, _EHashIterator::curBucket, _EHashIterator::curEntry, _EHash::curSize, _EHashIterator::eh, and _EHEntry::next.
Referenced by ccgEdgeIterator_next(), ccgFaceIterator_next(), and ccgVertIterator_next().
| CCGAllocatorIFC* ccg_getStandardAllocatorIFC | ( | void | ) |
Standard allocator implementation.
Definition at line 194 of file CCGSubSurf_util.c.
References _stdAllocator_alloc(), _stdAllocator_free(), _stdAllocator_realloc(), CCGAllocatorIFC::alloc, CCGAllocatorIFC::free, NULL, CCGAllocatorIFC::realloc, and CCGAllocatorIFC::release.
Referenced by ccgSubSurf_new().
| void ccgSubSurf__allFaces | ( | CCGSubSurf * | ss, |
| CCGFace *** | faces, | ||
| int * | numFaces, | ||
| int * | freeFaces | ||
| ) |
Definition at line 842 of file CCGSubSurf.c.
References _EHash::buckets, _EHash::curSize, faces, CCGSubSurf::fMap, MEM_mallocN, CCGFace::next, NULL, and _EHash::numEntries.
Referenced by ccgSubSurf_stitchFaces(), ccgSubSurf_updateFromFaces(), ccgSubSurf_updateLevels(), ccgSubSurf_updateNormals(), and ccgSubSurf_updateToFaces().
| void ccgSubSurf__effectedFaceNeighbors | ( | CCGSubSurf * | ss, |
| CCGFace ** | faces, | ||
| int | numFaces, | ||
| CCGVert *** | verts, | ||
| int * | numVerts, | ||
| CCGEdge *** | edges, | ||
| int * | numEdges | ||
| ) |
Definition at line 867 of file CCGSubSurf.c.
References _EHash::buckets, _EHash::curSize, e, Edge_eEffected, CCGSubSurf::eMap, Face_eEffected, faces, CCGFace::flags, MEM_mallocN, _EHash::numEntries, v, Vert_eEffected, verts, and CCGSubSurf::vMap.
Referenced by ccgSubSurf_stitchFaces(), ccgSubSurf_updateLevels(), and ccgSubSurf_updateNormals().
| void ccgSubSurf__sync_legacy | ( | CCGSubSurf * | ss | ) |
Definition at line 1003 of file CCGSubSurf_legacy.c.
References _edge_getCoVert(), _edge_getOtherVert(), _edge_isBoundary(), _vert_isBoundary(), _EHash::buckets, CCGSubSurf::calcVertNormals, ccgSubSurf__calcSubdivLevel(), ccgSubSurf__calcVertNormals(), ccgSubSurf_getEdgeUserData(), ccgSubSurf_getFaceUserData(), ccgSubSurf_getVertUserData(), CCGSubSurf::currentAge, _EHash::curSize, e, Edge_eEffected, EDGE_getCo, EDGE_getSharpness(), CCGSubSurf::edgeUserAgeOffset, CCGSubSurf::eMap, Face_eEffected, FACE_getCenterData(), FACE_getEdges(), FACE_getIECo, FACE_getIFCo, FACE_getVerts(), CCGSubSurf::faceUserAgeOffset, CCGFace::flags, CCGSubSurf::fMap, MEM_freeN, MEM_mallocN, CCGSubSurf::meshIFC, _EHash::numEntries, CCGFace::numVerts, CCGSubSurf::q, CCGSubSurf::r, r, CCGMeshIFC::simpleSubdiv, CCGSubSurf::subdivLevels, CCGSubSurf::useAgeCounts, v, Vert_eEffected, VERT_getCo, VERT_seam(), VertDataAdd(), VertDataCopy(), VertDataMulN(), CCGMeshIFC::vertDataSize, VertDataSub(), VertDataZero(), CCGSubSurf::vertUserAgeOffset, and CCGSubSurf::vMap.
Referenced by ccgSubSurf__sync().
| void ccgSubSurf__sync_opensubdiv | ( | CCGSubSurf * | ss | ) |
| void ccgSubSurf_converter_free | ( | struct OpenSubdiv_Converter * | converter | ) |
| void ccgSubSurf_converter_setup_from_ccg | ( | CCGSubSurf * | ss, |
| struct OpenSubdiv_Converter * | converter | ||
| ) |
| void ccgSubSurf_converter_setup_from_derivedmesh | ( | CCGSubSurf * | ss, |
| struct DerivedMesh * | dm, | ||
| struct OpenSubdiv_Converter * | converter | ||
| ) |