Blender  V3.3
Classes | Macros | Typedefs | Enumerations | Functions
BKE_pbvh.h File Reference

A BVH for high poly meshes. More...

#include "BLI_bitmap.h"
#include "BLI_ghash.h"
#include "BKE_attribute.h"
#include "BKE_ccg.h"

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 }
 

Functions

void BKE_pbvh_set_frustum_planes (PBVH *pbvh, PBVHFrustumPlanes *planes)
 
void BKE_pbvh_get_frustum_planes (PBVH *pbvh, PBVHFrustumPlanes *planes)
 
PBVH * BKE_pbvh_new (void)
 
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)
 
void BKE_pbvh_build_grids (PBVH *pbvh, struct CCGElem **grids, int totgrid, struct CCGKey *key, void **gridfaces, struct DMFlagMat *flagmats, unsigned int **grid_hidden)
 
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)
 
void BKE_pbvh_build_pixels (PBVH *pbvh, struct Mesh *mesh, struct Image *image, struct ImageUser *image_user)
 
void BKE_pbvh_free (PBVH *pbvh)
 
void BKE_pbvh_search_callback (PBVH *pbvh, BKE_pbvh_SearchCallback scb, void *search_data, BKE_pbvh_HitCallback hcb, void *hit_data)
 
void BKE_pbvh_search_gather (PBVH *pbvh, BKE_pbvh_SearchCallback scb, void *search_data, PBVHNode ***array, int *tot)
 
void BKE_pbvh_raycast (PBVH *pbvh, BKE_pbvh_HitOccludedCallback cb, void *data, const float ray_start[3], const float ray_normal[3], bool original)
 
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)
 
bool BKE_pbvh_bmesh_node_raycast_detail (PBVHNode *node, const float ray_start[3], struct IsectRayPrecalc *isect_precalc, float *depth, float *r_edge_length)
 
void BKE_pbvh_raycast_project_ray_root (PBVH *pbvh, bool original, float ray_start[3], float ray_end[3], float ray_normal[3])
 
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)
 
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)
 
void BKE_pbvh_draw_cb (PBVH *pbvh, bool update_only_visible, PBVHFrustumPlanes *update_frustum, PBVHFrustumPlanes *draw_frustum, void(*draw_fn)(void *user_data, struct GPU_PBVH_Buffers *buffers), void *user_data, bool full_render)
 
void BKE_pbvh_draw_debug_cb (PBVH *pbvh, void(*draw_fn)(void *user_data, const float bmin[3], const float bmax[3], PBVHNodeFlags flag), void *user_data)
 
PBVHType BKE_pbvh_type (const PBVH *pbvh)
 
bool BKE_pbvh_has_faces (const PBVH *pbvh)
 
void BKE_pbvh_bounding_box (const PBVH *pbvh, float min[3], float max[3])
 
unsigned int ** BKE_pbvh_grid_hidden (const PBVH *pbvh)
 
int BKE_pbvh_count_grid_quads (BLI_bitmap **grid_hidden, const int *grid_indices, int totgrid, int gridsize)
 
void BKE_pbvh_sync_face_sets_to_grids (PBVH *pbvh)
 
const struct CCGKey * BKE_pbvh_get_grid_key (const PBVH *pbvh)
 
struct CCGElem ** BKE_pbvh_get_grids (const PBVH *pbvh)
 
BLI_bitmap ** BKE_pbvh_get_grid_visibility (const PBVH *pbvh)
 
int BKE_pbvh_get_grid_num_vertices (const PBVH *pbvh)
 
int BKE_pbvh_get_grid_num_faces (const PBVH *pbvh)
 
struct BMesh * BKE_pbvh_get_bmesh (PBVH *pbvh)
 
void BKE_pbvh_bmesh_detail_size_set (PBVH *pbvh, float detail_size)
 
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)
 
void BKE_pbvh_node_mark_update (PBVHNode *node)
 
void BKE_pbvh_node_mark_update_mask (PBVHNode *node)
 
void BKE_pbvh_node_mark_update_color (PBVHNode *node)
 
void BKE_pbvh_node_mark_update_visibility (PBVHNode *node)
 
