Blender V4.3
sculpt_filter_mesh.cc File Reference
#include "sculpt_filter.hh"
#include <fmt/format.h>
#include "DNA_windowmanager_types.h"
#include "MEM_guardedalloc.h"
#include "BLI_enumerable_thread_specific.hh"
#include "BLI_hash.h"
#include "BLI_index_range.hh"
#include "BLI_math_base.hh"
#include "BLI_math_matrix.h"
#include "BLI_math_matrix.hh"
#include "BLI_math_vector.h"
#include "BLI_math_vector_types.hh"
#include "BLI_task.h"
#include "BLT_translation.hh"
#include "BKE_brush.hh"
#include "BKE_context.hh"
#include "BKE_layer.hh"
#include "BKE_mesh.hh"
#include "BKE_modifier.hh"
#include "BKE_object_types.hh"
#include "BKE_paint.hh"
#include "BKE_pbvh_api.hh"
#include "WM_api.hh"
#include "WM_types.hh"
#include "ED_screen.hh"
#include "ED_sculpt.hh"
#include "ED_view3d.hh"
#include "mesh_brush_common.hh"
#include "paint_intern.hh"
#include "sculpt_automask.hh"
#include "sculpt_boundary.hh"
#include "sculpt_cloth.hh"
#include "sculpt_face_set.hh"
#include "sculpt_intern.hh"
#include "sculpt_smooth.hh"
#include "sculpt_undo.hh"
#include "RNA_access.hh"
#include "RNA_define.hh"
#include "RNA_prototypes.hh"
#include "UI_interface.hh"
#include "UI_resources.hh"
#include "bmesh.hh"
#include <cmath>
#include <cstdlib>

Go to the source code of this file.

Namespaces

namespace  blender
 
namespace  blender::ed
 
namespace  blender::ed::sculpt_paint
 
namespace  blender::ed::sculpt_paint::filter
 

Enumerations

enum class  blender::ed::sculpt_paint::filter::MeshFilterType {
  blender::ed::sculpt_paint::filter::Smooth = 0 , blender::ed::sculpt_paint::filter::Scale = 1 , blender::ed::sculpt_paint::filter::Inflate = 2 , blender::ed::sculpt_paint::filter::Sphere = 3 ,
  blender::ed::sculpt_paint::filter::Random = 4 , blender::ed::sculpt_paint::filter::Relax = 5 , blender::ed::sculpt_paint::filter::RelaxFaceSets = 6 , blender::ed::sculpt_paint::filter::SurfaceSmooth = 7 ,
  blender::ed::sculpt_paint::filter::Sharpen = 8 , blender::ed::sculpt_paint::filter::EnhanceDetails = 9 , blender::ed::sculpt_paint::filter::EraseDisplacement = 10
}
 
enum  blender::ed::sculpt_paint::filter::eMeshFilterDeformAxis { blender::ed::sculpt_paint::filter::MESH_FILTER_DEFORM_X = 1 << 0 , blender::ed::sculpt_paint::filter::MESH_FILTER_DEFORM_Y = 1 << 1 , blender::ed::sculpt_paint::filter::MESH_FILTER_DEFORM_Z = 1 << 2 }
 
enum  { blender::ed::sculpt_paint::filter::FILTER_MESH_MODAL_CANCEL = 1 , blender::ed::sculpt_paint::filter::FILTER_MESH_MODAL_CONFIRM }
 

Functions

float3x3 blender::ed::sculpt_paint::filter::to_orientation_space (const filter::Cache &filter_cache)
 
float3x3 blender::ed::sculpt_paint::filter::to_object_space (const filter::Cache &filter_cache)
 
void blender::ed::sculpt_paint::filter::zero_disabled_axis_components (const filter::Cache &filter_cache, MutableSpan< float3 > vectors)
 
void blender::ed::sculpt_paint::filter::cache_init (bContext *C, Object &ob, const Sculpt &sd, undo::Type undo_type, const float mval_fl[2], float area_normal_radius, float start_strength)
 
static bool blender::ed::sculpt_paint::filter::sculpt_mesh_filter_needs_pmap (MeshFilterType filter_type)
 
static bool blender::ed::sculpt_paint::filter::sculpt_mesh_filter_is_continuous (MeshFilterType type)
 
static BLI_NOINLINE void blender::ed::sculpt_paint::filter::clamp_factors (const MutableSpan< float > factors, const float min, const float max)
 
