Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blenkernel/BKE_subdiv_ccg.h
| Context not available. | |||||
| bool need_mask; | bool need_mask; | ||||
| } SubdivToCCGSettings; | } SubdivToCCGSettings; | ||||
| typedef struct SubdivCCGCoord { | |||||
| /* Index of the grid within SubdivCCG::grids array. */ | |||||
| int grid_index; | |||||
| /* Coordinate within the grid. */ | |||||
| short x, y; | |||||
| } SubdivCCGCoord; | |||||
| /* This is actually a coarse face, which consists of multiple CCG grids. */ | /* This is actually a coarse face, which consists of multiple CCG grids. */ | ||||
| typedef struct SubdivCCGFace { | typedef struct SubdivCCGFace { | ||||
| /* Total number of grids in this face. | /* Total number of grids in this face. | ||||
| Context not available. | |||||
| typedef struct SubdivCCGAdjacentEdge { | typedef struct SubdivCCGAdjacentEdge { | ||||
| int num_adjacent_faces; | int num_adjacent_faces; | ||||
| /* Indexed by adjacent face index, then by point index on the edge. | /* Indexed by adjacent face index, then by point index on the edge. | ||||
| * points to a coordinate into the grids. */ | * points to a grid element. */ | ||||
| struct SubdivCCGCoord **boundary_coords; | struct CCGElem ***boundary_elements; | ||||
| } SubdivCCGAdjacentEdge; | } SubdivCCGAdjacentEdge; | ||||
| /* Definition of a vertex which is adjacent to at least one of the faces. */ | /* Definition of a vertex which is adjacent to at least one of the faces. */ | ||||
| typedef struct SubdivCCGAdjacentVertex { | typedef struct SubdivCCGAdjacentVertex { | ||||
| int num_adjacent_faces; | int num_adjacent_faces; | ||||
| /* Indexed by adjacent face index, points to a coordinate in the grids. */ | /* Indexed by adjacent face index, points to a grid element. */ | ||||
| struct SubdivCCGCoord *corner_coords; | struct CCGElem **corner_elements; | ||||
| } SubdivCCGAdjacentVertex; | } SubdivCCGAdjacentVertex; | ||||
| /* Representation of subdivision surface which uses CCG grids. */ | /* Representation of subdivision surface which uses CCG grids. */ | ||||
| Context not available. | |||||
| int *r_num_faces, | int *r_num_faces, | ||||
| int *r_num_loops); | int *r_num_loops); | ||||
| typedef struct SubdivCCGCoord { | |||||
| /* Index of the grid within SubdivCCG::grids array. */ | |||||
| int grid_index; | |||||
| /* Coordinate within the grid. */ | |||||
| int x, y; | |||||
| } SubdivCCGCoord; | |||||
| typedef struct SubdivCCGNeighbors { | typedef struct SubdivCCGNeighbors { | ||||
| SubdivCCGCoord *coords; | SubdivCCGCoord *coords; | ||||
| int size; | int size; | ||||
| int num_duplicates; | |||||
| SubdivCCGCoord coords_fixed[256]; | SubdivCCGCoord coords_fixed[256]; | ||||
| } SubdivCCGNeighbors; | } SubdivCCGNeighbors; | ||||
| Context not available. | |||||
| /* Get actual neighbors of the given coordinate. | /* Get actual neighbors of the given coordinate. | ||||
| * | * | ||||
| * SubdivCCGNeighbors.neighbors must be freed if it is not equal to | * SubdivCCGNeighbors.neighbors must be freed if it is not equal to | ||||
| * SubdivCCGNeighbors.fixed_neighbors. | * SubdivCCGNeighbors.fixed_neighbors. */ | ||||
| * | |||||
| * If include_duplicates is true, vertices in other grids that match | |||||
| * the current vertex are added at the end of the coords array. */ | |||||
| void BKE_subdiv_ccg_neighbor_coords_get(const SubdivCCG *subdiv_ccg, | void BKE_subdiv_ccg_neighbor_coords_get(const SubdivCCG *subdiv_ccg, | ||||
| const SubdivCCGCoord *coord, | const SubdivCCGCoord *coord, | ||||
| const bool include_duplicates, | |||||
| SubdivCCGNeighbors *r_neighbors); | SubdivCCGNeighbors *r_neighbors); | ||||
| #endif /* __BKE_SUBDIV_CCG_H__ */ | #endif /* __BKE_SUBDIV_CCG_H__ */ | ||||
| Context not available. | |||||