void BKE_pbvh_node_mark_rebuild_draw (PBVHNode *node)
 
void BKE_pbvh_node_mark_redraw (PBVHNode *node)
 
void BKE_pbvh_node_mark_normals_update (PBVHNode *node)
 
void BKE_pbvh_node_mark_topology_update (PBVHNode *node)
 
void BKE_pbvh_node_fully_hidden_set (PBVHNode *node, int fully_hidden)
 
bool BKE_pbvh_node_fully_hidden_get (PBVHNode *node)
 
void BKE_pbvh_node_fully_masked_set (PBVHNode *node, int fully_masked)
 
bool BKE_pbvh_node_fully_masked_get (PBVHNode *node)
 
void BKE_pbvh_node_fully_unmasked_set (PBVHNode *node, int fully_masked)
 
bool BKE_pbvh_node_fully_unmasked_get (PBVHNode *node)
 
void BKE_pbvh_mark_rebuild_pixels (PBVH *pbvh)
 
void BKE_pbvh_vert_tag_update_normal (PBVH *pbvh, int index)
 
void BKE_pbvh_node_get_grids (PBVH *pbvh, PBVHNode *node, int **grid_indices, int *totgrid, int *maxgrid, int *gridsize, struct CCGElem ***r_griddata)
 
void BKE_pbvh_node_num_verts (PBVH *pbvh, PBVHNode *node, int *r_uniquevert, int *r_totvert)
 
void BKE_pbvh_node_get_verts (PBVH *pbvh, PBVHNode *node, const int **r_vert_indices, struct MVert **r_verts)
 
void BKE_pbvh_node_get_loops (PBVH *pbvh, PBVHNode *node, const int **r_loop_indices, const struct MLoop **r_loops)
 
void BKE_pbvh_node_get_BB (PBVHNode *node, float bb_min[3], float bb_max[3])
 
void BKE_pbvh_node_get_original_BB (PBVHNode *node, float bb_min[3], float bb_max[3])
 
float BKE_pbvh_node_get_tmin (PBVHNode *node)
 
bool BKE_pbvh_node_frustum_contain_AABB (PBVHNode *node, void *frustum)
 
bool BKE_pbvh_node_frustum_exclude_AABB (PBVHNode *node, void *frustum)
 
struct GSet * BKE_pbvh_bmesh_node_unique_verts (PBVHNode *node)
 
struct GSet * BKE_pbvh_bmesh_node_other_verts (PBVHNode *node)
 
struct GSet * BKE_pbvh_bmesh_node_faces (PBVHNode *node)
 
void BKE_pbvh_bmesh_node_save_orig (struct BMesh *bm, PBVHNode *node)
 
void BKE_pbvh_bmesh_after_stroke (PBVH *pbvh)
 
void BKE_pbvh_update_bounds (PBVH *pbvh, int flags)
 
void BKE_pbvh_update_vertex_data (PBVH *pbvh, int flags)
 
void BKE_pbvh_update_visibility (PBVH *pbvh)
 
void BKE_pbvh_update_normals (PBVH *pbvh, struct SubdivCCG *subdiv_ccg)
 
void BKE_pbvh_redraw_BB (PBVH *pbvh, float bb_min[3], float bb_max[3])
 
void BKE_pbvh_get_grid_updates (PBVH *pbvh, bool clear, void ***r_gridfaces, int *r_totface)
 
void BKE_pbvh_grids_update (PBVH *pbvh, struct CCGElem **grids, void **gridfaces, struct DMFlagMat *flagmats, unsigned int **grid_hidden)
 
void BKE_pbvh_subdiv_cgg_set (PBVH *pbvh, struct SubdivCCG *subdiv_ccg)
 
void BKE_pbvh_face_sets_set (PBVH *pbvh, int *face_sets)
 
void BKE_pbvh_face_sets_color_set (PBVH *pbvh, int seed, int color_default)
 
void BKE_pbvh_respect_hide_set (PBVH *pbvh, bool respect_hide)
 
float(* BKE_pbvh_vert_coords_alloc (struct PBVH *pbvh))[3]
 