static void blender::ed::sculpt_paint::filter::calc_smooth_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static void blender::ed::sculpt_paint::filter::calc_inflate_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static void blender::ed::sculpt_paint::filter::calc_scale_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static BLI_NOINLINE void blender::ed::sculpt_paint::filter::calc_sphere_translations (const Span< float3 > positions, const Span< float > factors, const MutableSpan< float3 > translations)
 
static void blender::ed::sculpt_paint::filter::calc_sphere_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static BLI_NOINLINE void blender::ed::sculpt_paint::filter::randomize_factors (const Span< float3 > positions, const int seed, const MutableSpan< float > factors)
 
static void blender::ed::sculpt_paint::filter::calc_random_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static void blender::ed::sculpt_paint::filter::calc_relax_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static void blender::ed::sculpt_paint::filter::calc_relax_face_sets_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static void blender::ed::sculpt_paint::filter::calc_surface_smooth_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static BLI_NOINLINE void blender::ed::sculpt_paint::filter::calc_sharpen_detail_translations (const filter::Cache &filter_cache, const Span< float3 > positions, const Span< float3 > smooth_positions, const Span< float > sharpen_factors, const Span< float3 > detail_directions, const MutableSpan< float3 > translations)
 
static void blender::ed::sculpt_paint::filter::calc_sharpen_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static void blender::ed::sculpt_paint::filter::calc_enhance_details_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static void blender::ed::sculpt_paint::filter::calc_erase_displacement_filter (const Depsgraph &depsgraph, const Sculpt &sd, const float strength, Object &object, const IndexMask &node_mask)
 
static void blender::ed::sculpt_paint::filter::mesh_filter_surface_smooth_init (Object &object, const float shape_preservation, const float current_vertex_displacement)
 
static void blender::ed::sculpt_paint::filter::calc_limit_surface_positions (const Object &object, MutableSpan< float3 > limit_positions)
 
static void blender::ed::sculpt_paint::filter::mesh_filter_sharpen_init (const Depsgraph &depsgraph, const Object &object, const float smooth_ratio, const float intensify_detail_strength, const int curvature_smooth_iterations, filter::Cache &filter_cache)
 
wmKeyMapblender::ed::sculpt_paint::filter::modal_keymap (wmKeyConfig *keyconf)
 
static void blender::ed::sculpt_paint::filter::sculpt_mesh_update_status_bar (bContext *C, wmOperator *)
 
static void blender::ed::sculpt_paint::filter::sculpt_mesh_filter_apply (bContext *C, wmOperator *op)
 
static void blender::ed::sculpt_paint::filter::sculpt_mesh_update_strength (wmOperator *op, SculptSession &ss, float2 prev_press_mouse, float2 mouse)
 
static void blender::ed::sculpt_paint::filter::sculpt_mesh_filter_apply_with_history (bContext *C, wmOperator *op)
 
static void blender::ed::sculpt_paint::filter::sculpt_mesh_filter_end (bContext *C)
 
static int blender::ed::sculpt_paint::filter::sculpt_mesh_filter_confirm (SculptSession &ss, wmOperator *op, const MeshFilterType filter_type)
 
static void blender::ed::sculpt_paint::filter::sculpt_mesh_filter_cancel (bContext *C, wmOperator *)
 
static int blender::ed::sculpt_paint::filter::sculpt_mesh_filter_modal (bContext *C, wmOperator *op, const wmEvent *event)
 
static void blender::ed::sculpt_paint::filter::sculpt_filter_specific_init (const Depsgraph &depsgraph, const MeshFilterType filter_type, wmOperator *op, Object &object)
 
static int blender::ed::sculpt_paint::filter::sculpt_mesh_filter_start (bContext *C, wmOperator *op)
 
static int blender::ed::sculpt_paint::filter::sculpt_mesh_filter_invoke (bContext *C, wmOperator *op, const wmEvent *event)
 
static int blender::ed::sculpt_paint::filter::sculpt_mesh_filter_exec (bContext *C, wmOperator *op)
 
void blender::ed::sculpt_paint::filter::register_operator_props (wmOperatorType *ot)
 
static void blender::ed::sculpt_paint::filter::sculpt_mesh_ui_exec (bContext *, wmOperator *op)
 
void blender::ed::sculpt_paint::filter::SCULPT_OT_mesh_filter (wmOperatorType *ot)
 

Variables

static EnumPropertyItem blender::ed::sculpt_paint::filter::prop_mesh_filter_types []
 
static EnumPropertyItem blender::ed::sculpt_paint::filter::prop_mesh_filter_deform_axis_items []
 
static EnumPropertyItem blender::ed::sculpt_paint::filter::prop_mesh_filter_orientation_items []