|
Blender V5.0
|
#include <BKE_paint_bvh.hh>
Public Member Functions | |
| Tree (const Tree &other)=delete | |
| Tree (Tree &&other)=default | |
| Tree & | operator= (const Tree &other)=delete |
| Tree & | operator= (Tree &&other)=default |
| ~Tree () | |
| int | nodes_num () const |
| template<typename NodeT> | |
| Span< NodeT > | nodes () const |
| template<typename NodeT> | |
| MutableSpan< NodeT > | nodes () |
| Type | type () const |
| void | tag_positions_changed (const IndexMask &node_mask) |
| void | tag_visibility_changed (const IndexMask &node_mask) |
| void | tag_topology_changed (const IndexMask &node_mask) |
| void | tag_face_sets_changed (const IndexMask &node_mask) |
| void | tag_masks_changed (const IndexMask &node_mask) |
| void | tag_attribute_changed (const IndexMask &node_mask, StringRef attribute_name) |
| void | flush_bounds_to_parents () |
| void | update_bounds (const Depsgraph &depsgraph, const Object &object) |
| void | update_bounds_mesh (Span< float3 > vert_positions) |
| void | update_bounds_grids (Span< float3 > positions, int grid_area) |
| void | update_bounds_bmesh (const BMesh &bm) |
| void | update_normals (Object &object_orig, Object &object_eval) |
| void | update_visibility (const Object &object) |
| template<> | |
| Span< MeshNode > | nodes () const |
| template<> | |
| Span< GridsNode > | nodes () const |
| template<> | |
| Span< BMeshNode > | nodes () const |
| template<> | |
| MutableSpan< MeshNode > | nodes () |
| template<> | |
| MutableSpan< GridsNode > | nodes () |
| template<> | |
| MutableSpan< BMeshNode > | nodes () |
Static Public Member Functions | |
| static Tree | from_mesh (const Mesh &mesh) |
| static Tree | from_grids (const Mesh &base_mesh, const SubdivCCG &subdiv_ccg) |
| static Tree | from_bmesh (BMesh &bm) |
Public Attributes | |
| std::variant< Vector< MeshNode >, Vector< GridsNode >, Vector< BMeshNode > > | nodes_ |
| pixels::PBVHData * | pixels_ = nullptr |
| std::unique_ptr< DrawCache > | draw_data |
Definition at line 231 of file BKE_paint_bvh.hh.
|
delete |
References Tree().
Referenced by from_bmesh(), from_grids(), from_mesh(), nodes(), operator=(), operator=(), Tree(), and Tree().
|
default |
References Tree().
| blender::bke::pbvh::Tree::~Tree | ( | ) |
Definition at line 620 of file pbvh.cc.
References blender::bke::pbvh::Node::Leaf, blender::bke::pbvh::node_pixels_free(), nodes(), nodes_, blender::bke::pbvh::pixels_free(), and blender::bke::pbvh::Node::TexLeaf.
| void blender::bke::pbvh::Tree::flush_bounds_to_parents | ( | ) |
Run the last step of the BVH bounds recalculation process, propagating updated leaf node bounds to their parent/ancestor inner nodes. This is meant to be used after leaf node bounds have been computed separately.
Definition at line 1306 of file pbvh.cc.
References blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::begin(), blender::index_mask::IndexMask::foreach_index(), blender::IndexMask::from_bits(), i, blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::is_empty(), blender::Bounds< T >::max, blender::bounds::merge(), blender::Bounds< T >::min, nodes(), nodes_, blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::remove(), blender::Set< Key, InlineBufferCapacity, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::reserve(), and blender::index_mask::IndexMask::size().
Referenced by blender::ed::sculpt_paint::boundary::do_bend_brush(), blender::ed::sculpt_paint::brushes::do_bmesh_topology_rake_brush(), blender::ed::sculpt_paint::brushes::do_clay_brush(), blender::ed::sculpt_paint::brushes::do_clay_strips_brush(), blender::ed::sculpt_paint::brushes::do_clay_thumb_brush(), blender::ed::sculpt_paint::brushes::do_displacement_eraser_brush(), blender::ed::sculpt_paint::brushes::do_displacement_smear_brush(), blender::ed::sculpt_paint::brushes::do_draw_vector_displacement_brush(), blender::ed::sculpt_paint::brushes::do_elastic_deform_brush(), blender::ed::sculpt_paint::brushes::do_enhance_details_brush(), blender::ed::sculpt_paint::boundary::do_grab_brush(), blender::ed::sculpt_paint::brushes::do_grab_brush(), blender::ed::sculpt_paint::boundary::do_inflate_brush(), blender::ed::sculpt_paint::brushes::do_inflate_brush(), blender::ed::sculpt_paint::brushes::do_layer_brush(), blender::ed::sculpt_paint::brushes::do_multiplane_scrape_brush(), blender::ed::sculpt_paint::brushes::do_pinch_brush(), blender::ed::sculpt_paint::brushes::do_plane_brush(), blender::ed::sculpt_paint::pose::do_pose_brush(), blender::ed::sculpt_paint::brushes::do_rotate_brush(), blender::ed::sculpt_paint::cloth::do_simulation_step(), blender::ed::sculpt_paint::boundary::do_slide_brush(), blender::ed::sculpt_paint::boundary::do_smooth_brush(), blender::ed::sculpt_paint::brushes::do_snake_hook_brush(), blender::ed::sculpt_paint::brushes::do_thumb_brush(), blender::ed::sculpt_paint::brushes::do_topology_slide_brush(), blender::ed::sculpt_paint::boundary::do_twist_brush(), blender::ed::sculpt_paint::project::gesture_apply_for_symmetry_pass(), blender::ed::sculpt_paint::brushes::offset_positions(), blender::ed::sculpt_paint::cloth::sculpt_cloth_filter_modal(), blender::ed::sculpt_paint::sculpt_transform_all_vertices(), blender::ed::sculpt_paint::transform_radius_elastic(), update_bounds_bmesh(), update_bounds_grids(), and update_bounds_mesh().
Build a BVH tree from a triangle BMesh.
Definition at line 2158 of file pbvh_bmesh.cc.
References BLI_memarena_new(), BLI_MEMARENA_STD_BUFSIZE, 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, BM_VERTS_OF_MESH, blender::bke::pbvh::BMesh, CD_PROP_INT32, BMVert::co, CustomData_get_offset_named(), blender::bke::pbvh::dyntopo_node_none, i, blender::math::min_max(), blender::bke::pbvh::negative_bounds(), BMLoop::next, nodes(), blender::threading::parallel_for(), blender::bke::pbvh::pbvh_bmesh_create_nodes_fast_recursive(), blender::bke::pbvh::pbvh_bmesh_node_limit_ensure_fast(), blender::bke::pbvh::store_bounds_orig(), blender::bke::pbvh::FastNodeBuildInfo::totface, Tree(), BMLoop::v, and v.
Referenced by blender::bke::build_pbvh_for_dynamic_topology().
|
static |
Build a BVH tree from grids geometry.
Definition at line 471 of file pbvh.cc.
References Geometry::attributes, BKE_subdiv_ccg_key_top_level(), blender::bke::pbvh::build_nodes_recursive_grids(), blender::bke::pbvh::calc_face_grid_bounds(), blender::bke::Face, faces, blender::array_utils::fill_index_range(), from_grids(), CCGKey::grid_area, blender::bke::pbvh::Grids, i, init(), blender::Span< T >::is_empty(), blender::bke::pbvh::leaf_limit, blender::bounds::merge(), blender::bke::pbvh::merge_bounds(), blender::bke::pbvh::negative_bounds(), nodes(), blender::threading::parallel_for(), blender::threading::parallel_reduce(), SubdivCCG::positions, SCOPED_TIMER_AVERAGED, and Tree().
Referenced by blender::bke::build_pbvh_from_ccg(), and from_grids().
Build a BVH tree from base mesh triangles.
Definition at line 306 of file pbvh.cc.
References blender::bke::pbvh::build_mesh_leaf_nodes(), blender::bke::pbvh::build_nodes_recursive_mesh(), blender::bke::pbvh::calc_face_bounds(), blender::bke::Face, faces, blender::array_utils::fill_index_range(), from_mesh(), init(), blender::Span< T >::is_empty(), blender::bke::pbvh::leaf_limit, blender::bounds::merge(), blender::bke::pbvh::merge_bounds(), blender::bke::pbvh::Mesh, blender::bke::pbvh::negative_bounds(), nodes(), blender::threading::parallel_for(), blender::threading::parallel_reduce(), blender::bke::Point, SCOPED_TIMER_AVERAGED, blender::Span< T >::slice(), blender::bke::pbvh::store_bounds_orig(), and Tree().
Referenced by blender::bke::build_pbvh_from_regular_mesh(), from_mesh(), and blender::bke::tests::TEST_F().
| MutableSpan< NodeT > blender::bke::pbvh::Tree::nodes | ( | ) |
| MutableSpan< BMeshNode > blender::bke::pbvh::Tree::nodes | ( | ) |
| MutableSpan< GridsNode > blender::bke::pbvh::Tree::nodes | ( | ) |
| MutableSpan< MeshNode > blender::bke::pbvh::Tree::nodes | ( | ) |
| Span< NodeT > blender::bke::pbvh::Tree::nodes | ( | ) | const |
Referenced by blender::ed::sculpt_paint::mask::apply_mask_from_settings(), blender::ed::sculpt_paint::mask::apply_new_mask_bmesh(), blender::ed::sculpt_paint::mask::apply_new_mask_grids(), blender::ed::sculpt_paint::mask::apply_new_mask_mesh(), blender::ed::sculpt_paint::average_mask_border_position(), blender::ed::sculpt_paint::average_unmasked_position(), blender::ed::sculpt_paint::smooth::blur_geometry_data_array(), blender::ed::sculpt_paint::calc_area_center(), blender::ed::sculpt_paint::calc_area_normal(), blender::ed::sculpt_paint::calc_area_normal_and_center(), blender::ed::sculpt_paint::auto_mask::Cache::calc_cavity_factor(), blender::ed::sculpt_paint::cloth::calc_constraint_factors(), blender::ed::sculpt_paint::filter::calc_enhance_details_filter(), blender::ed::sculpt_paint::filter::calc_erase_displacement_filter(), blender::ed::sculpt_paint::filter::calc_inflate_filter(), blender::ed::sculpt_paint::filter::calc_random_filter(), blender::ed::sculpt_paint::filter::calc_relax_face_sets_filter(), blender::ed::sculpt_paint::filter::calc_relax_filter(), blender::ed::sculpt_paint::filter::calc_scale_filter(), blender::ed::sculpt_paint::filter::calc_sharpen_filter(), blender::ed::sculpt_paint::filter::calc_smooth_filter(), blender::ed::sculpt_paint::calc_smooth_translations(), blender::ed::sculpt_paint::filter::calc_sphere_filter(), blender::ed::sculpt_paint::filter::calc_surface_smooth_filter(), blender::ed::sculpt_paint::islands::calc_topology_islands_bmesh(), calculate_average_weight(), blender::ed::sculpt_paint::face_set::clear_face_sets(), blender::ed::sculpt_paint::cloth::cloth_brush_apply_brush_forces(), blender::ed::sculpt_paint::cloth::cloth_sim_initialize_default_node_state(), blender::ed::sculpt_paint::boundary::do_bend_brush(), blender::ed::sculpt_paint::brushes::do_bmesh_topology_rake_brush(), blender::ed::sculpt_paint::brushes::do_clay_brush(), blender::ed::sculpt_paint::brushes::do_clay_strips_brush(), blender::ed::sculpt_paint::brushes::do_clay_thumb_brush(), blender::ed::sculpt_paint::brushes::do_displacement_eraser_brush(), blender::ed::sculpt_paint::brushes::do_displacement_smear_brush(), blender::ed::sculpt_paint::brushes::do_draw_vector_displacement_brush(), blender::ed::sculpt_paint::brushes::do_elastic_deform_brush(), blender::ed::sculpt_paint::brushes::do_enhance_details_brush(), blender::ed::sculpt_paint::boundary::do_grab_brush(), blender::ed::sculpt_paint::brushes::do_grab_brush(), blender::ed::sculpt_paint::boundary::do_inflate_brush(), blender::ed::sculpt_paint::brushes::do_inflate_brush(), blender::ed::sculpt_paint::brushes::do_layer_brush(), blender::ed::sculpt_paint::brushes::do_mask_brush(), blender::ed::sculpt_paint::brushes::do_multiplane_scrape_brush(), blender::ed::sculpt_paint::color::do_paint_brush(), blender::ed::sculpt_paint::brushes::do_pinch_brush(), blender::ed::sculpt_paint::brushes::do_plane_brush(), blender::ed::sculpt_paint::pose::do_pose_brush(), blender::ed::sculpt_paint::brushes::do_rotate_brush(), blender::ed::sculpt_paint::cloth::do_simulation_step(), blender::ed::sculpt_paint::boundary::do_slide_brush(), blender::ed::sculpt_paint::color::do_smear_brush(), blender::ed::sculpt_paint::boundary::do_smooth_brush(), blender::ed::sculpt_paint::brushes::do_smooth_brush(), blender::ed::sculpt_paint::brushes::do_smooth_mask_brush(), blender::ed::sculpt_paint::brushes::do_snake_hook_brush(), blender::ed::sculpt_paint::brushes::do_thumb_brush(), blender::ed::sculpt_paint::brushes::do_topology_slide_brush(), blender::ed::sculpt_paint::boundary::do_twist_brush(), do_wpaint_brush_blur(), do_wpaint_brush_draw(), do_wpaint_brush_smear(), blender::ed::sculpt_paint::dynamic_topology_update(), blender::ed::sculpt_paint::face_set::edit_fairing(), blender::ed::sculpt_paint::cloth::ensure_nodes_constraints(), blender::ed::sculpt_paint::face_set::face_hide_update(), blender::ed::sculpt_paint::face_set::face_sets_update(), blender::ed::sculpt_paint::fake_neighbor_search(), blender::ed::sculpt_paint::mask::fill_mask_bmesh(), blender::ed::sculpt_paint::mask::fill_mask_grids(), blender::ed::sculpt_paint::mask::fill_mask_mesh(), flush_bounds_to_parents(), blender::ed::sculpt_paint::hide::flush_face_changes_node(), from_bmesh(), from_grids(), from_mesh(), blender::ed::sculpt_paint::face_set::gesture_apply_bmesh(), blender::ed::sculpt_paint::mask::gesture_apply_for_symmetry_pass(), blender::ed::sculpt_paint::project::gesture_apply_for_symmetry_pass(), blender::ed::sculpt_paint::face_set::gesture_apply_mesh(), blender::ed::sculpt_paint::hide::grid_hide_update(), blender::ed::sculpt_paint::hide::grids_show_all(), blender::ed::sculpt_paint::pose::grow_pose_factor(), blender::ed::sculpt_paint::hide::grow_shrink_visibility_grid(), blender::ed::sculpt_paint::mask::init_mask_grids(), blender::ed::sculpt_paint::mask::invert_mask_bmesh(), blender::ed::sculpt_paint::mask::invert_mask_grids(), blender::ed::sculpt_paint::hide::invert_visibility_bmesh(), blender::ed::sculpt_paint::hide::invert_visibility_grids(), blender::ed::sculpt_paint::hide::invert_visibility_mesh(), blender::ed::sculpt_paint::filter::mesh_filter_sharpen_init(), blender::ed::sculpt_paint::hide::mesh_show_all(), blender::ed::sculpt_paint::nearest_vert_calc_bmesh(), blender::ed::sculpt_paint::nearest_vert_calc_grids(), blender::ed::sculpt_paint::nearest_vert_calc_mesh(), nodes_num(), blender::ed::sculpt_paint::brushes::offset_positions(), blender::ed::sculpt_paint::hide::partialvis_update_bmesh_nodes(), blender::ed::sculpt_paint::undo::push_nodes(), blender::ed::sculpt_paint::expand::restore_color_data(), blender::ed::sculpt_paint::undo::restore_color_from_undo_step(), blender::ed::sculpt_paint::undo::restore_face_set_from_undo_step(), blender::ed::sculpt_paint::undo::restore_list(), blender::ed::sculpt_paint::undo::restore_mask_from_undo_step(), blender::ed::sculpt_paint::undo::restore_position_from_undo_step(), blender::ed::sculpt_paint::brushes::sample_surface(), blender::ed::sculpt_paint::cloth::sculpt_cloth_filter_modal(), blender::ed::sculpt_paint::color::sculpt_color_filter_apply(), blender::ed::sculpt_paint::color::sculpt_color_presmooth_init(), blender::ed::sculpt_paint::dyntopo::sculpt_detail_flood_fill_exec(), blender::ed::sculpt_paint::mask::sculpt_mask_filter_exec(), blender::ed::sculpt_paint::mask::sculpt_mask_init_exec(), blender::ed::sculpt_paint::sculpt_transform_all_vertices(), blender::ed::sculpt_paint::cloth::sim_activate_nodes(), blender::ed::sculpt_paint::transform_radius_elastic(), blender::ed::sculpt_paint::mask::try_remove_mask_mesh(), update_bounds_bmesh(), update_bounds_grids(), update_bounds_mesh(), blender::ed::sculpt_paint::expand::update_for_vert(), blender::ed::sculpt_paint::mask::update_mask_mesh(), blender::ed::sculpt_paint::hide::update_node_visibility_from_face_changes(), update_normals(), blender::ed::sculpt_paint::hide::update_undo_state(), update_visibility(), blender::ed::sculpt_paint::hide::vert_hide_update(), blender::ed::sculpt_paint::mask::write_mask_mesh(), and ~Tree().
| int blender::bke::pbvh::Tree::nodes_num | ( | ) | const |
Definition at line 590 of file pbvh.cc.
References nodes(), and nodes_.
Referenced by blender::ed::sculpt_paint::face_set::clear_face_sets(), blender::ed::sculpt_paint::cloth::cloth_sim_initialize_default_node_state(), blender::ed::sculpt_paint::face_set::face_sets_update(), and blender::ed::sculpt_paint::face_set::gesture_apply_mesh().
| void blender::bke::pbvh::Tree::tag_attribute_changed | ( | const IndexMask & | node_mask, |
| StringRef | attribute_name ) |
Tag nodes where generic attribute data has changed (not positions, masks, or face sets).
Definition at line 676 of file pbvh.cc.
References draw_data.
Referenced by blender::ed::sculpt_paint::color::do_paint_brush(), blender::ed::sculpt_paint::expand::restore_color_data(), blender::ed::sculpt_paint::undo::restore_color_from_undo_step(), blender::ed::sculpt_paint::undo::restore_list(), blender::ed::sculpt_paint::color::sculpt_color_filter_apply(), transform_active_color(), blender::ed::sculpt_paint::expand::update_for_vert(), and vertex_color_set_exec().
| void blender::bke::pbvh::Tree::tag_face_sets_changed | ( | const IndexMask & | node_mask | ) |
Tag nodes where face sets have changed, causing refresh of derived data.
Definition at line 662 of file pbvh.cc.
References draw_data.
Referenced by blender::ed::sculpt_paint::face_set::clear_face_sets(), blender::ed::sculpt_paint::expand::face_sets_update(), blender::ed::sculpt_paint::face_set::face_sets_update(), blender::ed::sculpt_paint::face_set::gesture_apply_bmesh(), blender::ed::sculpt_paint::face_set::gesture_apply_mesh(), blender::ed::sculpt_paint::face_set::init_op_exec(), blender::ed::sculpt_paint::face_set::randomize_colors_exec(), blender::ed::sculpt_paint::expand::restore_face_set_data(), blender::ed::sculpt_paint::undo::restore_face_set_from_undo_step(), blender::ed::sculpt_paint::undo::restore_list(), and blender::ed::sculpt_paint::store_mesh_from_eval().
| void blender::bke::pbvh::Tree::tag_masks_changed | ( | const IndexMask & | node_mask | ) |
Tag nodes where mask values have changed, causing refresh of derived data.
Definition at line 669 of file pbvh.cc.
References draw_data.
Referenced by blender::ed::sculpt_paint::mask::apply_new_mask_bmesh(), blender::ed::sculpt_paint::mask::apply_new_mask_grids(), blender::ed::sculpt_paint::mask::apply_new_mask_mesh(), blender::ed::sculpt_paint::undo::bmesh_restore_generic(), blender::ed::sculpt_paint::brushes::do_mask_brush(), blender::ed::sculpt_paint::brushes::do_smooth_mask_brush(), blender::ed::sculpt_paint::mask::fill_mask_bmesh(), blender::ed::sculpt_paint::mask::fill_mask_mesh(), blender::ed::sculpt_paint::mask::gesture_apply_for_symmetry_pass(), blender::ed::sculpt_paint::mask::init_mask_grids(), blender::ed::sculpt_paint::mask::invert_mask_bmesh(), blender::ed::sculpt_paint::mask::invert_mask_grids(), blender::ed::sculpt_paint::mask::mask_from_boundary_exec(), blender::ed::sculpt_paint::mask::mask_from_cavity_exec(), blender::ed::sculpt_paint::undo::restore_list(), blender::ed::sculpt_paint::undo::restore_mask_from_undo_step(), blender::ed::sculpt_paint::mask::sculpt_mask_filter_exec(), blender::ed::sculpt_paint::mask::sculpt_mask_init_exec(), blender::ed::sculpt_paint::store_mesh_from_eval(), blender::ed::sculpt_paint::expand::update_for_vert(), blender::ed::sculpt_paint::mask::update_mask_mesh(), blender::ed::sculpt_paint::expand::write_mask_data(), and blender::ed::sculpt_paint::mask::write_mask_mesh().
| void blender::bke::pbvh::Tree::tag_positions_changed | ( | const IndexMask & | node_mask | ) |
Mark data based on positions for specific BVH nodes dirty. In particular: bounds, normals, and GPU data buffers. That data is recomputed later on in functions like update_bounds.
Definition at line 635 of file pbvh.cc.
References draw_data, blender::index_mask::IndexMask::min_array_size(), and blender::index_mask::IndexMask::set_bits().
Referenced by BKE_pbvh_bmesh_after_stroke(), blender::ed::sculpt_paint::boundary::do_bend_brush(), blender::ed::sculpt_paint::brushes::do_bmesh_topology_rake_brush(), blender::ed::sculpt_paint::brushes::do_clay_brush(), blender::ed::sculpt_paint::brushes::do_clay_strips_brush(), blender::ed::sculpt_paint::brushes::do_clay_thumb_brush(), blender::ed::sculpt_paint::brushes::do_displacement_eraser_brush(), blender::ed::sculpt_paint::brushes::do_displacement_smear_brush(), blender::ed::sculpt_paint::brushes::do_draw_vector_displacement_brush(), blender::ed::sculpt_paint::brushes::do_elastic_deform_brush(), blender::ed::sculpt_paint::brushes::do_enhance_details_brush(), blender::ed::sculpt_paint::boundary::do_grab_brush(), blender::ed::sculpt_paint::brushes::do_grab_brush(), blender::ed::sculpt_paint::boundary::do_inflate_brush(), blender::ed::sculpt_paint::brushes::do_inflate_brush(), blender::ed::sculpt_paint::brushes::do_layer_brush(), blender::ed::sculpt_paint::brushes::do_multiplane_scrape_brush(), blender::ed::sculpt_paint::brushes::do_pinch_brush(), blender::ed::sculpt_paint::brushes::do_plane_brush(), blender::ed::sculpt_paint::pose::do_pose_brush(), blender::ed::sculpt_paint::brushes::do_rotate_brush(), blender::ed::sculpt_paint::cloth::do_simulation_step(), blender::ed::sculpt_paint::boundary::do_slide_brush(), blender::ed::sculpt_paint::boundary::do_smooth_brush(), blender::ed::sculpt_paint::brushes::do_smooth_brush(), blender::ed::sculpt_paint::brushes::do_snake_hook_brush(), blender::ed::sculpt_paint::brushes::do_surface_smooth_brush(), blender::ed::sculpt_paint::brushes::do_thumb_brush(), blender::ed::sculpt_paint::brushes::do_topology_slide_brush(), blender::ed::sculpt_paint::boundary::do_twist_brush(), blender::ed::sculpt_paint::dynamic_topology_update(), blender::ed::sculpt_paint::face_set::edit_modify_coordinates(), blender::ed::sculpt_paint::project::gesture_apply_for_symmetry_pass(), blender::ed::sculpt_paint::brushes::offset_positions(), blender::ed::sculpt_paint::undo::restore_list(), blender::ed::sculpt_paint::undo::restore_position_from_undo_step(), blender::ed::sculpt_paint::cloth::sculpt_cloth_filter_modal(), blender::ed::sculpt_paint::filter::sculpt_mesh_filter_apply(), blender::ed::sculpt_paint::sculpt_transform_all_vertices(), blender::ed::sculpt_paint::store_mesh_from_eval(), and blender::ed::sculpt_paint::transform_radius_elastic().
| void blender::bke::pbvh::Tree::tag_topology_changed | ( | const IndexMask & | node_mask | ) |
Tag nodes that have a different number of vertices or faces (currently just for Type::BMesh).
Definition at line 655 of file pbvh.cc.
References draw_data.
Referenced by BKE_pbvh_bmesh_after_stroke(), and blender::ed::sculpt_paint::dynamic_topology_update().
| void blender::bke::pbvh::Tree::tag_visibility_changed | ( | const IndexMask & | node_mask | ) |
Tag nodes where face or vertex visibility has changed.
Definition at line 646 of file pbvh.cc.
References draw_data, blender::index_mask::IndexMask::min_array_size(), and blender::index_mask::IndexMask::set_bits().
Referenced by blender::ed::sculpt_paint::face_set::face_hide_update(), blender::ed::sculpt_paint::hide::flush_face_changes_node(), blender::ed::sculpt_paint::hide::grid_hide_update(), blender::ed::sculpt_paint::hide::grids_show_all(), blender::ed::sculpt_paint::hide::grow_shrink_visibility_grid(), blender::ed::sculpt_paint::hide::invert_visibility_bmesh(), blender::ed::sculpt_paint::hide::invert_visibility_grids(), blender::ed::sculpt_paint::hide::invert_visibility_mesh(), blender::ed::sculpt_paint::hide::mesh_show_all(), blender::ed::sculpt_paint::hide::partialvis_update_bmesh_nodes(), and blender::ed::sculpt_paint::undo::restore_list().
|
inline |
Definition at line 677 of file BKE_paint_bvh.hh.
Referenced by blender::ed::sculpt_paint::mask::apply_mask_from_settings(), blender::ed::sculpt_paint::average_mask_border_position(), blender::ed::sculpt_paint::average_unmasked_position(), blender::ed::sculpt_paint::smooth::blur_geometry_data_array(), blender::ed::sculpt_paint::brush_delta_update(), blender::ed::sculpt_paint::calc_area_center(), blender::ed::sculpt_paint::calc_area_normal(), blender::ed::sculpt_paint::calc_area_normal_and_center(), blender::ed::sculpt_paint::auto_mask::Cache::calc_cavity_factor(), blender::ed::sculpt_paint::cloth::calc_constraint_factors(), blender::ed::sculpt_paint::filter::calc_enhance_details_filter(), blender::ed::sculpt_paint::expand::calc_falloff_from_vert_and_symmetry(), blender::ed::sculpt_paint::filter::calc_inflate_filter(), blender::ed::sculpt_paint::filter::calc_random_filter(), blender::ed::sculpt_paint::filter::calc_relax_face_sets_filter(), blender::ed::sculpt_paint::filter::calc_relax_filter(), blender::ed::sculpt_paint::filter::calc_scale_filter(), blender::ed::sculpt_paint::filter::calc_sharpen_filter(), blender::ed::sculpt_paint::filter::calc_smooth_filter(), blender::ed::sculpt_paint::calc_smooth_translations(), blender::ed::sculpt_paint::filter::calc_sphere_filter(), blender::ed::sculpt_paint::filter::calc_surface_smooth_filter(), blender::ed::sculpt_paint::expand::calc_topology_falloff_from_verts(), blender::ed::sculpt_paint::trim::can_exec(), blender::ed::sculpt_paint::face_set::change_visibility_exec(), blender::ed::sculpt_paint::face_set::clear_face_sets(), blender::ed::sculpt_paint::cloth::cloth_brush_apply_brush_forces(), blender::ed::sculpt_paint::cloth::cloth_sim_initialize_default_node_state(), blender::ed::sculpt_paint::cloth::copy_normals_to_array(), blender::ed::sculpt_paint::cloth::copy_positions_to_array(), blender::ed::sculpt_paint::face_set::create_op_exec(), blender::ed::sculpt_paint::cursor_geometry_info_update(), blender::ed::sculpt_paint::boundary::data_init(), blender::ed::sculpt_paint::expand::diagonals_falloff_create(), blender::ed::sculpt_paint::boundary::do_bend_brush(), blender::ed::sculpt_paint::boundary::do_boundary_brush(), blender::ed::sculpt_paint::brushes::do_clay_brush(), blender::ed::sculpt_paint::brushes::do_clay_strips_brush(), blender::ed::sculpt_paint::brushes::do_clay_thumb_brush(), blender::ed::sculpt_paint::brushes::do_draw_vector_displacement_brush(), blender::ed::sculpt_paint::brushes::do_elastic_deform_brush(), blender::ed::sculpt_paint::brushes::do_enhance_details_brush(), blender::ed::sculpt_paint::boundary::do_grab_brush(), blender::ed::sculpt_paint::brushes::do_grab_brush(), blender::ed::sculpt_paint::boundary::do_inflate_brush(), blender::ed::sculpt_paint::brushes::do_inflate_brush(), blender::ed::sculpt_paint::brushes::do_layer_brush(), blender::ed::sculpt_paint::brushes::do_mask_brush(), blender::ed::sculpt_paint::brushes::do_multiplane_scrape_brush(), blender::ed::sculpt_paint::brushes::do_pinch_brush(), blender::ed::sculpt_paint::brushes::do_plane_brush(), blender::ed::sculpt_paint::pose::do_pose_brush(), blender::ed::sculpt_paint::brushes::do_rotate_brush(), blender::ed::sculpt_paint::cloth::do_simulation_step(), blender::ed::sculpt_paint::boundary::do_slide_brush(), blender::ed::sculpt_paint::boundary::do_smooth_brush(), blender::ed::sculpt_paint::brushes::do_smooth_brush(), blender::ed::sculpt_paint::brushes::do_smooth_mask_brush(), blender::ed::sculpt_paint::brushes::do_snake_hook_brush(), blender::ed::sculpt_paint::brushes::do_surface_smooth_brush(), blender::ed::sculpt_paint::brushes::do_thumb_brush(), blender::ed::sculpt_paint::brushes::do_topology_slide_brush(), blender::ed::sculpt_paint::boundary::do_twist_brush(), blender::ed::sculpt_paint::face_set::edit_is_operation_valid(), blender::ed::sculpt_paint::cloth::ensure_nodes_constraints(), blender::ed::sculpt_paint::face_set::face_hide_update(), blender::ed::sculpt_paint::face_set::face_sets_update(), blender::ed::sculpt_paint::fake_neighbor_search(), blender::ed::sculpt_paint::mask::fill_mask(), blender::ed::sculpt_paint::find_symm_verts(), blender::ed::sculpt_paint::flush_update_done(), blender::ed::sculpt_paint::flush_update_step(), blender::ed::sculpt_paint::geometry_preview_lines_update(), blender::ed::sculpt_paint::project::gesture_apply_for_symmetry_pass(), blender::ed::sculpt_paint::face_set::gesture_apply_mesh(), blender::ed::sculpt_paint::trim::gesture_begin(), blender::ed::sculpt_paint::pose::grow_pose_factor(), blender::ed::sculpt_paint::hide::hide_show_all_exec(), blender::ed::sculpt_paint::hide::hide_show_masked_exec(), blender::ed::sculpt_paint::pose::ik_chain_init_topology(), blender::ed::sculpt_paint::expand::init_from_face_set_boundary(), blender::ed::sculpt_paint::face_set::init_op_exec(), blender::ed::sculpt_paint::filter::mesh_filter_sharpen_init(), multires_flush_sculpt_updates(), blender::ed::sculpt_paint::no_multires_poll(), nodes(), blender::ed::sculpt_paint::expand::normals_falloff_create(), blender::ed::sculpt_paint::brushes::offset_positions(), blender::ed::sculpt_paint::boundary::preview_data_init(), blender::ed::sculpt_paint::undo::push_begin_ex(), blender::ed::sculpt_paint::undo::push_node(), blender::ed::sculpt_paint::undo::push_nodes(), blender::ed::sculpt_paint::face_set::randomize_colors_exec(), blender::ed::sculpt_paint::undo::restore_color_from_undo_step(), blender::ed::sculpt_paint::undo::restore_face_set_from_undo_step(), blender::ed::sculpt_paint::undo::restore_list(), blender::ed::sculpt_paint::undo::restore_mask_from_undo_step(), blender::ed::sculpt_paint::undo::restore_position_from_undo_step(), blender::ed::sculpt_paint::expand::resursion_step_add(), blender::ed::sculpt_paint::dyntopo::sample_detail(), blender::ed::sculpt_paint::brushes::sample_surface(), blender::ed::sculpt_paint::sculpt_brush_stroke_invoke(), blender::ed::sculpt_paint::cloth::sculpt_cloth_filter_modal(), blender::ed::sculpt_paint::expand::sculpt_expand_invoke(), blender::ed::sculpt_paint::sculpt_find_nearest_to_ray_cb(), blender::ed::sculpt_paint::mask::sculpt_mask_filter_exec(), blender::ed::sculpt_paint::mask::sculpt_mask_init_exec(), blender::ed::sculpt_paint::filter::sculpt_mesh_filter_start(), blender::ed::sculpt_paint::sculpt_raycast_cb(), blender::ed::sculpt_paint::sculpt_transform_all_vertices(), blender::ed::sculpt_paint::cloth::sim_activate_nodes(), blender::ed::sculpt_paint::expand::snap_init_from_enabled(), blender::ed::sculpt_paint::expand::spherical_falloff_create(), stats_object_sculpt(), blender::ed::sculpt_paint::stroke_get_location_bvh_ex(), blender::ed::sculpt_paint::dyntopo::stroke_is_dyntopo(), blender::ed::sculpt_paint::symmetrize_exec(), blender::ed::sculpt_paint::transform_radius_elastic(), update_bounds(), blender::ed::sculpt_paint::expand::update_for_vert(), update_normals(), blender::ed::sculpt_paint::expand::vert_to_face_falloff(), blender::ed::sculpt_paint::vertex_is_occluded(), blender::ed::sculpt_paint::hide::visibility_filter_exec(), blender::ed::sculpt_paint::hide::visibility_invert_exec(), and blender::ed::sculpt_paint::expand::write_mask_data().
| void blender::bke::pbvh::Tree::update_bounds | ( | const Depsgraph & | depsgraph, |
| const Object & | object ) |
Recalculate node bounding boxes based on the current coordinates. Calculation is only done for affected nodes that have been tagged by #PBVH::tag_positions_changed().
Definition at line 1386 of file pbvh.cc.
References SculptSession::bm, blender::bke::pbvh::BMesh, depsgraph, SubdivCCG::grid_area, blender::bke::pbvh::Grids, blender::bke::pbvh::Mesh, SubdivCCG::positions, SculptSession::subdiv_ccg, type(), update_bounds_bmesh(), update_bounds_grids(), update_bounds_mesh(), and blender::bke::pbvh::vert_positions_eval().
Referenced by blender::ed::sculpt_paint::cancel_modal_transform(), blender::ed::sculpt_paint::brushes::do_smooth_brush(), blender::ed::sculpt_paint::brushes::do_surface_smooth_brush(), blender::ed::sculpt_paint::face_set::edit_modify_coordinates(), blender::ed::sculpt_paint::undo::restore_list(), blender::ed::sculpt_paint::filter::sculpt_mesh_filter_apply(), blender::ed::sculpt_paint::filter::sculpt_mesh_filter_cancel(), and blender::ed::sculpt_paint::store_mesh_from_eval().
| void blender::bke::pbvh::Tree::update_bounds_bmesh | ( | const BMesh & | bm | ) |
Definition at line 1373 of file pbvh.cc.
References flush_bounds_to_parents(), blender::index_mask::IndexMask::foreach_index(), blender::IndexMask::from_bits(), i, blender::index_mask::IndexMask::is_empty(), nodes(), and blender::bke::pbvh::update_node_bounds_bmesh().
Referenced by update_bounds().
Definition at line 1359 of file pbvh.cc.
References flush_bounds_to_parents(), blender::index_mask::IndexMask::foreach_index(), blender::IndexMask::from_bits(), i, blender::index_mask::IndexMask::is_empty(), nodes(), and blender::bke::pbvh::update_node_bounds_grids().
Referenced by update_bounds().
Definition at line 1346 of file pbvh.cc.
References flush_bounds_to_parents(), blender::index_mask::IndexMask::foreach_index(), blender::IndexMask::from_bits(), i, blender::index_mask::IndexMask::is_empty(), nodes(), and blender::bke::pbvh::update_node_bounds_mesh().
Referenced by update_bounds().
Definition at line 1229 of file pbvh.cc.
References BKE_subdiv_ccg_update_normals(), blender::bke::pbvh::BMesh, blender::bke::pbvh::bmesh_normals_update(), blender::IndexMask::from_bits(), blender::bke::pbvh::Grids, blender::bke::pbvh::Mesh, nodes(), blender::bke::pbvh::nodes_to_face_selection_grids(), Object::sculpt, SculptSession::subdiv_ccg, type(), and blender::bke::pbvh::update_normals_mesh().
| void blender::bke::pbvh::Tree::update_visibility | ( | const Object & | object | ) |
Definition at line 1579 of file pbvh.cc.
References blender::bke::pbvh::BMesh, blender::IndexMask::from_bits(), blender::bke::pbvh::Grids, blender::index_mask::IndexMask::is_empty(), blender::bke::pbvh::Mesh, nodes(), SculptSession::subdiv_ccg, update_visibility(), blender::bke::pbvh::update_visibility_bmesh(), blender::bke::pbvh::update_visibility_faces(), and blender::bke::pbvh::update_visibility_grids().
Referenced by blender::ed::sculpt_paint::face_set::change_visibility_exec(), blender::ed::sculpt_paint::hide::grids_show_all(), blender::ed::sculpt_paint::hide::grow_shrink_visibility_grid(), blender::ed::sculpt_paint::hide::invert_visibility_mesh(), blender::ed::sculpt_paint::hide::mesh_show_all(), blender::ed::sculpt_paint::hide::partialvis_update_bmesh_nodes(), blender::ed::sculpt_paint::undo::restore_list(), and update_visibility().
| std::unique_ptr<DrawCache> blender::bke::pbvh::Tree::draw_data |
Definition at line 264 of file BKE_paint_bvh.hh.
Referenced by tag_attribute_changed(), tag_face_sets_changed(), tag_masks_changed(), tag_positions_changed(), tag_topology_changed(), tag_visibility_changed(), and blender::ed::sculpt_paint::hide::update_node_visibility_from_face_changes().
| std::variant<Vector<MeshNode>, Vector<GridsNode>, Vector<BMeshNode> > blender::bke::pbvh::Tree::nodes_ |
Definition at line 260 of file BKE_paint_bvh.hh.
Referenced by BKE_pbvh_bmesh_after_stroke(), BKE_pbvh_mark_rebuild_pixels(), flush_bounds_to_parents(), nodes(), nodes(), nodes_num(), blender::bke::pbvh::pbvh_iter_next(), blender::bke::pbvh::pbvh_iter_next_occluded(), and ~Tree().
| pixels::PBVHData* blender::bke::pbvh::Tree::pixels_ = nullptr |
Definition at line 262 of file BKE_paint_bvh.hh.