void BKE_pbvh_vert_coords_apply (struct PBVH *pbvh, const float(*vertCos)[3], int totvert)
 
bool BKE_pbvh_is_deformed (struct PBVH *pbvh)
 
void pbvh_vertex_iter_init (PBVH *pbvh, PBVHNode *node, PBVHVertexIter *vi, int mode)
 
void BKE_pbvh_node_get_proxies (PBVHNode *node, PBVHProxyNode **proxies, int *proxy_count)
 
void BKE_pbvh_node_free_proxies (PBVHNode *node)
 
PBVHProxyNode * BKE_pbvh_node_add_proxy (PBVH *pbvh, PBVHNode *node)
 
void BKE_pbvh_gather_proxies (PBVH *pbvh, PBVHNode ***r_array, int *r_tot)
 
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])
 
bool BKE_pbvh_node_has_vert_with_normal_update_tag (PBVH *pbvh, PBVHNode *node)
 
bool pbvh_has_mask (const PBVH *pbvh)
 
void pbvh_show_mask_set (PBVH *pbvh, bool show_mask)
 
bool pbvh_has_face_sets (PBVH *pbvh)
 
void pbvh_show_face_sets_set (PBVH *pbvh, bool show_face_sets)
 
void BKE_pbvh_parallel_range_settings (struct TaskParallelSettings *settings, bool use_threading, int totnode)
 
struct MVert * BKE_pbvh_get_verts (const PBVH *pbvh)
 
const float(* BKE_pbvh_get_vert_normals (const PBVH *pbvh))[3]
 
PBVHColorBufferNode * BKE_pbvh_node_color_buffer_get (PBVHNode *node)
 
void BKE_pbvh_node_color_buffer_free (PBVH *pbvh)
 
bool BKE_pbvh_get_color_layer (const struct Mesh *me, CustomDataLayer **r_layer, eAttrDomain *r_attr)
 
void BKE_pbvh_swap_colors (PBVH *pbvh, const int *indices, const int indices_num, float(*colors)[4])
 
void BKE_pbvh_store_colors (PBVH *pbvh, const int *indices, const int indices_num, float(*colors)[4])
 
void BKE_pbvh_store_colors_vertex (PBVH *pbvh, const int *indices, const int indices_num, float(*colors)[4])
 
bool BKE_pbvh_is_drawing (const PBVH *pbvh)
 
void BKE_pbvh_is_drawing_set (PBVH *pbvh, bool val)
 
void BKE_pbvh_node_num_loops (PBVH *pbvh, PBVHNode *node, int *r_totloop)
 
void BKE_pbvh_update_active_vcol (PBVH *pbvh, const struct Mesh *mesh)
 
void BKE_pbvh_pmap_set (PBVH *pbvh, const struct MeshElemMap *pmap)
 
void BKE_pbvh_vertex_color_set (PBVH *pbvh, int vertex, const float color[4])
 
void BKE_pbvh_vertex_color_get (const PBVH *pbvh, int vertex, float r_color[4])
 
void BKE_pbvh_ensure_node_loops (PBVH *pbvh)
 
bool BKE_pbvh_draw_cache_invalid (const PBVH *pbvh)
 

Detailed Description

A BVH for high poly meshes.

Definition in file BKE_pbvh.h.

Macro Definition Documentation

◆ BKE_pbvh_vertex_iter_begin

#define BKE_pbvh_vertex_iter_begin (   pbvh,
  node,
  vi,
  mode 
)

Definition at line 439 of file BKE_pbvh.h.

◆ BKE_pbvh_vertex_iter_end

#define BKE_pbvh_vertex_iter_end
Value:
} \
} \
} \
((void)0)
SyclQueue void void size_t num_bytes void

Definition at line 509 of file BKE_pbvh.h.

◆ PBVH_ITER_ALL

#define PBVH_ITER_ALL   0

Definition at line 390 of file BKE_pbvh.h.

◆ PBVH_ITER_UNIQUE

#define PBVH_ITER_UNIQUE   1

Definition at line 391 of file BKE_pbvh.h.

Typedef Documentation

◆ BKE_pbvh_HitCallback

typedef void(* BKE_pbvh_HitCallback) (PBVHNode *node, void *data)

