Blender
V3.3
|
#include <math.h>
#include "BKE_subdiv_ccg.h"
#include "DNA_mesh_types.h"
#include "DNA_meshdata_types.h"
#include "DNA_modifier_types.h"
#include "DNA_object_types.h"
#include "BLI_utildefines.h"
#include "BKE_customdata.h"
#include "BKE_subdiv.h"
#include "MEM_guardedalloc.h"
Go to the source code of this file.
Classes | |
struct | PolyCornerIndex |
struct | GridPaintMaskData |
Typedefs | |
typedef struct PolyCornerIndex | PolyCornerIndex |
typedef struct GridPaintMaskData | GridPaintMaskData |
Functions | |
static int | mask_get_grid_and_coord (SubdivCCGMaskEvaluator *mask_evaluator, const int ptex_face_index, const float u, const float v, const GridPaintMask **r_mask_grid, float *grid_u, float *grid_v) |
BLI_INLINE float | read_mask_grid (const GridPaintMask *mask_grid, const float grid_u, const float grid_v) |
static float | eval_mask (SubdivCCGMaskEvaluator *mask_evaluator, const int ptex_face_index, const float u, const float v) |
static void | free_mask_data (SubdivCCGMaskEvaluator *mask_evaluator) |
static int | count_num_ptex_faces (const Mesh *mesh) |
static void | mask_data_init_mapping (SubdivCCGMaskEvaluator *mask_evaluator, const Mesh *mesh) |
static void | mask_init_data (SubdivCCGMaskEvaluator *mask_evaluator, const Mesh *mesh) |
static void | mask_init_functions (SubdivCCGMaskEvaluator *mask_evaluator) |
bool | BKE_subdiv_ccg_mask_init_from_paint (SubdivCCGMaskEvaluator *mask_evaluator, const struct Mesh *mesh) |
typedef struct GridPaintMaskData GridPaintMaskData |
typedef struct PolyCornerIndex PolyCornerIndex |
bool BKE_subdiv_ccg_mask_init_from_paint | ( | SubdivCCGMaskEvaluator * | mask_evaluator, |
const struct Mesh * | mesh | ||
) |
Definition at line 155 of file subdiv_ccg_mask.c.
References CD_GRID_PAINT_MASK, CustomData_get_layer(), Mesh::ldata, mask_init_data(), mask_init_functions(), MEM_callocN, mesh, and SubdivCCGMaskEvaluator::user_data.
Referenced by BKE_subdiv_to_ccg_mesh().
|
static |
Definition at line 102 of file subdiv_ccg_mask.c.
References mesh, Mesh::mpoly, MPoly::totloop, and Mesh::totpoly.
Referenced by mask_data_init_mapping().
|
static |
Definition at line 81 of file subdiv_ccg_mask.c.
References mask_get_grid_and_coord(), read_mask_grid(), and v.
Referenced by mask_init_functions().
|
static |
Definition at line 92 of file subdiv_ccg_mask.c.
References data, MEM_freeN, and SubdivCCGMaskEvaluator::user_data.
Referenced by mask_init_functions().
|
static |
Definition at line 113 of file subdiv_ccg_mask.c.
References PolyCornerIndex::corner, count_num_ptex_faces(), data, MEM_malloc_arrayN, mesh, Mesh::mpoly, PolyCornerIndex::poly_index, MPoly::totloop, Mesh::totpoly, and SubdivCCGMaskEvaluator::user_data.
Referenced by mask_init_data().
|
static |
Definition at line 42 of file subdiv_ccg_mask.c.
References BKE_subdiv_ptex_face_uv_to_grid_uv(), BKE_subdiv_rotate_quad_to_corner(), PolyCornerIndex::corner, data, MPoly::loopstart, PolyCornerIndex::poly_index, MPoly::totloop, SubdivCCGMaskEvaluator::user_data, and v.
Referenced by eval_mask().
|
static |
Definition at line 141 of file subdiv_ccg_mask.c.
References CD_GRID_PAINT_MASK, CustomData_get_layer(), data, Mesh::ldata, mask_data_init_mapping(), mesh, Mesh::mpoly, and SubdivCCGMaskEvaluator::user_data.
Referenced by BKE_subdiv_ccg_mask_init_from_paint().
|
static |
Definition at line 149 of file subdiv_ccg_mask.c.
References eval_mask(), SubdivCCGMaskEvaluator::eval_mask, SubdivCCGMaskEvaluator::free, and free_mask_data().
Referenced by BKE_subdiv_ccg_mask_init_from_paint().
BLI_INLINE float read_mask_grid | ( | const GridPaintMask * | mask_grid, |
const float | grid_u, | ||
const float | grid_v | ||
) |
Definition at line 68 of file subdiv_ccg_mask.c.
References BKE_subdiv_grid_size_from_level(), GridPaintMask::data, GridPaintMask::level, NULL, x, and y.
Referenced by eval_mask().