Blender V4.3
sculpt_automasking.cc File Reference
#include "sculpt_automask.hh"
#include "MEM_guardedalloc.h"
#include "BLI_array.hh"
#include "BLI_hash.h"
#include "BLI_index_range.hh"
#include "BLI_math_base.hh"
#include "BLI_math_base_safe.h"
#include "BLI_math_vector.h"
#include "BLI_math_vector_types.hh"
#include "BLI_set.hh"
#include "BLI_vector.hh"
#include "DNA_brush_types.h"
#include "DNA_mesh_types.h"
#include "BKE_colortools.hh"
#include "BKE_paint.hh"
#include "BKE_pbvh_api.hh"
#include "BKE_subdiv_ccg.hh"
#include "mesh_brush_common.hh"
#include "paint_intern.hh"
#include "sculpt_boundary.hh"
#include "sculpt_dyntopo.hh"
#include "sculpt_face_set.hh"
#include "sculpt_filter.hh"
#include "sculpt_flood_fill.hh"
#include "sculpt_intern.hh"
#include "sculpt_islands.hh"
#include "sculpt_undo.hh"
#include "bmesh.hh"
#include <cmath>
#include <cstdlib>

Go to the source code of this file.

Classes

struct  blender::ed::sculpt_paint::auto_mask::AccumulatedVert
 

Namespaces

namespace  blender
 
namespace  blender::ed
 
namespace  blender::ed::sculpt_paint
 
namespace  blender::ed::sculpt_paint::auto_mask
 

Enumerations

enum class  blender::ed::sculpt_paint::auto_mask::BoundaryAutomaskMode { blender::ed::sculpt_paint::auto_mask::Edges = 1 , blender::ed::sculpt_paint::auto_mask::FaceSets = 2 }
 

Functions

const Cacheblender::ed::sculpt_paint::auto_mask::active_cache_get (const SculptSession &ss)
 
bool blender::ed::sculpt_paint::auto_mask::mode_enabled (const Sculpt &sd, const Brush *br, eAutomasking_flag mode)
 
bool blender::ed::sculpt_paint::auto_mask::is_enabled (const Sculpt &sd, const Object &object, const Brush *br)
 
static int blender::ed::sculpt_paint::auto_mask::calc_effective_bits (const Sculpt &sd, const Brush *brush)
 
bool blender::ed::sculpt_paint::auto_mask::needs_normal (const SculptSession &ss, const Sculpt &sd, const Brush *brush)
 
static float blender::ed::sculpt_paint::auto_mask::normal_calc (const float3 &compare_normal, const float3 &normal, float limit_lower, float limit_upper)
 
static bool blender::ed::sculpt_paint::auto_mask::is_constrained_by_radius (const Brush *br)
 
static int blender::ed::sculpt_paint::auto_mask::boundary_propagation_steps (const Sculpt &sd, const Brush *brush)
 
static bool blender::ed::sculpt_paint::auto_mask::needs_factors_cache (const Sculpt &sd, const Brush *brush)
 
static float blender::ed::sculpt_paint::auto_mask::calc_brush_normal_factor (const Cache &automasking, const Object &object, const float3 &normal)
 
static float blender::ed::sculpt_paint::auto_mask::calc_view_normal_factor (const Cache &automasking, const Object &object, const float3 &normal)
 
static bool blender::ed::sculpt_paint::auto_mask::calc_view_occlusion_factor (const Depsgraph &depsgraph, Cache &automasking, const Object &object, const int vert, const float3 &vert_position)
 
static float blender::ed::sculpt_paint::auto_mask::calc_cavity_factor (const Cache &automasking, float factor)
 
static void blender::ed::sculpt_paint::auto_mask::calc_blurred_cavity_mesh (const Depsgraph &depsgraph, const Object &object, const Cache &automasking, const int steps, const int vert, MutableSpan< float > cavity_factors)
 