Definition at line 100 of file BKE_pbvh.h.

◆ BKE_pbvh_HitOccludedCallback

typedef void(* BKE_pbvh_HitOccludedCallback) (PBVHNode *node, void *data, float *tmin)

Definition at line 101 of file BKE_pbvh.h.

◆ BKE_pbvh_SearchCallback

typedef bool(* BKE_pbvh_SearchCallback) (PBVHNode *node, void *data)

Returns true if the search should continue from this node, false otherwise.

Definition at line 98 of file BKE_pbvh.h.

◆ BKE_pbvh_SearchNearestCallback

typedef void(* BKE_pbvh_SearchNearestCallback) (PBVHNode *node, void *data, float *tmin)

Definition at line 103 of file BKE_pbvh.h.

◆ PBVH

typedef struct PBVH PBVH

Definition at line 1 of file BKE_pbvh.h.

◆ PBVHFrustumPlanes

◆ PBVHNode

typedef struct PBVHNode PBVHNode

Definition at line 1 of file BKE_pbvh.h.

◆ PBVHPixelsNode

◆ PBVHVertexIter

Enumeration Type Documentation

◆ PBVHNodeFlags

Enumerator
PBVH_Leaf 
PBVH_UpdateNormals 
PBVH_UpdateBB 
PBVH_UpdateOriginalBB 
PBVH_UpdateDrawBuffers 
PBVH_UpdateRedraw 
PBVH_UpdateMask 
PBVH_UpdateVisibility 
PBVH_RebuildDrawBuffers 
PBVH_FullyHidden 
PBVH_FullyMasked 
PBVH_FullyUnmasked 
PBVH_UpdateTopology 
PBVH_UpdateColor 
PBVH_RebuildPixels 

Definition at line 63 of file BKE_pbvh.h.

◆ PBVHTopologyUpdateMode

Enumerator
PBVH_Subdivide 
PBVH_Collapse 

Definition at line 278 of file BKE_pbvh.h.

◆ PBVHType

enum PBVHType
Enumerator
PBVH_FACES 
PBVH_GRIDS 
PBVH_BMESH 

Definition at line 233 of file BKE_pbvh.h.

Function Documentation

◆ BKE_pbvh_bmesh_after_stroke()

void BKE_pbvh_bmesh_after_stroke ( PBVH *  pbvh)

◆ BKE_pbvh_bmesh_detail_size_set()

void BKE_pbvh_bmesh_detail_size_set ( PBVH *  pbvh,
float  detail_size 
)

◆ BKE_pbvh_bmesh_node_faces()

struct GSet* BKE_pbvh_bmesh_node_faces ( PBVHNode *  node)

Definition at line 2113 of file pbvh_bmesh.c.

References node.

Referenced by partialvis_update_bmesh(), and sculpt_undo_bmesh_push().

◆ BKE_pbvh_bmesh_node_other_verts()

struct GSet* BKE_pbvh_bmesh_node_other_verts ( PBVHNode *  node)

Definition at line 2108 of file pbvh_bmesh.c.

References node.

Referenced by partialvis_update_bmesh(), and pbvh_bmesh_node_visibility_update().

◆ BKE_pbvh_bmesh_node_raycast_detail()

bool BKE_pbvh_bmesh_node_raycast_detail ( PBVHNode *  node,
const float  ray_start[3],
struct IsectRayPrecalc *  isect_precalc,
float *  depth,
float *  r_edge_length 
)

◆ BKE_pbvh_bmesh_node_save_orig()

void BKE_pbvh_bmesh_node_save_orig ( struct BMesh *  bm,
PBVHNode *  node 
)

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().

◆ BKE_pbvh_bmesh_node_unique_verts()

struct GSet* BKE_pbvh_bmesh_node_unique_verts ( PBVHNode *  node)

Definition at line 2103 of file pbvh_bmesh.c.

References node.

Referenced by partialvis_update_bmesh(), and pbvh_bmesh_node_visibility_update().

◆ BKE_pbvh_bmesh_update_topology()

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 
)

◆ BKE_pbvh_bounding_box()

