|
Blender V5.0
|
#include <sculpt_automask.hh>
Public Types | |
| enum class | OcclusionValue : int8_t { Unknown = 0 , Visible = 1 , Occluded = 2 } |
Public Member Functions | |
| void | calc_cavity_factor (const Depsgraph &depsgraph, const Object &object, const IndexMask &node_mask) |
Public Attributes | |
| Settings | settings |
| Array< float > | factor |
| Array< OcclusionValue > | occlusion |
| Array< float > | cavity_factor |
Definition at line 49 of file sculpt_automask.hh.
|
strong |
| Enumerator | |
|---|---|
| Unknown | |
| Visible | |
| Occluded | |
Definition at line 55 of file sculpt_automask.hh.
| void blender::ed::sculpt_paint::auto_mask::Cache::calc_cavity_factor | ( | const Depsgraph & | depsgraph, |
| const Object & | object, | ||
| const IndexMask & | node_mask ) |
Calculates the cavity factor for a set of nodes.
Has no effect on an individual node level if the factor for a vertex has already been calculated. This data is best calculated outside of any loops that affect the stroke's position, as the curvature calculation is sensitive to small changes, meaning processing inside the normal brush update step may result in odd artifacts from ordering of position updates.
Definition at line 1745 of file sculpt_automasking.cc.
References BKE_subdiv_ccg_key_top_level(), BLI_assert, BM_elem_index_get, blender::bke::pbvh::BMesh, BRUSH_AUTOMASKING_CAVITY_ALL, calc_cavity_factor(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_bmesh(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_grids(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_mesh(), cavity_factor, depsgraph, blender::index_mask::IndexMask::foreach_index(), SubdivCCG::grid_area, blender::bke::ccg::grid_range(), blender::bke::pbvh::Grids, i, blender::bke::pbvh::Mesh, blender::bke::pbvh::Tree::nodes(), blender::bke::object::pbvh_get(), settings, SculptSession::subdiv_ccg, blender::bke::pbvh::Tree::type(), and verts.
Referenced by calc_cavity_factor(), and blender::ed::sculpt_paint::do_brush_action().
Cached cavity factor values for each vertex.
Definition at line 76 of file sculpt_automask.hh.
Referenced by calc_cavity_factor(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_bmesh(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_grids(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_mesh(), blender::ed::sculpt_paint::auto_mask::calc_face_factors(), blender::ed::sculpt_paint::auto_mask::calc_grids_factors(), blender::ed::sculpt_paint::auto_mask::calc_vert_factors(), and blender::ed::sculpt_paint::auto_mask::calc_vert_factors().
Cached factor for auto-masking modes that are implemented to process the entire mesh.
Definition at line 53 of file sculpt_automask.hh.
Referenced by blender::ed::sculpt_paint::auto_mask::calc_face_factors(), blender::ed::sculpt_paint::auto_mask::calc_grids_factors(), blender::ed::sculpt_paint::auto_mask::calc_vert_factors(), and blender::ed::sculpt_paint::auto_mask::calc_vert_factors().
| Array<OcclusionValue> blender::ed::sculpt_paint::auto_mask::Cache::occlusion |
Cached occlusion values for each vertex. Since calculating the occlusion is so expensive, it's only calculated at the beginning of a stroke and stored for later.
Definition at line 69 of file sculpt_automask.hh.
Referenced by blender::ed::sculpt_paint::auto_mask::calc_view_occlusion_factor().
| Settings blender::ed::sculpt_paint::auto_mask::Cache::settings |
Definition at line 50 of file sculpt_automask.hh.
Referenced by blender::ed::sculpt_paint::auto_mask::cache_settings_update(), blender::ed::sculpt_paint::auto_mask::calc_brush_normal_factor(), calc_cavity_factor(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_bmesh(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_grids(), blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_mesh(), blender::ed::sculpt_paint::auto_mask::calc_face_factors(), blender::ed::sculpt_paint::auto_mask::calc_grids_factors(), blender::ed::sculpt_paint::auto_mask::calc_vert_factors(), blender::ed::sculpt_paint::auto_mask::calc_vert_factors(), blender::ed::sculpt_paint::auto_mask::calc_view_normal_factor(), blender::ed::sculpt_paint::do_brush_action(), and blender::ed::sculpt_paint::auto_mask::process_cavity_factor().