Blender V5.0
blender::ed::sculpt_paint::gesture Namespace Reference

Classes

struct  LassoData
struct  LineData
struct  GestureData
struct  Operation

Enumerations

enum  ShapeType { Box = 0 , Lasso = 1 , Line = 2 }
enum class  SelectionType { Inside = 0 , Outside = 1 }

Functions

void operator_properties (wmOperatorType *ot, ShapeType shapeType)
static void init_common (bContext *C, const wmOperator *op, GestureData &gesture_data)
static void lasso_px_cb (const int x, const int x_end, const int y, void *user_data)
std::unique_ptr< GestureDatainit_from_polyline (bContext *C, wmOperator *op)
std::unique_ptr< GestureDatainit_from_lasso (bContext *C, wmOperator *op)
std::unique_ptr< GestureDatainit_from_box (bContext *C, wmOperator *op)
static void line_plane_from_tri (float *r_plane, const GestureData &gesture_data, const bool flip, const float3 &p1, const float3 &p2, const float3 &p3)
static void line_calculate_plane_points (const GestureData &gesture_data, const Span< float2 > line_points, std::array< float3, 4 > &r_plane_points, std::array< float3, 2 > &r_offset_plane_points)
std::unique_ptr< GestureDatainit_from_line (bContext *C, const wmOperator *op)
static void flip_plane (float out[4], const float in[4], const char symm)
static void flip_for_symmetry_pass (GestureData &gesture_data, const ePaintSymmetryFlags symmpass)
static void update_affected_nodes_by_line_plane (GestureData &gesture_data)
static void update_affected_nodes_by_clip_planes (GestureData &gesture_data)
static void update_affected_nodes (GestureData &gesture_data)
static bool is_affected_lasso (const GestureData &gesture_data, const float3 &position)
bool is_affected (const GestureData &gesture_data, const float3 &position, const float3 &normal)
void filter_factors (const GestureData &gesture_data, const Span< float3 > positions, const Span< float3 > normals, const MutableSpan< float > factors)
void apply (bContext &C, GestureData &gesture_data, wmOperator &op)

Enumeration Type Documentation

◆ SelectionType

Enumerator
Inside 
Outside 

Definition at line 38 of file sculpt_gesture.hh.

◆ ShapeType

Enumerator
Box 
Lasso 
Line 

Definition at line 29 of file sculpt_gesture.hh.

Function Documentation

◆ apply()

void blender::ed::sculpt_paint::gesture::apply ( bContext & C,
GestureData & gesture_data,
wmOperator & op )

Definition at line 451 of file sculpt_gesture.cc.

References apply(), blender::ed::sculpt_paint::gesture::Operation::apply_for_symmetry_pass, blender::ed::sculpt_paint::gesture::Operation::begin, C, blender::ed::sculpt_paint::gesture::Operation::end, flip_for_symmetry_pass(), blender::ed::sculpt_paint::is_symmetry_iteration_valid(), blender::ed::sculpt_paint::gesture::GestureData::operation, SCULPT_tag_update_overlays(), blender::ed::sculpt_paint::gesture::GestureData::symm, and update_affected_nodes().

Referenced by apply(), blender::ed::sculpt_paint::face_set::gesture_box_exec(), blender::ed::sculpt_paint::mask::gesture_box_exec(), blender::ed::sculpt_paint::trim::gesture_box_exec(), blender::ed::sculpt_paint::face_set::gesture_lasso_exec(), blender::ed::sculpt_paint::mask::gesture_lasso_exec(), blender::ed::sculpt_paint::trim::gesture_lasso_exec(), blender::ed::sculpt_paint::face_set::gesture_line_exec(), blender::ed::sculpt_paint::mask::gesture_line_exec(), blender::ed::sculpt_paint::project::gesture_line_exec(), blender::ed::sculpt_paint::trim::gesture_line_exec(), blender::ed::sculpt_paint::face_set::gesture_polyline_exec(), blender::ed::sculpt_paint::mask::gesture_polyline_exec(), blender::ed::sculpt_paint::trim::gesture_polyline_exec(), blender::ed::sculpt_paint::hide::hide_show_gesture_box_exec(), blender::ed::sculpt_paint::hide::hide_show_gesture_lasso_exec(), blender::ed::sculpt_paint::hide::hide_show_gesture_line_exec(), and blender::ed::sculpt_paint::hide::hide_show_gesture_polyline_exec().

◆ filter_factors()

void blender::ed::sculpt_paint::gesture::filter_factors ( const GestureData & gesture_data,
const Span< float3 > positions,
const Span< float3 > normals,
const MutableSpan< float > factors )

◆ flip_for_symmetry_pass()

◆ flip_plane()

void blender::ed::sculpt_paint::gesture::flip_plane ( float out[4],
const float in[4],
const char symm )
static

Definition at line 284 of file sculpt_gesture.cc.

References in, out, PAINT_SYMM_X, PAINT_SYMM_Y, and PAINT_SYMM_Z.

Referenced by flip_for_symmetry_pass().

◆ init_common()

◆ init_from_box()

◆ init_from_lasso()

◆ init_from_line()

◆ init_from_polyline()

◆ is_affected()

◆ is_affected_lasso()

◆ lasso_px_cb()

void blender::ed::sculpt_paint::gesture::lasso_px_cb ( const int x,
const int x_end,
const int y,
void * user_data )
static

◆ line_calculate_plane_points()

void blender::ed::sculpt_paint::gesture::line_calculate_plane_points ( const GestureData & gesture_data,
const Span< float2 > line_points,
std::array< float3, 4 > & r_plane_points,
std::array< float3, 2 > & r_offset_plane_points )
static

◆ line_plane_from_tri()

void blender::ed::sculpt_paint::gesture::line_plane_from_tri ( float * r_plane,
const GestureData & gesture_data,
const bool flip,
const float3 & p1,
const float3 & p2,
const float3 & p3 )
static

◆ operator_properties()

◆ update_affected_nodes()

void blender::ed::sculpt_paint::gesture::update_affected_nodes ( GestureData & gesture_data)
static

◆ update_affected_nodes_by_clip_planes()

◆ update_affected_nodes_by_line_plane()