void BKE_pbvh_bounding_box ( const PBVH *  pbvh,
float  min[3],
float  max[3] 
)

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().

◆ BKE_pbvh_build_bmesh()

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 
)

◆ BKE_pbvh_build_grids()

void BKE_pbvh_build_grids ( PBVH *  pbvh,
struct CCGElem **  grids,
int  totgrid,
struct CCGKey *  key,
void **  gridfaces,
struct DMFlagMat *  flagmats,
unsigned int **  grid_hidden 
)

◆ BKE_pbvh_build_mesh()

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.

Note
Unlike mpoly/mloop/verts, looptri is totally owned by PBVH (which means it may rewrite it if needed, see BKE_pbvh_vert_coords_apply().

Referenced by build_pbvh_from_regular_mesh().

◆ BKE_pbvh_build_pixels()

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().

◆ BKE_pbvh_count_grid_quads()

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().

◆ BKE_pbvh_draw_cache_invalid()

bool BKE_pbvh_draw_cache_invalid ( const PBVH *  pbvh)

Definition at line 3250 of file pbvh.c.

References PBVH::draw_cache_invalid.

Referenced by mesh_batch_cache_valid().

◆ BKE_pbvh_draw_cb()

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 
)

◆ BKE_pbvh_draw_debug_cb()

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().

◆ BKE_pbvh_ensure_node_loops()

void BKE_pbvh_ensure_node_loops ( PBVH *  pbvh)

◆ BKE_pbvh_face_sets_color_set()

void BKE_pbvh_face_sets_color_set ( PBVH *  pbvh,
int  seed,
int  color_default 
)

◆ BKE_pbvh_face_sets_set()

void BKE_pbvh_face_sets_set ( PBVH *  pbvh,
int *  face_sets 
)

Definition at line 3236 of file pbvh.c.

References PBVH::face_sets.

Referenced by sculpt_update_object().

◆ BKE_pbvh_find_nearest_to_ray()

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 
)

◆ BKE_pbvh_free()

void BKE_pbvh_free ( PBVH *  pbvh)

◆ BKE_pbvh_gather_proxies()

void BKE_pbvh_gather_proxies ( PBVH *  pbvh,
PBVHNode ***  r_array,
int *  r_tot 
)

◆ BKE_pbvh_get_bmesh()

struct BMesh* BKE_pbvh_get_bmesh ( PBVH *  pbvh)

◆ BKE_pbvh_get_color_layer()

bool BKE_pbvh_get_color_layer ( const struct Mesh *  me,
CustomDataLayer **  r_layer,
eAttrDomain *  r_attr 
)

Referenced by sculpt_update_object().

◆ BKE_pbvh_get_frustum_planes()

void BKE_pbvh_get_frustum_planes ( PBVH *  pbvh,
PBVHFrustumPlanes *  planes 
)

◆ BKE_pbvh_get_grid_key()

const struct CCGKey* BKE_pbvh_get_grid_key ( const PBVH *  pbvh)

◆ BKE_pbvh_get_grid_num_faces()

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().

◆ BKE_pbvh_get_grid_num_vertices()

int BKE_pbvh_get_grid_num_vertices ( const PBVH *  pbvh)

◆ BKE_pbvh_get_grid_updates()

void BKE_pbvh_get_grid_updates ( PBVH *  pbvh,
bool  clear,
void ***  r_gridfaces,
int *  r_totface 
)

◆ BKE_pbvh_get_grid_visibility()

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().

◆ BKE_pbvh_get_grids()

struct CCGElem** BKE_pbvh_get_grids ( const PBVH *  pbvh)

◆ BKE_pbvh_get_vert_normals()

const float(* BKE_pbvh_get_vert_normals ( const PBVH *  pbvh) )[3]

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().

◆ BKE_pbvh_get_verts()

struct MVert* BKE_pbvh_get_verts ( const PBVH *  pbvh)

◆ BKE_pbvh_grid_hidden()

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().

◆ BKE_pbvh_grids_update()

void BKE_pbvh_grids_update ( PBVH *  pbvh,
struct CCGElem **  grids,
void **  gridfaces,
struct DMFlagMat *  flagmats,
unsigned int **  grid_hidden 
)