static void blender::ed::sculpt_paint::auto_mask::calc_blurred_cavity_grids (const Object &object, const Cache &automasking, const int steps, const SubdivCCGCoord vert, MutableSpan< float > cavity_factors)
 
static void blender::ed::sculpt_paint::auto_mask::calc_blurred_cavity_bmesh (const Cache &automasking, const int steps, BMVert *vert, MutableSpan< float > cavity_factors)
 
static float blender::ed::sculpt_paint::auto_mask::process_cavity_factor (const Cache &automasking, float factor)
 
static float blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_mesh (const Depsgraph &depsgraph, const Cache &automasking, const Object &object, const int vert)
 
static float blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_grids (const CCGKey &key, const Cache &automasking, const Object &object, const int vert)
 
static float blender::ed::sculpt_paint::auto_mask::calc_cavity_factor_bmesh (const Cache &automasking, BMVert *vert, const int vert_i)
 
void blender::ed::sculpt_paint::auto_mask::calc_vert_factors (const Depsgraph &depsgraph, const Object &object, const Cache &cache, const bke::pbvh::MeshNode &node, Span< int > verts, MutableSpan< float > factors)
 
void blender::ed::sculpt_paint::auto_mask::calc_face_factors (const Depsgraph &depsgraph, const Object &object, OffsetIndices< int > faces, Span< int > corner_verts, const Cache &cache, const bke::pbvh::MeshNode &node, Span< int > face_indices, MutableSpan< float > factors)
 
void blender::ed::sculpt_paint::auto_mask::calc_grids_factors (const Depsgraph &depsgraph, const Object &object, const Cache &cache, const bke::pbvh::GridsNode &node, Span< int > grids, MutableSpan< float > factors)
 
void blender::ed::sculpt_paint::auto_mask::calc_vert_factors (const Depsgraph &depsgraph, const Object &object, const Cache &cache, const bke::pbvh::BMeshNode &node, const Set< BMVert *, 0 > &verts, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::fill_topology_automasking_factors_mesh (const Depsgraph &depsgraph, const Sculpt &sd, Object &ob, const Span< float3 > vert_positions, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::fill_topology_automasking_factors_grids (const Sculpt &sd, Object &ob, const SubdivCCG &subdiv_ccg, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::fill_topology_automasking_factors_bmesh (const Sculpt &sd, Object &ob, BMesh &bm, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::fill_topology_automasking_factors (const Depsgraph &depsgraph, const Sculpt &sd, Object &ob, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::init_face_sets_masking (const Sculpt &sd, Object &ob, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::init_boundary_masking_mesh (Object &object, const Depsgraph &depsgraph, const BoundaryAutomaskMode mode, const int propagation_steps, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::init_boundary_masking_grids (Object &object, const BoundaryAutomaskMode mode, const int propagation_steps, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::init_boundary_masking_bmesh (Object &object, const BoundaryAutomaskMode mode, const int propagation_steps, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::init_boundary_masking (Object &object, const Depsgraph &depsgraph, const BoundaryAutomaskMode mode, const int propagation_steps, MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::auto_mask::cache_settings_update (Cache &automasking, Object &object, const Sculpt &sd, const Brush *brush)
 
static void blender::ed::sculpt_paint::auto_mask::normal_occlusion_automasking_fill (const Depsgraph &depsgraph, Cache &automasking, Object &ob, eAutomasking_flag mode, MutableSpan< float > factors)
 
bool blender::ed::sculpt_paint::auto_mask::brush_type_can_reuse_automask (int sculpt_brush_type)
 
std::unique_ptr< Cacheblender::ed::sculpt_paint::auto_mask::cache_init (const Depsgraph &depsgraph, const Sculpt &sd, Object &ob)
 
std::unique_ptr< Cacheblender::ed::sculpt_paint::auto_mask::cache_init (const Depsgraph &depsgraph, const Sculpt &sd, const Brush *brush, Object &ob)
 

Variables

static constexpr int blender::ed::sculpt_paint::auto_mask::EDGE_DISTANCE_INF = -1