Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/sculpt_paint/curves_sculpt_smooth.cc
| Show First 20 Lines • Show All 72 Lines • ▼ Show 20 Lines | void execute(SmoothOperation &self, const bContext &C, const StrokeExtension &stroke_extension) | ||||
| curves_sculpt_ = ctx_.scene->toolsettings->curves_sculpt; | curves_sculpt_ = ctx_.scene->toolsettings->curves_sculpt; | ||||
| brush_ = BKE_paint_brush_for_read(&curves_sculpt_->paint); | brush_ = BKE_paint_brush_for_read(&curves_sculpt_->paint); | ||||
| brush_radius_base_re_ = BKE_brush_size_get(ctx_.scene, brush_); | brush_radius_base_re_ = BKE_brush_size_get(ctx_.scene, brush_); | ||||
| brush_radius_factor_ = brush_radius_factor(*brush_, stroke_extension); | brush_radius_factor_ = brush_radius_factor(*brush_, stroke_extension); | ||||
| brush_strength_ = brush_strength_get(*ctx_.scene, *brush_, stroke_extension); | brush_strength_ = brush_strength_get(*ctx_.scene, *brush_, stroke_extension); | ||||
| brush_pos_re_ = stroke_extension.mouse_position; | brush_pos_re_ = stroke_extension.mouse_position; | ||||
| point_factors_ = get_point_selection(*curves_id_); | point_factors_ = curves_->attributes().lookup_or_default<float>( | ||||
| curve_selection_ = retrieve_selected_curves(*curves_id_, selected_curve_indices_); | ".selection", ATTR_DOMAIN_POINT, 1.0f); | ||||
| curve_selection_ = curves::retrieve_selected_curves(*curves_id_, selected_curve_indices_); | |||||
| transforms_ = CurvesSurfaceTransforms(*object_, curves_id_->surface); | transforms_ = CurvesSurfaceTransforms(*object_, curves_id_->surface); | ||||
| const eBrushFalloffShape falloff_shape = static_cast<eBrushFalloffShape>( | const eBrushFalloffShape falloff_shape = static_cast<eBrushFalloffShape>( | ||||
| brush_->falloff_shape); | brush_->falloff_shape); | ||||
| if (stroke_extension.is_first) { | if (stroke_extension.is_first) { | ||||
| if (falloff_shape == PAINT_FALLOFF_SHAPE_SPHERE) { | if (falloff_shape == PAINT_FALLOFF_SHAPE_SPHERE) { | ||||
| self.brush_3d_ = *sample_curves_3d_brush(*ctx_.depsgraph, | self.brush_3d_ = *sample_curves_3d_brush(*ctx_.depsgraph, | ||||
| *ctx_.region, | *ctx_.region, | ||||
| ▲ Show 20 Lines • Show All 171 Lines • Show Last 20 Lines | |||||