◆ BKE_pbvh_has_faces()

bool BKE_pbvh_has_faces ( const PBVH *  pbvh)

Definition at line 1803 of file pbvh.c.

References PBVH::bm, PBVH_BMESH, BMesh::totface, PBVH::totprim, and PBVH::type.

◆ BKE_pbvh_is_deformed()

bool BKE_pbvh_is_deformed ( struct PBVH *  pbvh)

Definition at line 3010 of file pbvh.c.

References PBVH::deformed.

Referenced by sculpt_update_object().

◆ BKE_pbvh_is_drawing()

bool BKE_pbvh_is_drawing ( const PBVH *  pbvh)

Definition at line 3245 of file pbvh.c.

References PBVH::is_drawing.

Referenced by mesh_batch_cache_init(), and mesh_batch_cache_valid().

◆ BKE_pbvh_is_drawing_set()

void BKE_pbvh_is_drawing_set ( PBVH *  pbvh,
bool  val 
)

Definition at line 3255 of file pbvh.c.

References PBVH::is_drawing.

Referenced by workbench_color_type_get().

◆ BKE_pbvh_mark_rebuild_pixels()

void BKE_pbvh_mark_rebuild_pixels ( PBVH *  pbvh)

Definition at line 1885 of file pbvh.c.

References node, PBVH::nodes, PBVH_Leaf, PBVH_RebuildPixels, and PBVH::totnode.

Referenced by sculpt_update_object().

◆ BKE_pbvh_new()

PBVH* BKE_pbvh_new ( void  )

◆ BKE_pbvh_node_add_proxy()

PBVHProxyNode* BKE_pbvh_node_add_proxy ( PBVH *  pbvh,
PBVHNode *  node 
)

◆ BKE_pbvh_node_color_buffer_free()

void BKE_pbvh_node_color_buffer_free ( PBVH *  pbvh)

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().

◆ BKE_pbvh_node_color_buffer_get()

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().

◆ BKE_pbvh_node_find_nearest_to_ray()

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 
)

◆ BKE_pbvh_node_free_proxies()

void BKE_pbvh_node_free_proxies ( PBVHNode *  node)

Definition at line 3037 of file pbvh.c.

References MEM_freeN, node, and NULL.

Referenced by sculpt_combine_proxies_task_cb().

◆ BKE_pbvh_node_frustum_contain_AABB()

bool BKE_pbvh_node_frustum_contain_AABB ( PBVHNode *  node,
void *  frustum 
)

◆ BKE_pbvh_node_frustum_exclude_AABB()

bool BKE_pbvh_node_frustum_exclude_AABB ( PBVHNode *  node,
void *  frustum 
)

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().

◆ BKE_pbvh_node_fully_hidden_get()

bool BKE_pbvh_node_fully_hidden_get ( PBVHNode *  node)

Definition at line 1928 of file pbvh.c.

References node, PBVH_FullyHidden, and PBVH_Leaf.

Referenced by SCULPT_search_sphere_cb().

◆ BKE_pbvh_node_fully_hidden_set()

void BKE_pbvh_node_fully_hidden_set ( PBVHNode *  node,
int  fully_hidden 
)

◆ BKE_pbvh_node_fully_masked_get()

bool BKE_pbvh_node_fully_masked_get ( PBVHNode *  node)

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().

◆ BKE_pbvh_node_fully_masked_set()

void BKE_pbvh_node_fully_masked_set ( PBVHNode *  node,
int  fully_masked 
)

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().

◆ BKE_pbvh_node_fully_unmasked_get()

bool BKE_pbvh_node_fully_unmasked_get ( PBVHNode *  node)

Definition at line 1962 of file pbvh.c.

References node, PBVH_FullyUnmasked, and PBVH_Leaf.

◆ BKE_pbvh_node_fully_unmasked_set()

void BKE_pbvh_node_fully_unmasked_set ( PBVHNode *  node,
int  fully_masked 
)

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().

◆ BKE_pbvh_node_get_BB()

void BKE_pbvh_node_get_BB ( PBVHNode *  node,
float  bb_min[3],
float  bb_max[3] 
)

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().

