Blender
V3.3
|
A BVH for high poly meshes. More...
Go to the source code of this file.
Classes | |
struct | PBVHProxyNode |
struct | PBVHColorBufferNode |
struct | PBVHPixelsNode |
struct | PBVHFrustumPlanes |
struct | PBVHVertexIter |
Macros | |
#define | PBVH_ITER_ALL 0 |
#define | PBVH_ITER_UNIQUE 1 |
#define | BKE_pbvh_vertex_iter_begin(pbvh, node, vi, mode) |
#define | BKE_pbvh_vertex_iter_end |
Typedefs | |
typedef struct PBVH | PBVH |
typedef struct PBVHNode | PBVHNode |
typedef struct PBVHPixelsNode | PBVHPixelsNode |
typedef struct PBVHFrustumPlanes | PBVHFrustumPlanes |
typedef bool(* | BKE_pbvh_SearchCallback) (PBVHNode *node, void *data) |
typedef void(* | BKE_pbvh_HitCallback) (PBVHNode *node, void *data) |
typedef void(* | BKE_pbvh_HitOccludedCallback) (PBVHNode *node, void *data, float *tmin) |
typedef void(* | BKE_pbvh_SearchNearestCallback) (PBVHNode *node, void *data, float *tmin) |
typedef struct PBVHVertexIter | PBVHVertexIter |
Enumerations | |
enum | PBVHNodeFlags { PBVH_Leaf = 1 << 0 , PBVH_UpdateNormals = 1 << 1 , PBVH_UpdateBB = 1 << 2 , PBVH_UpdateOriginalBB = 1 << 3 , PBVH_UpdateDrawBuffers = 1 << 4 , PBVH_UpdateRedraw = 1 << 5 , PBVH_UpdateMask = 1 << 6 , PBVH_UpdateVisibility = 1 << 8 , PBVH_RebuildDrawBuffers = 1 << 9 , PBVH_FullyHidden = 1 << 10 , PBVH_FullyMasked = 1 << 11 , PBVH_FullyUnmasked = 1 << 12 , PBVH_UpdateTopology = 1 << 13 , PBVH_UpdateColor = 1 << 14 , PBVH_RebuildPixels = 1 << 15 } |
enum | PBVHType { PBVH_FACES , PBVH_GRIDS , PBVH_BMESH } |
enum | PBVHTopologyUpdateMode { PBVH_Subdivide = 1 , PBVH_Collapse = 2 } |
A BVH for high poly meshes.
Definition in file BKE_pbvh.h.
Definition at line 439 of file BKE_pbvh.h.
#define BKE_pbvh_vertex_iter_end |
Definition at line 509 of file BKE_pbvh.h.
#define PBVH_ITER_ALL 0 |
Definition at line 390 of file BKE_pbvh.h.
#define PBVH_ITER_UNIQUE 1 |
Definition at line 391 of file BKE_pbvh.h.
Definition at line 100 of file BKE_pbvh.h.
Definition at line 101 of file BKE_pbvh.h.
Returns true if the search should continue from this node, false otherwise.
Definition at line 98 of file BKE_pbvh.h.
Definition at line 103 of file BKE_pbvh.h.
Definition at line 1 of file BKE_pbvh.h.
typedef struct PBVHFrustumPlanes PBVHFrustumPlanes |
Definition at line 1 of file BKE_pbvh.h.
typedef struct PBVHPixelsNode PBVHPixelsNode |
typedef struct PBVHVertexIter PBVHVertexIter |
enum PBVHNodeFlags |
Definition at line 63 of file BKE_pbvh.h.
Enumerator | |
---|---|
PBVH_Subdivide | |
PBVH_Collapse |
Definition at line 278 of file BKE_pbvh.h.
enum PBVHType |
Enumerator | |
---|---|
PBVH_FACES | |
PBVH_GRIDS | |
PBVH_BMESH |
Definition at line 233 of file BKE_pbvh.h.
Definition at line 2077 of file pbvh_bmesh.c.
References PBVHNode::flag, PBVH::nodes, pbvh_bmesh_node_drop_orig(), pbvh_bmesh_node_limit_ensure(), PBVH_Leaf, and PBVH::totnode.
Referenced by SCULPT_flush_update_done().
Definition at line 2092 of file pbvh_bmesh.c.
References PBVH::bm_max_edge_len, and PBVH::bm_min_edge_len.
Referenced by BKE_pbvh_build_bmesh(), sculpt_detail_flood_fill_exec(), and sculpt_stroke_update_step().
Definition at line 2113 of file pbvh_bmesh.c.
References node.
Referenced by partialvis_update_bmesh(), and sculpt_undo_bmesh_push().
Definition at line 2108 of file pbvh_bmesh.c.
References node.
Referenced by partialvis_update_bmesh(), and pbvh_bmesh_node_visibility_update().
bool BKE_pbvh_bmesh_node_raycast_detail | ( | PBVHNode * | node, |
const float | ray_start[3], | ||
struct IsectRayPrecalc * | isect_precalc, | ||
float * | depth, | ||
float * | r_edge_length | ||
) |
Definition at line 1560 of file pbvh_bmesh.c.
References BLI_assert, BLI_gsetIterator_getKey(), BM_elem_flag_test, BM_ELEM_HIDDEN, BM_face_as_array_vert_tri(), GSET_ITER, BMFace::len, len_squared_v3v3(), max_fff(), node, NULL, PBVH_FullyHidden, ray_face_intersection_tri(), and sqrtf.
Referenced by sculpt_raycast_detail_cb().
In order to perform operations on the original node coordinates (currently just ray-cast), store the node's triangles and vertices.
Skips triangles that are hidden.
Definition at line 2020 of file pbvh_bmesh.c.
References BLI_gset_len(), BLI_gsetIterator_getKey(), bm, BM_elem_flag_test, BM_ELEM_HIDDEN, BM_elem_index_get, BM_elem_index_set, bm_face_as_array_index_tri(), BM_ITER_ELEM, BM_VERT, BM_VERTS_OF_FACE, BMVert::co, copy_v3_v3(), BMesh::elem_index_dirty, GSET_ITER, MEM_mallocN, node, and v.
Referenced by sculpt_topology_update().
Definition at line 2103 of file pbvh_bmesh.c.
References node.
Referenced by partialvis_update_bmesh(), and pbvh_bmesh_node_visibility_update().
bool BKE_pbvh_bmesh_update_topology | ( | PBVH * | pbvh, |
PBVHTopologyUpdateMode | mode, | ||
const float | center[3], | ||
const float | view_normal[3], | ||
float | radius, | ||
bool | use_frontface, | ||
bool | use_projected | ||
) |
Collapse short edges, subdivide long edges.
Definition at line 1943 of file pbvh_bmesh.c.
References BLI_assert, BLI_buffer_declare_static, BLI_buffer_free, BLI_BUFFER_NOP, BLI_heapsimple_free(), BLI_mempool_create(), BLI_mempool_destroy(), BLI_MEMPOOL_NOP, PBVH::bm, PBVH::cd_face_node_offset, CD_PAINT_MASK, PBVH::cd_vert_node_offset, center, CustomData_get_offset(), EdgeQueue::heap, len_squared_v3(), long_edge_queue_create(), node, PBVH::nodes, NULL, pbvh_bmesh_collapse_short_edges(), pbvh_bmesh_subdivide_long_edges(), PBVH_Collapse, PBVH_Leaf, PBVH_Subdivide, PBVH_UpdateTopology, short_edge_queue_create(), PBVH::totnode, and BMesh::vdata.
Referenced by sculpt_detail_flood_fill_exec(), and sculpt_topology_update().
Get the PBVH root's bounding box.
Definition at line 1812 of file pbvh.c.
References BB::bmax, BB::bmin, copy_v3_v3(), max, min, PBVH::nodes, PBVH::totnode, PBVHNode::vb, and zero_v3().
Referenced by sculpt_detail_flood_fill_exec(), and SCULPT_update_object_bounding_box().
void BKE_pbvh_build_bmesh | ( | PBVH * | pbvh, |
struct BMesh * | bm, | ||
bool | smooth_shading, | ||
struct BMLog * | log, | ||
int | cd_vert_node_offset, | ||
int | cd_face_node_offset | ||
) |
Definition at line 1866 of file pbvh_bmesh.c.
References BB_expand(), BB_reset(), BBC_update_centroid(), BKE_pbvh_bmesh_detail_size_set(), BLI_memarena_free(), BLI_memarena_new(), BLI_MEMARENA_STD_BUFSIZE, PBVH::bm, bm, BM_ELEM_CD_SET_INT, BM_elem_index_set, BM_FACE, BM_FACE_FIRST_LOOP, BM_FACES_OF_MESH, BM_ITER_MESH, BM_ITER_MESH_INDEX, PBVH::bm_log, BM_VERTS_OF_MESH, PBVH::cd_face_node_offset, PBVH::cd_vert_node_offset, BMVert::co, DYNTOPO_NODE_NONE, BMesh::elem_index_dirty, PBVH::flags, PBVH::leaf_limit, log(), MEM_callocN, MEM_freeN, MEM_mallocN, BMLoop::next, PBVH::nodes, PBVH_BMESH, pbvh_bmesh_create_nodes_fast_recursive(), pbvh_bmesh_node_limit_ensure_fast(), PBVH_DYNTOPO_SMOOTH_SHADING, FastNodeBuildInfo::totface, BMesh::totface, PBVH::totnode, PBVH::type, BMLoop::v, and v.
Referenced by build_pbvh_for_dynamic_topology().
void BKE_pbvh_build_grids | ( | PBVH * | pbvh, |
struct CCGElem ** | grids, | ||
int | totgrid, | ||
struct CCGKey * | key, | ||
void ** | gridfaces, | ||
struct DMFlagMat * | flagmats, | ||
unsigned int ** | grid_hidden | ||
) |
Do a full rebuild with on Grids data structure.
Definition at line 608 of file pbvh.c.
References BB_expand(), BB_reset(), BBC_update_centroid(), BBC::bcentroid, CCG_elem_offset_co(), PBVH::grid_flag_mats, PBVH::grid_hidden, CCGKey::grid_size, PBVH::gridfaces, PBVH::gridkey, PBVH::grids, LEAF_LIMIT, PBVH::leaf_limit, max_ii(), MEM_freeN, MEM_mallocN, pbvh_build(), PBVH_GRIDS, PBVH::totgrid, and PBVH::type.
Referenced by build_pbvh_from_ccg().
void BKE_pbvh_build_mesh | ( | PBVH * | pbvh, |
struct Mesh * | mesh, | ||
const struct MPoly * | mpoly, | ||
const struct MLoop * | mloop, | ||
struct MVert * | verts, | ||
int | totvert, | ||
struct CustomData * | vdata, | ||
struct CustomData * | ldata, | ||
struct CustomData * | pdata, | ||
const struct MLoopTri * | looptri, | ||
int | looptri_num | ||
) |
Do a full rebuild with on Mesh data structure.
Referenced by build_pbvh_from_regular_mesh().
void BKE_pbvh_build_pixels | ( | PBVH * | pbvh, |
struct Mesh * | mesh, | ||
struct Image * | image, | ||
struct ImageUser * | image_user | ||
) |
Definition at line 383 of file pbvh_pixels.cc.
References image(), mesh, and blender::bke::pbvh::pixels::update_pixels().
Referenced by sculpt_pbvh_update_pixels().
int BKE_pbvh_count_grid_quads | ( | BLI_bitmap ** | grid_hidden, |
const int * | grid_indices, | ||
int | totgrid, | ||
int | gridsize | ||
) |
Returns the number of visible quads in the nodes' grids.
Definition at line 339 of file pbvh.c.
References paint_is_grid_face_hidden(), x, and y.
Referenced by build_grid_leaf_node(), and GPU_pbvh_grid_buffers_update().
Definition at line 3250 of file pbvh.c.
References PBVH::draw_cache_invalid.
Referenced by mesh_batch_cache_valid().
void BKE_pbvh_draw_cb | ( | PBVH * | pbvh, |
bool | update_only_visible, | ||
PBVHFrustumPlanes * | update_frustum, | ||
PBVHFrustumPlanes * | draw_frustum, | ||
void(*)(void *user_data, struct GPU_PBVH_Buffers *buffers) | draw_fn, | ||
void * | user_data, | ||
bool | full_render | ||
) |
Referenced by drw_sculpt_generate_calls().
void BKE_pbvh_draw_debug_cb | ( | PBVH * | pbvh, |
void(*)(void *user_data, const float bmin[3], const float bmax[3], PBVHNodeFlags flag) | draw_fn, | ||
void * | user_data | ||
) |
Definition at line 2920 of file pbvh.c.
References Freestyle::a, node, PBVH::nodes, PBVH::totnode, and user_data.
Referenced by drw_sculpt_generate_calls().
Definition at line 3280 of file pbvh.c.
References BKE_pbvh_type(), BLI_assert, BLI_BITMAP_ENABLE, BLI_BITMAP_NEW, BLI_BITMAP_TEST, PBVH::looptri, MEM_malloc_arrayN, MEM_SAFE_FREE, node, PBVH::nodes, PBVH_FACES, PBVH_Leaf, PBVH::totnode, and MLoopTri::tri.
Referenced by do_brush_action(), SCULPT_filter_cache_init(), sculpt_mask_by_color_invoke(), and vpaint_invoke().
Definition at line 2843 of file pbvh.c.
References PBVH::face_sets_color_default, PBVH::face_sets_color_seed, and seed.
Referenced by sculpt_face_set_create_exec(), sculpt_face_sets_randomize_colors_exec(), and sculpt_update_object().
Definition at line 3236 of file pbvh.c.
References PBVH::face_sets.
Referenced by sculpt_update_object().
void BKE_pbvh_find_nearest_to_ray | ( | PBVH * | pbvh, |
BKE_pbvh_HitOccludedCallback | cb, | ||
void * | data, | ||
const float | ray_start[3], | ||
const float | ray_normal[3], | ||
bool | original | ||
) |
Definition at line 2593 of file pbvh.c.
References BKE_pbvh_search_callback_occluded(), data, FindNearestRayData::dist_ray_to_aabb_precalc, dist_squared_ray_to_aabb_v3_precalc(), nearest_to_ray_aabb_dist_sq(), and FindNearestRayData::original.
Referenced by SCULPT_stroke_get_location().
Definition at line 663 of file pbvh.c.
References BLI_gset_free(), PBVH::deformed, GPU_pbvh_buffers_free(), GPU_pbvh_free_format(), PBVH::looptri, MEM_freeN, MEM_SAFE_FREE, node, PBVH::nodes, NULL, PBVH_Leaf, pbvh_pixels_free(), PBVH::prim_indices, PBVH::totnode, PBVH::vbo_id, PBVH::vert_bitmap, and PBVH::verts.
Referenced by multires_force_sculpt_rebuild(), SCULPT_pbvh_clear(), and sculptsession_free_pbvh().
Definition at line 3050 of file pbvh.c.
References MEM_freeN, MEM_recallocN_id, node, PBVH::nodes, NULL, and PBVH::totnode.
Referenced by sculpt_combine_proxies(), and SCULPT_combine_transform_proxies().
Only valid for type == PBVH_BMESH.
Definition at line 1861 of file pbvh.c.
References BLI_assert, PBVH::bm, PBVH_BMESH, and PBVH::type.
Referenced by partialvis_update_bmesh(), SCULPT_vertex_co_get(), SCULPT_vertex_count_get(), SCULPT_vertex_mask_get(), and SCULPT_vertex_normal_get().
bool BKE_pbvh_get_color_layer | ( | const struct Mesh * | me, |
CustomDataLayer ** | r_layer, | ||
eAttrDomain * | r_attr | ||
) |
Referenced by sculpt_update_object().
void BKE_pbvh_get_frustum_planes | ( | PBVH * | pbvh, |
PBVHFrustumPlanes * | planes | ||
) |
Definition at line 3203 of file pbvh.c.
References copy_v4_v4(), PBVHFrustumPlanes::num_planes, PBVH::num_planes, PBVHFrustumPlanes::planes, and PBVH::planes.
Referenced by drw_sculpt_generate_calls().
Multi-res level, only valid for type == PBVH_GRIDS.
Definition at line 1831 of file pbvh.c.
References BLI_assert, PBVH::gridkey, PBVH_GRIDS, and PBVH::type.
Referenced by partialvis_update_grids(), pbvh_grids_node_visibility_update(), sculpt_expand_grids_to_faces_falloff(), SCULPT_vertex_all_face_sets_visible_get(), SCULPT_vertex_co_get(), SCULPT_vertex_face_set_get(), SCULPT_vertex_face_set_set(), SCULPT_vertex_has_face_set(), SCULPT_vertex_has_unique_face_set(), SCULPT_vertex_is_boundary(), SCULPT_vertex_limit_surface_get(), SCULPT_vertex_mask_get(), sculpt_vertex_neighbors_get_grids(), SCULPT_vertex_normal_get(), and SCULPT_vertex_visible_get().
int BKE_pbvh_get_grid_num_faces | ( | const PBVH * | pbvh | ) |
Definition at line 1855 of file pbvh.c.
References BLI_assert, CCGKey::grid_size, PBVH::gridkey, PBVH_GRIDS, PBVH::totgrid, and PBVH::type.
Referenced by stats_object_sculpt().
int BKE_pbvh_get_grid_num_vertices | ( | const PBVH * | pbvh | ) |
Definition at line 1849 of file pbvh.c.
References BLI_assert, CCGKey::grid_area, PBVH::gridkey, PBVH_GRIDS, PBVH::totgrid, and PBVH::type.
Referenced by SCULPT_vertex_count_get(), and stats_object_sculpt().
Definition at line 1751 of file pbvh.c.
References BLI_gset_add(), BLI_gset_free(), BLI_gset_len(), BLI_gset_ptr_new(), BLI_gsetIterator_getKey(), clear(), faces, PBVH::gridfaces, GSET_ITER_INDEX, MEM_mallocN, node, NULL, pbvh_iter_begin(), pbvh_iter_end(), pbvh_iter_next(), and PBVH_UpdateNormals.
Referenced by BKE_pbvh_update_normals(), and multires_stitch_grids().
BLI_bitmap** BKE_pbvh_get_grid_visibility | ( | const PBVH * | pbvh | ) |
Definition at line 1843 of file pbvh.c.
References BLI_assert, PBVH::grid_hidden, PBVH_GRIDS, and PBVH::type.
Referenced by SCULPT_vertex_visible_get().
Definition at line 1837 of file pbvh.c.
References BLI_assert, PBVH::grids, PBVH_GRIDS, and PBVH::type.
Referenced by SCULPT_vertex_co_get(), SCULPT_vertex_mask_get(), and SCULPT_vertex_normal_get().
Definition at line 3225 of file pbvh.c.
References BLI_assert, PBVH_FACES, PBVH::type, and PBVH::vert_normals.
Referenced by SCULPT_vertex_normal_get().
Definition at line 3219 of file pbvh.c.
References BLI_assert, PBVH_FACES, PBVH::type, and PBVH::verts.
Referenced by SCULPT_mesh_deformed_mverts_get(), SCULPT_vertex_co_for_grab_active_get(), and SCULPT_vertex_co_get().
unsigned int** BKE_pbvh_grid_hidden | ( | const PBVH * | pbvh | ) |
Multi-res hidden data, only valid for type == PBVH_GRIDS.
Definition at line 1825 of file pbvh.c.
References BLI_assert, PBVH::grid_hidden, PBVH_GRIDS, and PBVH::type.
Referenced by partialvis_update_grids(), pbvh_grids_node_visibility_update(), and sculpt_undo_alloc_and_store_hidden().
void BKE_pbvh_grids_update | ( | PBVH * | pbvh, |
struct CCGElem ** | grids, | ||
void ** | gridfaces, | ||
struct DMFlagMat * | flagmats, | ||
unsigned int ** | grid_hidden | ||
) |
Definition at line 2932 of file pbvh.c.
References Freestyle::a, BKE_pbvh_node_mark_rebuild_draw(), PBVH::grid_flag_mats, PBVH::grid_hidden, PBVH::gridfaces, PBVH::grids, PBVH::nodes, and PBVH::totnode.
Referenced by BKE_sculpt_bvh_update_from_ccg().
Definition at line 1803 of file pbvh.c.
References PBVH::bm, PBVH_BMESH, BMesh::totface, PBVH::totprim, and PBVH::type.
Definition at line 3010 of file pbvh.c.
References PBVH::deformed.
Referenced by sculpt_update_object().
Definition at line 3245 of file pbvh.c.
References PBVH::is_drawing.
Referenced by mesh_batch_cache_init(), and mesh_batch_cache_valid().
Definition at line 3255 of file pbvh.c.
References PBVH::is_drawing.
Referenced by workbench_color_type_get().
Definition at line 1885 of file pbvh.c.
References node, PBVH::nodes, PBVH_Leaf, PBVH_RebuildPixels, and PBVH::totnode.
Referenced by sculpt_update_object().
Definition at line 655 of file pbvh.c.
References PBVH::draw_cache_invalid, MEM_callocN, and PBVH::respect_hide.
Referenced by build_pbvh_for_dynamic_topology(), build_pbvh_from_ccg(), and build_pbvh_from_regular_mesh().
PBVHProxyNode* BKE_pbvh_node_add_proxy | ( | PBVH * | pbvh, |
PBVHNode * | node | ||
) |
Definition at line 3016 of file pbvh.c.
References BKE_pbvh_node_num_verts(), MEM_callocN, MEM_mallocN, MEM_reallocN, node, and NULL.
Referenced by do_clay_brush_task_cb_ex(), do_clay_strips_brush_task_cb_ex(), do_clay_thumb_brush_task_cb_ex(), do_crease_brush_task_cb_ex(), do_displacement_eraser_brush_task_cb_ex(), do_draw_brush_task_cb_ex(), do_draw_sharp_brush_task_cb_ex(), do_elastic_deform_brush_task_cb_ex(), do_fill_brush_task_cb_ex(), do_flatten_brush_task_cb_ex(), do_grab_brush_task_cb_ex(), do_gravity_task_cb_ex(), do_inflate_brush_task_cb_ex(), do_multiplane_scrape_brush_task_cb_ex(), do_nudge_brush_task_cb_ex(), do_pinch_brush_task_cb_ex(), do_rotate_brush_task_cb_ex(), do_scrape_brush_task_cb_ex(), do_snake_hook_brush_task_cb_ex(), do_thumb_brush_task_cb_ex(), do_topology_relax_task_cb_ex(), do_topology_slide_task_cb_ex(), and sculpt_elastic_transform_task_cb().
Definition at line 3088 of file pbvh.c.
References BKE_pbvh_search_gather(), MEM_SAFE_FREE, and NULL.
Referenced by paint_mesh_restore_co(), and sculpt_stroke_done().
PBVHColorBufferNode* BKE_pbvh_node_color_buffer_get | ( | PBVHNode * | node | ) |
Definition at line 3079 of file pbvh.c.
References MEM_callocN, and node.
Referenced by do_paint_brush_task_cb_ex().
bool BKE_pbvh_node_find_nearest_to_ray | ( | PBVH * | pbvh, |
PBVHNode * | node, | ||
float(*) | origco[3], | ||
bool | use_origco, | ||
const float | ray_start[3], | ||
const float | ray_normal[3], | ||
float * | depth, | ||
float * | dist_sq | ||
) |
Definition at line 2717 of file pbvh.c.
References node, PBVH_BMESH, pbvh_bmesh_node_nearest_to_ray(), PBVH_FACES, pbvh_faces_node_nearest_to_ray(), PBVH_FullyHidden, PBVH_GRIDS, pbvh_grids_node_nearest_to_ray(), and PBVH::type.
Referenced by sculpt_find_nearest_to_ray_cb().
Test if AABB is at least partially inside the PBVHFrustumPlanes volume.
Definition at line 2793 of file pbvh.c.
References data, ISECT_OUTSIDE, node, and test_frustum_aabb().
Referenced by get_pbvh_nodes(), pbvh_draw_search_cb(), sculpt_gesture_update_effected_nodes_by_clip_planes(), and sculpt_gesture_update_effected_nodes_by_line_plane().
Test if AABB is at least partially outside the PBVHFrustumPlanes volume.
Definition at line 2803 of file pbvh.c.
References data, ISECT_INSIDE, node, and test_frustum_aabb().
Referenced by get_pbvh_nodes().
Definition at line 1928 of file pbvh.c.
References node, PBVH_FullyHidden, and PBVH_Leaf.
Referenced by SCULPT_search_sphere_cb().
Definition at line 1916 of file pbvh.c.
References BLI_assert, node, PBVH_FullyHidden, and PBVH_Leaf.
Referenced by build_grid_leaf_node(), build_mesh_leaf_node(), partialvis_update_bmesh(), partialvis_update_grids(), partialvis_update_mesh(), pbvh_bmesh_create_nodes_fast_recursive(), pbvh_bmesh_node_finalize(), pbvh_bmesh_node_visibility_update(), pbvh_faces_node_visibility_update(), pbvh_grids_node_visibility_update(), pbvh_update_visibility_redraw_task_cb(), update_cb(), and update_cb_partial().
Definition at line 1945 of file pbvh.c.
References node, PBVH_FullyMasked, and PBVH_Leaf.
Referenced by SCULPT_search_circle_cb(), and SCULPT_search_sphere_cb().
Definition at line 1933 of file pbvh.c.
References BLI_assert, node, PBVH_FullyMasked, and PBVH_Leaf.
Referenced by pbvh_update_mask_redraw_task_cb().
Definition at line 1962 of file pbvh.c.
References node, PBVH_FullyUnmasked, and PBVH_Leaf.
Definition at line 1950 of file pbvh.c.
References BLI_assert, node, PBVH_FullyUnmasked, and PBVH_Leaf.
Referenced by pbvh_update_mask_redraw_task_cb().
Definition at line 2084 of file pbvh.c.
References copy_v3_v3(), and node.
Referenced by BKE_pbvh_raycast_project_ray_root(), SCULPT_search_circle_cb(), and SCULPT_search_sphere_cb().
void BKE_pbvh_node_get_bm_orco_data | ( | PBVHNode * | node, |
int(**) | r_orco_tris[3], | ||
int * | r_orco_tris_num, | ||
float(**) | r_orco_coords[3] | ||
) |
Definition at line 2116 of file pbvh.c.
References node.
Referenced by calc_area_normal_and_center_task_cb().
void BKE_pbvh_node_get_grids | ( | PBVH * | pbvh, |
PBVHNode * | node, | ||
int ** | grid_indices, | ||
int * | totgrid, | ||
int * | maxgrid, | ||
int * | gridsize, | ||
struct CCGElem *** | r_griddata | ||
) |
Definition at line 2037 of file pbvh.c.
References CCGKey::grid_size, PBVH::gridkey, PBVH::grids, node, NULL, PBVH_BMESH, PBVH_FACES, PBVH_GRIDS, PBVH::totgrid, and PBVH::type.
Referenced by partialvis_update_grids(), pbvh_grids_node_visibility_update(), pbvh_vertex_iter_init(), sculpt_undo_alloc_and_store_hidden(), sculpt_undo_alloc_node(), SCULPT_undo_push_node(), and update_cb_partial().
void BKE_pbvh_node_get_loops | ( | PBVH * | pbvh, |
PBVHNode * | node, | ||
const int ** | r_loop_indices, | ||
const struct MLoop ** | r_loops | ||
) |
Referenced by SCULPT_undo_push_node().
Definition at line 2090 of file pbvh.c.
References copy_v3_v3(), and node.
Referenced by BKE_pbvh_raycast_project_ray_root(), SCULPT_search_circle_cb(), and SCULPT_search_sphere_cb().
void BKE_pbvh_node_get_proxies | ( | PBVHNode * | node, |
PBVHProxyNode ** | proxies, | ||
int * | proxy_count | ||
) |
Definition at line 2096 of file pbvh.c.
Referenced by sculpt_combine_proxies_task_cb().
Definition at line 949 of file pbvh.c.
References node.
Referenced by sculpt_find_nearest_to_ray_cb(), sculpt_raycast_cb(), and sculpt_raycast_detail_cb().
void BKE_pbvh_node_get_verts | ( | PBVH * | pbvh, |
PBVHNode * | node, | ||
const int ** | r_vert_indices, | ||
struct MVert ** | r_verts | ||
) |
Definition at line 1989 of file pbvh.c.
References node, and PBVH::verts.
Referenced by partialvis_update_mesh(), pbvh_faces_node_visibility_update(), pbvh_vertex_iter_init(), SCULPT_undo_push_node(), sculpt_undo_store_hidden(), and update_cb_partial().
Definition at line 2126 of file pbvh.c.
References BLI_assert, node, PBVH_FACES, PBVH::type, v, PBVH::vert_bitmap, and verts.
Referenced by update_cb_partial().
Definition at line 1911 of file pbvh.c.
References node, and PBVH_UpdateNormals.
Referenced by mask_flood_fill_task_cb(), mask_gesture_apply_task_cb(), and SCULPT_filter_cache_init().
Definition at line 1901 of file pbvh.c.
References node, PBVH_RebuildDrawBuffers, PBVH_UpdateDrawBuffers, and PBVH_UpdateRedraw.
Referenced by BKE_pbvh_grids_update(), build_grid_leaf_node(), build_mesh_leaf_node(), partialvis_update_bmesh(), partialvis_update_grids(), partialvis_update_mesh(), pbvh_bmesh_create_nodes_fast_recursive(), and pbvh_bmesh_node_finalize().
Definition at line 1906 of file pbvh.c.
References node, PBVH_UpdateDrawBuffers, and PBVH_UpdateRedraw.
Referenced by do_brush_action_task_cb(), sculpt_expand_face_sets_update(), sculpt_expand_restore_color_data(), sculpt_expand_restore_face_set_data(), sculpt_expand_restore_mask_data(), sculpt_expand_task_cb(), sculpt_face_set_create_exec(), sculpt_face_sets_randomize_colors_exec(), sculpt_mask_expand_cancel(), sculpt_mask_expand_invoke(), sculpt_mask_expand_modal(), and sculpt_undo_bmesh_restore_generic_task_cb().
Definition at line 2098 of file pbvh_bmesh.c.
References node, and PBVH_UpdateTopology.
Referenced by sculpt_detail_flood_fill_exec(), and sculpt_topology_update().
Definition at line 1869 of file pbvh.c.
References node, PBVH_RebuildPixels, PBVH_UpdateBB, PBVH_UpdateDrawBuffers, PBVH_UpdateNormals, PBVH_UpdateOriginalBB, and PBVH_UpdateRedraw.
Referenced by BKE_pbvh_vert_coords_apply(), BKE_sculpt_update_object_before_eval(), cloth_filter_apply_forces_task_cb(), do_brush_action_task_cb(), mesh_filter_task_cb(), paint_mesh_restore_co_task_cb(), project_line_gesture_apply_task_cb(), sculpt_elastic_transform_task_cb(), sculpt_face_set_edit_modify_coordinates(), sculpt_topology_update(), sculpt_transform_task_cb(), update_cb(), and update_cb_partial().
Definition at line 1880 of file pbvh.c.
References node, PBVH_UpdateColor, PBVH_UpdateDrawBuffers, and PBVH_UpdateRedraw.
Referenced by color_filter_task_cb(), do_brush_action_task_cb(), paint_mesh_restore_co_task_cb(), sculpt_expand_colors_update_task_cb(), and update_cb_partial().
Definition at line 1875 of file pbvh.c.
References node, PBVH_UpdateDrawBuffers, PBVH_UpdateMask, and PBVH_UpdateRedraw.
Referenced by dirty_mask_apply_task_cb(), do_brush_action_task_cb(), do_mask_by_color_contiguous_update_nodes_cb(), do_mask_by_color_task_cb(), mask_filter_task_cb(), mask_flood_fill_task_cb(), mask_gesture_apply_task_cb(), mask_init_task_cb(), paint_mesh_restore_co_task_cb(), sculpt_expand_finish(), sculpt_expand_mask_update_task_cb(), sculpt_expand_task_cb(), update_cb(), and update_cb_partial().
Definition at line 1895 of file pbvh.c.
References node, PBVH_RebuildDrawBuffers, PBVH_UpdateDrawBuffers, PBVH_UpdateRedraw, and PBVH_UpdateVisibility.
Referenced by face_set_edit_do_post_visibility_updates(), face_set_gesture_apply_task_cb(), sculpt_face_set_init_exec(), sculpt_face_sets_change_visibility_exec(), update_cb(), and update_cb_partial().
Definition at line 3260 of file pbvh.c.
References BKE_pbvh_type(), BLI_assert, node, PBVH_FACES, and UNUSED_VARS.
Referenced by sculpt_undo_alloc_node(), and SCULPT_undo_push_node().
Definition at line 2003 of file pbvh.c.
References BLI_gset_len(), CCGKey::grid_area, PBVH::gridkey, node, PBVH_BMESH, PBVH_FACES, PBVH_GRIDS, and PBVH::type.
Referenced by BKE_pbvh_node_add_proxy(), partialvis_update_mesh(), pbvh_faces_node_visibility_update(), pbvh_vertex_iter_init(), sculpt_undo_alloc_node(), SCULPT_undo_push_node(), sculpt_undo_store_color(), sculpt_undo_store_hidden(), and update_cb_partial().
bool BKE_pbvh_node_raycast | ( | PBVH * | pbvh, |
PBVHNode * | node, | ||
float(*) | origco[3], | ||
bool | use_origco, | ||
const float | ray_start[3], | ||
const float | ray_normal[3], | ||
struct IsectRayPrecalc * | isect_precalc, | ||
float * | depth, | ||
int * | active_vertex_index, | ||
int * | active_face_grid_index, | ||
float * | face_normal | ||
) |
Definition at line 2457 of file pbvh.c.
References PBVH::bm, BM_mesh_elem_index_ensure(), BM_VERT, node, PBVH_BMESH, pbvh_bmesh_node_raycast(), PBVH_FACES, pbvh_faces_node_raycast(), PBVH_FullyHidden, PBVH_GRIDS, pbvh_grids_node_raycast(), and PBVH::type.
Referenced by sculpt_raycast_cb().
void BKE_pbvh_parallel_range_settings | ( | struct TaskParallelSettings * | settings, |
bool | use_threading, | ||
int | totnode | ||
) |
Definition at line 3211 of file pbvh.c.
References TaskParallelSettings::use_threading.
Referenced by calculate_average_weight(), cloth_brush_apply_brush_foces(), do_brush_action(), do_gravity(), mask_flood_fill_exec(), paint_mesh_restore_co(), pbvh_faces_update_normals(), pbvh_update_BB_redraw(), pbvh_update_draw_buffers(), pbvh_update_mask_redraw(), pbvh_update_visibility(), pbvh_update_visibility_redraw(), SCULPT_bmesh_topology_rake(), SCULPT_calc_area_center(), SCULPT_calc_area_normal_and_center(), SCULPT_cloth_brush_do_simulation_step(), SCULPT_cloth_brush_ensure_nodes_constraints(), sculpt_cloth_filter_modal(), sculpt_color_filter_modal(), sculpt_combine_proxies(), SCULPT_combine_transform_proxies(), sculpt_dirty_mask_exec(), SCULPT_do_boundary_brush(), SCULPT_do_clay_brush(), SCULPT_do_clay_strips_brush(), SCULPT_do_clay_thumb_brush(), SCULPT_do_crease_brush(), SCULPT_do_displacement_eraser_brush(), SCULPT_do_displacement_smear_brush(), SCULPT_do_draw_brush(), SCULPT_do_draw_face_sets_brush(), SCULPT_do_draw_sharp_brush(), SCULPT_do_elastic_deform_brush(), SCULPT_do_fill_brush(), SCULPT_do_flatten_brush(), SCULPT_do_grab_brush(), SCULPT_do_inflate_brush(), SCULPT_do_layer_brush(), SCULPT_do_mask_brush_draw(), SCULPT_do_multiplane_scrape_brush(), SCULPT_do_nudge_brush(), SCULPT_do_paint_brush(), SCULPT_do_paint_brush_image(), SCULPT_do_pinch_brush(), SCULPT_do_pose_brush(), SCULPT_do_rotate_brush(), SCULPT_do_scrape_brush(), SCULPT_do_slide_relax_brush(), SCULPT_do_smear_brush(), SCULPT_do_snake_hook_brush(), SCULPT_do_surface_smooth_brush(), SCULPT_do_thumb_brush(), SCULPT_enhance_details_brush(), sculpt_expand_update_for_vertex(), SCULPT_fake_neighbor_search(), SCULPT_filter_cache_init(), SCULPT_flush_stroke_deform(), sculpt_gesture_face_set_apply_for_symmetry_pass(), sculpt_gesture_mask_apply_for_symmetry_pass(), sculpt_gesture_project_apply_for_symmetry_pass(), sculpt_mask_by_color_contiguous(), sculpt_mask_by_color_full_mesh(), sculpt_mask_expand_invoke(), sculpt_mask_expand_modal(), sculpt_mask_filter_exec(), SCULPT_mask_filter_smooth_apply(), sculpt_mask_init_exec(), sculpt_mesh_filter_modal(), SCULPT_nearest_vertex_get(), SCULPT_pbvh_calc_area_normal(), SCULPT_pose_brush_init(), sculpt_pose_grow_pose_factor(), SCULPT_smooth(), sculpt_transform_all_vertices(), sculpt_transform_radius_elastic(), sculpt_undo_bmesh_restore_generic(), blender::bke::pbvh::pixels::update_pixels(), and wpaint_paint_leaves().
void BKE_pbvh_pmap_set | ( | PBVH * | pbvh, |
const struct MeshElemMap * | pmap | ||
) |
Referenced by BKE_sculpt_object_pbvh_ensure(), and sculpt_update_object().
void BKE_pbvh_raycast | ( | PBVH * | pbvh, |
BKE_pbvh_HitOccludedCallback | cb, | ||
void * | data, | ||
const float | ray_start[3], | ||
const float | ray_normal[3], | ||
bool | original | ||
) |
Definition at line 2169 of file pbvh.c.
References BKE_pbvh_search_callback_occluded(), data, isect_ray_aabb_v3_precalc(), RaycastData::original, RaycastData::ray, and ray_aabb_intersect().
Referenced by sample_detail_dyntopo(), SCULPT_cursor_geometry_info_update(), and SCULPT_stroke_get_location().
void BKE_pbvh_raycast_project_ray_root | ( | PBVH * | pbvh, |
bool | original, | ||
float | ray_start[3], | ||
float | ray_end[3], | ||
float | ray_normal[3] | ||
) |
For orthographic cameras, project the far away ray segment points to the root node so we can have better precision.
Definition at line 2516 of file pbvh.c.
References add_v3_v3(), BKE_pbvh_node_get_BB(), BKE_pbvh_node_get_original_BB(), isect_ray_aabb_v3(), isect_ray_aabb_v3_precalc(), madd_v3_v3v3fl(), mid_v3_v3v3(), mul_v3_v3fl(), PBVH::nodes, offset, and sub_v3_v3v3().
Referenced by SCULPT_raycast_init().
Definition at line 1729 of file pbvh.c.
References BB_expand_with_bb(), BB_reset(), BB::bmax, BB::bmin, copy_v3_v3(), node, NULL, pbvh_iter_begin(), pbvh_iter_end(), pbvh_iter_next(), and PBVH_UpdateRedraw.
Referenced by SCULPT_get_redraw_rect().
Definition at line 3241 of file pbvh.c.
References PBVH::respect_hide.
Referenced by build_pbvh_from_ccg(), and build_pbvh_from_regular_mesh().
void BKE_pbvh_search_callback | ( | PBVH * | pbvh, |
BKE_pbvh_SearchCallback | scb, | ||
void * | search_data, | ||
BKE_pbvh_HitCallback | hcb, | ||
void * | hit_data | ||
) |
Definition at line 871 of file pbvh.c.
References node, pbvh_iter_begin(), pbvh_iter_end(), pbvh_iter_next(), and PBVH_Leaf.
Referenced by sculpt_undo_restore_list().
void BKE_pbvh_search_gather | ( | PBVH * | pbvh, |
BKE_pbvh_SearchCallback | scb, | ||
void * | search_data, | ||
PBVHNode *** | array, | ||
int * | tot | ||
) |
Definition at line 838 of file pbvh.c.
References MEM_freeN, MEM_recallocN_id, node, NULL, pbvh_iter_begin(), pbvh_iter_end(), pbvh_iter_next(), PBVH_Leaf, and UNLIKELY.
Referenced by BKE_pbvh_draw_cb(), BKE_pbvh_node_color_buffer_free(), BKE_pbvh_update_bounds(), BKE_pbvh_update_normals(), BKE_pbvh_update_vertex_data(), BKE_pbvh_update_visibility(), BKE_sculpt_update_object_before_eval(), cloth_sim_initialize_default_node_state(), do_brush_action(), get_pbvh_nodes(), mask_flood_fill_exec(), paint_mesh_restore_co(), SCULPT_cloth_brush_affected_nodes_gather(), sculpt_detail_flood_fill_exec(), sculpt_dirty_mask_exec(), sculpt_expand_finish(), sculpt_expand_invoke(), sculpt_expand_restore_color_data(), sculpt_expand_restore_face_set_data(), sculpt_expand_restore_mask_data(), sculpt_expand_undo_push(), sculpt_face_set_create_exec(), sculpt_face_set_edit_modify_coordinates(), sculpt_face_set_edit_modify_face_sets(), sculpt_face_set_init_exec(), sculpt_face_sets_change_visibility_exec(), sculpt_face_sets_randomize_colors_exec(), SCULPT_fake_neighbor_search(), SCULPT_filter_cache_init(), SCULPT_flush_stroke_deform(), sculpt_gesture_update_effected_nodes_by_clip_planes(), sculpt_gesture_update_effected_nodes_by_line_plane(), sculpt_mask_by_color_contiguous(), sculpt_mask_by_color_full_mesh(), sculpt_mask_expand_invoke(), sculpt_mask_filter_exec(), sculpt_mask_init_exec(), SCULPT_nearest_vertex_get(), sculpt_pbvh_gather_cursor_update(), sculpt_pbvh_gather_generic(), SCULPT_pose_brush_init(), sculpt_pose_grow_pose_factor(), sculpt_set_pivot_position_exec(), sculpt_undo_bmesh_restore_generic(), sculpt_undo_push_all_grids(), and vwpaint_pbvh_gather_generic().
void BKE_pbvh_set_frustum_planes | ( | PBVH * | pbvh, |
PBVHFrustumPlanes * | planes | ||
) |
Definition at line 3195 of file pbvh.c.
References copy_v4_v4(), PBVHFrustumPlanes::num_planes, PBVH::num_planes, PBVHFrustumPlanes::planes, and PBVH::planes.
Referenced by drw_sculpt_generate_calls().
void BKE_pbvh_store_colors | ( | PBVH * | pbvh, |
const int * | indices, | ||
const int | indices_num, | ||
float(*) | colors[4] | ||
) |
Definition at line 179 of file pbvh.cc.
References PBVH::color_layer, blender::bke::to_static_color_type(), and CustomDataLayer::type.
Referenced by BKE_pbvh_store_colors_vertex(), and sculpt_undo_store_color().
void BKE_pbvh_store_colors_vertex | ( | PBVH * | pbvh, |
const int * | indices, | ||
const int | indices_num, | ||
float(*) | colors[4] | ||
) |
Definition at line 193 of file pbvh.cc.
References ATTR_DOMAIN_POINT, BKE_pbvh_store_colors(), PBVH::color_domain, PBVH::color_layer, indices, blender::bke::to_static_color_type(), and CustomDataLayer::type.
Referenced by sculpt_undo_store_color().
Definition at line 3231 of file pbvh.c.
References PBVH::subdiv_ccg.
Referenced by sculpt_update_object().
void BKE_pbvh_swap_colors | ( | PBVH * | pbvh, |
const int * | indices, | ||
const int | indices_num, | ||
float(*) | colors[4] | ||
) |
Definition at line 163 of file pbvh.cc.
References PBVH::color_layer, blender::bke::to_static_color_type(), and CustomDataLayer::type.
Referenced by sculpt_undo_restore_color().
Definition at line 371 of file pbvh.c.
References BKE_subdiv_ccg_grid_to_face_index(), BLI_BITMAP_NEW, BLI_BITMAP_SET, PBVH::face_sets, CCGKey::grid_area, PBVH::grid_hidden, CCGKey::grid_size, PBVH::gridkey, PBVH::subdiv_ccg, PBVH::totgrid, x, and y.
Definition at line 1798 of file pbvh.c.
References PBVH::type.
Referenced by BKE_pbvh_ensure_node_loops(), BKE_pbvh_node_get_loops(), BKE_pbvh_node_num_loops(), BKE_sculpt_object_pbvh_ensure(), BKE_sculptsession_use_pbvh_draw(), calculate_average_color(), do_brush_action(), do_draw_face_sets_brush_task_cb_ex(), do_vpaint_brush_blur_loops(), do_vpaint_brush_blur_verts(), do_vpaint_brush_smear(), do_wpaint_brush_blur_task_cb_ex(), do_wpaint_brush_calc_average_weight_cb_ex(), do_wpaint_brush_draw_task_cb_ex(), do_wpaint_brush_smear_task_cb_ex(), face_set_edit_do_post_visibility_updates(), hide_show_exec(), mask_flood_fill_exec(), mask_gesture_apply_task_cb(), multires_flush_sculpt_updates(), multires_stitch_grids(), paint_cursor_sculpt_session_update_and_init(), pbvh_update_visibility_task_cb(), sample_detail(), SCULPT_active_face_set_get(), SCULPT_active_vertex_get(), sculpt_boundary_edit_data_init(), sculpt_color_filter_invoke(), sculpt_colors_poll(), SCULPT_cursor_geometry_info_update(), sculpt_expand_active_face_set_id_get(), sculpt_expand_diagonals_falloff_create(), sculpt_expand_falloff_factors_from_vertex_and_symm_create(), sculpt_expand_geodesics_from_state_boundary(), sculpt_expand_initialize_from_face_set_boundary(), sculpt_expand_invoke(), sculpt_expand_mesh_face_falloff_from_vertex_falloff(), sculpt_expand_resursion_step_add(), sculpt_expand_snap_initialize_from_enabled(), sculpt_face_set_create_exec(), sculpt_face_set_edit_is_operation_valid(), sculpt_face_set_init_exec(), SCULPT_face_set_next_available_get(), SCULPT_face_set_visibility_set(), sculpt_face_sets_automasking_init(), sculpt_face_sets_change_visibility_exec(), sculpt_face_sets_randomize_colors_exec(), SCULPT_face_sets_visibility_all_set(), SCULPT_face_sets_visibility_invert(), SCULPT_filter_cache_init(), sculpt_find_nearest_to_ray_cb(), SCULPT_flush_update_done(), SCULPT_geodesic_distances_create(), sculpt_geometry_preview_lines_draw(), SCULPT_geometry_preview_lines_update(), sculpt_gesture_mask_end(), SCULPT_handles_colors_report(), SCULPT_mesh_deformed_mverts_get(), sculpt_no_multires_poll(), sculpt_raycast_cb(), SCULPT_smooth(), SCULPT_stroke_get_location(), SCULPT_stroke_is_dynamic_topology(), sculpt_symmetrize_exec(), SCULPT_topology_automasking_init(), sculpt_topology_update(), sculpt_trim_gesture_box_exec(), sculpt_trim_gesture_lasso_exec(), sculpt_undo_restore_list(), sculpt_undo_store_color(), SCULPT_vertex_all_face_sets_visible_get(), SCULPT_vertex_any_face_set_visible_get(), SCULPT_vertex_co_get(), SCULPT_vertex_count_get(), SCULPT_vertex_face_set_get(), SCULPT_vertex_face_set_set(), SCULPT_vertex_has_face_set(), SCULPT_vertex_has_unique_face_set(), SCULPT_vertex_is_boundary(), SCULPT_vertex_limit_surface_get(), SCULPT_vertex_mask_get(), SCULPT_vertex_neighbors_get(), SCULPT_vertex_normal_get(), SCULPT_vertex_random_access_ensure(), SCULPT_vertex_visible_get(), SCULPT_vertex_visible_set(), SCULPT_visibility_sync_all_face_sets_to_vertices(), SCULPT_visibility_sync_all_vertex_to_face_sets(), stats_object_sculpt(), update_cb_partial(), vpaint_do_draw(), and workbench_color_type_get().
Definition at line 1545 of file pbvh.c.
References BKE_pbvh_search_gather(), MEM_SAFE_FREE, PBVH::nodes, pbvh_flush_bb(), pbvh_update_BB_redraw(), PBVH_UpdateBB, PBVH_UpdateOriginalBB, PBVH_UpdateRedraw, POINTER_FROM_INT, and update_search_cb().
Referenced by BKE_pbvh_vert_coords_apply(), ED_sculpt_redraw_planes_get(), SCULPT_flush_update_done(), SCULPT_flush_update_step(), sculpt_undo_restore_list(), and vwpaint_update_cache_variants().
Definition at line 2813 of file pbvh.c.
References BKE_pbvh_get_grid_updates(), BKE_pbvh_search_gather(), BKE_subdiv_ccg_update_normals(), faces, MEM_freeN, MEM_SAFE_FREE, PBVH_BMESH, pbvh_bmesh_normals_update(), PBVH_FACES, pbvh_faces_update_normals(), PBVH_GRIDS, PBVH_UpdateNormals, POINTER_FROM_INT, PBVH::type, and update_search_cb().
Referenced by DRW_mesh_batch_cache_create_requested(), drw_sculpt_generate_calls(), SCULPT_filter_cache_init(), and sculpt_mesh_filter_modal().
Definition at line 1567 of file pbvh.c.
References BKE_pbvh_search_gather(), PBVHNode::flag, MEM_freeN, PBVH::nodes, pbvh_update_mask_redraw(), pbvh_update_visibility_redraw(), PBVH_UpdateColor, PBVH_UpdateDrawBuffers, PBVH_UpdateMask, PBVH_UpdateRedraw, PBVH_UpdateVisibility, POINTER_FROM_INT, and update_search_cb().
Referenced by face_set_edit_do_post_visibility_updates(), mask_flood_fill_exec(), sculpt_dirty_mask_exec(), sculpt_face_set_init_exec(), sculpt_face_sets_change_visibility_exec(), SCULPT_flush_update_done(), sculpt_gesture_face_set_end(), sculpt_gesture_mask_end(), sculpt_mask_by_color_invoke(), sculpt_mask_init_exec(), sculpt_undo_restore_list(), and sculpt_undo_set_active_layer().
Definition at line 1711 of file pbvh.c.
References BKE_pbvh_search_gather(), MEM_freeN, PBVH::nodes, pbvh_update_visibility(), PBVH_UpdateVisibility, POINTER_FROM_INT, and update_search_cb().
Referenced by sculpt_undo_restore_list().
Definition at line 2948 of file pbvh.c.
References Freestyle::a, MVert::co, copy_v3_v3(), float(), MEM_callocN, NULL, PBVH::totvert, and PBVH::verts.
Referenced by sculpt_update_keyblock().
Definition at line 2966 of file pbvh.c.
References Freestyle::a, BKE_mesh_calc_normals_looptri(), BKE_pbvh_node_mark_update(), BKE_pbvh_update_bounds(), BKE_pbvh_vert_tag_update_normal(), BLI_assert_msg, MVert::co, copy_v3_v3(), PBVH::deformed, PBVH::looptri, MEM_dupallocN, PBVH::mloop, PBVH::nodes, NULL, PBVH_UpdateBB, PBVH_UpdateOriginalBB, PBVH::totnode, PBVH::totprim, PBVH::totvert, and PBVH::verts.
Referenced by build_pbvh_from_regular_mesh(), sculpt_undo_restore_coords(), and sculpt_update_object().
Definition at line 1967 of file pbvh.c.
References BLI_assert, PBVH_FACES, PBVH::type, and PBVH::vert_bitmap.
Referenced by BKE_pbvh_vert_coords_apply(), do_boundary_brush_bend_task_cb_ex(), do_boundary_brush_grab_task_cb_ex(), do_boundary_brush_inflate_task_cb_ex(), do_boundary_brush_slide_task_cb_ex(), do_boundary_brush_smooth_task_cb_ex(), do_boundary_brush_twist_task_cb_ex(), do_clay_brush_task_cb_ex(), do_clay_strips_brush_task_cb_ex(), do_clay_thumb_brush_task_cb_ex(), do_cloth_brush_solve_simulation_task_cb_ex(), do_crease_brush_task_cb_ex(), do_displacement_eraser_brush_task_cb_ex(), do_displacement_smear_brush_task_cb_ex(), do_draw_brush_task_cb_ex(), do_draw_sharp_brush_task_cb_ex(), do_elastic_deform_brush_task_cb_ex(), do_enhance_details_brush_task_cb_ex(), do_fill_brush_task_cb_ex(), do_flatten_brush_task_cb_ex(), do_grab_brush_task_cb_ex(), do_gravity_task_cb_ex(), do_inflate_brush_task_cb_ex(), do_layer_brush_task_cb_ex(), do_multiplane_scrape_brush_task_cb_ex(), do_nudge_brush_task_cb_ex(), do_pinch_brush_task_cb_ex(), do_pose_brush_task_cb_ex(), do_relax_face_sets_brush_task_cb_ex(), do_rotate_brush_task_cb_ex(), do_scrape_brush_task_cb_ex(), do_smooth_brush_task_cb_ex(), do_snake_hook_brush_task_cb_ex(), do_thumb_brush_task_cb_ex(), do_topology_rake_bmesh_task_cb_ex(), do_topology_relax_task_cb_ex(), do_topology_slide_task_cb_ex(), mesh_filter_task_cb(), paint_mesh_restore_co_task_cb(), project_line_gesture_apply_task_cb(), SCULPT_do_surface_smooth_brush_laplacian_task_cb_ex(), sculpt_elastic_transform_task_cb(), sculpt_transform_task_cb(), sculpt_undo_restore_coords(), and SCULPT_vertex_visible_set().
Definition at line 147 of file pbvh.cc.
References PBVH::color_layer, blender::bke::to_static_color_type(), and CustomDataLayer::type.
Referenced by SCULPT_vertex_color_get().
Definition at line 155 of file pbvh.cc.
References PBVH::color_layer, blender::bke::to_static_color_type(), and CustomDataLayer::type.
Referenced by SCULPT_vertex_color_set().
Definition at line 3171 of file pbvh.c.
References CD_SCULPT_FACE_SETS, CustomData_get_layer(), PBVH_BMESH, PBVH_FACES, PBVH_GRIDS, PBVH::pdata, and PBVH::type.
Referenced by OVERLAY_sculpt_cache_populate().
Definition at line 3157 of file pbvh.c.
References PBVH::bm, CD_PAINT_MASK, CustomData_get_layer(), CustomData_get_offset(), PBVH::gridkey, CCGKey::has_mask, PBVH_BMESH, PBVH_FACES, PBVH_GRIDS, PBVH::type, PBVH::vdata, and BMesh::vdata.
Referenced by OVERLAY_sculpt_cache_populate().
Definition at line 3190 of file pbvh.c.
References PBVH::show_face_sets.
Referenced by build_pbvh_for_dynamic_topology(), build_pbvh_from_ccg(), build_pbvh_from_regular_mesh(), and sculpt_update_object().
Definition at line 3185 of file pbvh.c.
References PBVH::show_mask.
Referenced by build_pbvh_for_dynamic_topology(), build_pbvh_from_ccg(), build_pbvh_from_regular_mesh(), and sculpt_update_object().
void pbvh_vertex_iter_init | ( | PBVH * | pbvh, |
PBVHNode * | node, | ||
PBVHVertexIter * | vi, | ||
int | mode | ||
) |
Definition at line 3099 of file pbvh.c.
References BKE_pbvh_node_get_grids(), BKE_pbvh_node_get_verts(), BKE_pbvh_node_num_verts(), BLI_gsetIterator_init(), PBVH::bm, PBVHVertexIter::bm_other_verts, PBVHVertexIter::bm_unique_verts, PBVHVertexIter::bm_vdata, CD_PAINT_MASK, PBVHVertexIter::cd_vert_mask_offset, CustomData_get_layer(), CustomData_get_offset(), PBVHVertexIter::fno, PBVHVertexIter::gh, PBVHVertexIter::grid, PBVHVertexIter::grid_hidden, PBVH::grid_hidden, PBVHVertexIter::grid_indices, PBVH::gridkey, PBVHVertexIter::grids, PBVHVertexIter::gridsize, PBVHVertexIter::key, PBVHVertexIter::mask, PBVHVertexIter::mvert, PBVHVertexIter::mverts, PBVHVertexIter::no, node, NULL, PBVH_BMESH, PBVH_FACES, PBVH_ITER_ALL, PBVH_ITER_UNIQUE, PBVHVertexIter::respect_hide, PBVH::respect_hide, PBVHVertexIter::totgrid, PBVHVertexIter::totvert, PBVH::type, PBVH::vdata, BMesh::vdata, PBVHVertexIter::vert_indices, PBVHVertexIter::vert_normals, PBVH::vert_normals, verts, PBVHVertexIter::visible, and PBVHVertexIter::vmask.