◆ BKE_pbvh_node_get_bm_orco_data()

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().

◆ BKE_pbvh_node_get_grids()

void BKE_pbvh_node_get_grids ( PBVH *  pbvh,
PBVHNode *  node,
int **  grid_indices,
int *  totgrid,
int *  maxgrid,
int *  gridsize,
struct CCGElem ***  r_griddata 
)

◆ BKE_pbvh_node_get_loops()

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().

◆ BKE_pbvh_node_get_original_BB()

void BKE_pbvh_node_get_original_BB ( PBVHNode *  node,
float  bb_min[3],
float  bb_max[3] 
)

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().

◆ BKE_pbvh_node_get_proxies()

void BKE_pbvh_node_get_proxies ( PBVHNode *  node,
PBVHProxyNode **  proxies,
int *  proxy_count 
)

Definition at line 2096 of file pbvh.c.

References node, and NULL.

Referenced by sculpt_combine_proxies_task_cb().

◆ BKE_pbvh_node_get_tmin()

float BKE_pbvh_node_get_tmin ( PBVHNode *  node)

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().

◆ BKE_pbvh_node_get_verts()

void BKE_pbvh_node_get_verts ( PBVH *  pbvh,
PBVHNode *  node,
const int **  r_vert_indices,
struct MVert **  r_verts 
)

◆ BKE_pbvh_node_has_vert_with_normal_update_tag()

bool BKE_pbvh_node_has_vert_with_normal_update_tag ( PBVH *  pbvh,
PBVHNode *  node 
)
Note
doing a full search on all vertices here seems expensive, however this is important to avoid having to recalculate bound-box & sync the buffers to the GPU (which is far more expensive!) See: T47232.

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().

◆ BKE_pbvh_node_mark_normals_update()

void BKE_pbvh_node_mark_normals_update ( PBVHNode *  node)

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().

◆ BKE_pbvh_node_mark_rebuild_draw()

void BKE_pbvh_node_mark_rebuild_draw ( PBVHNode *  node)

◆ BKE_pbvh_node_mark_redraw()

void BKE_pbvh_node_mark_redraw ( PBVHNode *  node)

◆ BKE_pbvh_node_mark_topology_update()

void BKE_pbvh_node_mark_topology_update ( PBVHNode *  node)

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().

◆ BKE_pbvh_node_mark_update()

void BKE_pbvh_node_mark_update ( PBVHNode *  node)

◆ BKE_pbvh_node_mark_update_color()

void BKE_pbvh_node_mark_update_color ( PBVHNode *  node)

◆ BKE_pbvh_node_mark_update_mask()

void BKE_pbvh_node_mark_update_mask ( PBVHNode *  node)

◆ BKE_pbvh_node_mark_update_visibility()

void BKE_pbvh_node_mark_update_visibility ( PBVHNode *  node)

◆ BKE_pbvh_node_num_loops()

void BKE_pbvh_node_num_loops ( PBVH *  pbvh,
PBVHNode *  node,
int *  r_totloop 
)

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().

◆ BKE_pbvh_node_num_verts()

void BKE_pbvh_node_num_verts ( PBVH *  pbvh,
PBVHNode *  node,
int *  r_uniquevert,
int *  r_totvert 
)

◆ BKE_pbvh_node_raycast()

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 
)

◆ BKE_pbvh_parallel_range_settings()

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().

◆ BKE_pbvh_pmap_set()

void BKE_pbvh_pmap_set ( PBVH *  pbvh,
const struct MeshElemMap *  pmap 
)

◆ BKE_pbvh_raycast()

void BKE_pbvh_raycast ( PBVH *  pbvh,
BKE_pbvh_HitOccludedCallback  cb,
void *  data,
const float  ray_start[3],
const float  ray_normal[3],
bool  original 
)

◆ BKE_pbvh_raycast_project_ray_root()

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().

◆ BKE_pbvh_redraw_BB()

void BKE_pbvh_redraw_BB ( PBVH *  pbvh,
float  bb_min[3],
float  bb_max[3] 
)

◆ BKE_pbvh_respect_hide_set()

void BKE_pbvh_respect_hide_set ( PBVH *  pbvh,
bool  respect_hide 
)

Definition at line 3241 of file pbvh.c.

References PBVH::respect_hide.

Referenced by build_pbvh_from_ccg(), and build_pbvh_from_regular_mesh().

◆ BKE_pbvh_search_callback()

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().

◆ BKE_pbvh_search_gather()

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().

◆ BKE_pbvh_set_frustum_planes()

void BKE_pbvh_set_frustum_planes ( PBVH *  pbvh,
PBVHFrustumPlanes *  planes 
)

◆ BKE_pbvh_store_colors()

void BKE_pbvh_store_colors ( PBVH *  pbvh,
const int *  indices,
const int  indices_num,
float(*)  colors[4] 
)

◆ BKE_pbvh_store_colors_vertex()

void BKE_pbvh_store_colors_vertex ( PBVH *  pbvh,
const int *  indices,
const int  indices_num,
float(*)  colors[4] 
)

◆ BKE_pbvh_subdiv_cgg_set()

void BKE_pbvh_subdiv_cgg_set ( PBVH *  pbvh,
struct SubdivCCG *  subdiv_ccg 
)

Definition at line 3231 of file pbvh.c.

References PBVH::subdiv_ccg.

Referenced by sculpt_update_object().

◆ BKE_pbvh_swap_colors()

void BKE_pbvh_swap_colors ( PBVH *  pbvh,
const int *  indices,
const int  indices_num,
float(*)  colors[4] 
)

◆ BKE_pbvh_sync_face_sets_to_grids()

void BKE_pbvh_sync_face_sets_to_grids ( PBVH *  pbvh)

◆ BKE_pbvh_type()

PBVHType BKE_pbvh_type ( const PBVH *  pbvh)

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().

◆ BKE_pbvh_update_active_vcol()

void BKE_pbvh_update_active_vcol ( PBVH *  pbvh,
const struct Mesh *  mesh 
)

◆ BKE_pbvh_update_bounds()

void BKE_pbvh_update_bounds ( PBVH *  pbvh,
int  flags 
)

◆ BKE_pbvh_update_normals()

void BKE_pbvh_update_normals ( PBVH *  pbvh,
struct SubdivCCG *  subdiv_ccg 
)

◆ BKE_pbvh_update_vertex_data()

void BKE_pbvh_update_vertex_data ( PBVH *  pbvh,
int  flags 
)

◆ BKE_pbvh_update_visibility()

void BKE_pbvh_update_visibility ( PBVH *  pbvh)

◆ BKE_pbvh_vert_coords_alloc()

float(* BKE_pbvh_vert_coords_alloc ( struct PBVH *  pbvh) )[3]

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().

◆ BKE_pbvh_vert_coords_apply()

void BKE_pbvh_vert_coords_apply ( struct PBVH *  pbvh,
const float(*)  vertCos[3],
int  totvert 
)

◆ BKE_pbvh_vert_tag_update_normal()

void BKE_pbvh_vert_tag_update_normal ( PBVH *  pbvh,
int  index 
)

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().

◆ BKE_pbvh_vertex_color_get()

void BKE_pbvh_vertex_color_get ( const PBVH *  pbvh,
int  vertex,
float  r_color[4] 
)

◆ BKE_pbvh_vertex_color_set()

void BKE_pbvh_vertex_color_set ( PBVH *  pbvh,
int  vertex,
const float  color[4] 
)

◆ pbvh_has_face_sets()

bool pbvh_has_face_sets ( PBVH *  pbvh)

◆ pbvh_has_mask()

bool pbvh_has_mask ( const PBVH *  pbvh)

◆ pbvh_show_face_sets_set()

void pbvh_show_face_sets_set ( PBVH *  pbvh,
bool  show_face_sets 
)

◆ pbvh_show_mask_set()

void pbvh_show_mask_set ( PBVH *  pbvh,
bool  show_mask 
)

◆ pbvh_vertex_iter_init()

void pbvh_vertex_iter_init ( PBVH *  pbvh,
PBVHNode *  node,
PBVHVertexIter *  vi,
int  mode 
)