|
Blender V4.3
|
Namespaces | |
| namespace | add_bezier |
| namespace | add_circle |
| namespace | clear_tilt |
| namespace | convert_from_particle_system |
| namespace | convert_to_particle_system |
| namespace | curve_type_set |
| namespace | curves_delete |
| namespace | curves_duplicate |
| namespace | cyclic_toggle |
| namespace | set_handle_type |
| namespace | set_selection_domain |
| namespace | snap_curves_to_surface |
| namespace | subdivide |
| namespace | surface_set |
| namespace | switch_direction |
| namespace | undo |
Classes | |
| struct | CurveDrawData |
| class | CurvesGeometry |
| struct | FindClosestData |
| struct | StrokeElem |
Typedefs | |
| using | SelectionRangeFn |
StrokeElem / #RNA_OperatorStrokeElement Conversion Functions | |
| enum | CurveDrawState { CURVE_DRAW_IDLE = 0 , CURVE_DRAW_PAINTING = 1 } |
| static float | stroke_elem_radius_from_pressure (const CurveDrawData *cdd, const float pressure) |
| static float | stroke_elem_radius (const CurveDrawData *cdd, const StrokeElem *selem) |
| static void | stroke_elem_pressure_set (const CurveDrawData *cdd, StrokeElem *selem, float pressure) |
| static void | stroke_elem_interp (StrokeElem *selem_out, const StrokeElem *selem_a, const StrokeElem *selem_b, float t) |
| static bool | stroke_elem_project (const CurveDrawData *cdd, const int mval_i[2], const float mval_fl[2], float surface_offset, const float radius, float r_location_world[3], float r_normal_world[3]) |
| static bool | stroke_elem_project_fallback (const CurveDrawData *cdd, const int mval_i[2], const float mval_fl[2], const float surface_offset, const float radius, const float location_fallback_depth[3], float r_location_world[3], float r_location_local[3], float r_normal_world[3], float r_normal_local[3]) |
| static bool | stroke_elem_project_fallback_elem (const CurveDrawData *cdd, const float location_fallback_depth[3], StrokeElem *selem) |
The code below uses a suffix naming convention to indicate the coordinate space: cu: Local space of the curves object that is being edited. su: Local space of the surface object. wo: World space. ha: Local space of an individual hair in the legacy hair system.
Definition at line 84 of file ED_curves.hh.
| Enumerator | |
|---|---|
| CURVE_DRAW_IDLE | |
| CURVE_DRAW_PAINTING | |
Definition at line 69 of file curves_draw.cc.
|
static |
Definition at line 45 of file curves_attribute_set.cc.
References blender::ed::geometry::attribute_set_poll(), C, CTX_data_active_object(), and editable_curves_in_edit_mode_poll().
Referenced by CURVES_OT_attribute_set().
| void blender::ed::curves::add_curves | ( | bke::CurvesGeometry & | curves, |
| Span< int > | new_sizes ) |
Adds new curves to curves.
| new_sizes | The new size for each curve. Sizes must be > 0. |
Definition at line 226 of file curves_edit.cc.
References blender::offset_indices::accumulate_counts_to_offsets(), blender::MutableSpan< T >::copy_from(), blender::bke::Curve, blender::MutableSpan< T >::drop_back(), blender::bke::fill_attribute_range_default(), blender::bke::Point, and blender::Span< T >::size().
|
static |
Add new curves primitive to an existing curves object in edit mode.
Definition at line 1547 of file curves_ops.cc.
References blender::ed::object::add_generic_get_opts(), append_primitive_curve(), C, blender::bke::curves_new_nomain(), blender::bke::CurvesGeometry::curves_num(), fill_selection_false(), fill_selection_true(), foreach_selection_attribute_writer(), blender::bke::GeometrySet::from_curves(), blender::math::from_loc_rot_scale(), Curves::geometry, blender::bke::GeometrySet::get_curves_for_write(), blender::geometry::join_geometries(), blender::bke::Point, blender::bke::CurvesGeometry::points_num(), blender::bke::ReadOnly, selection, Curves::selection_domain, blender::bke::CurvesGeometry::tag_topology_changed(), and blender::geometry::transform_geometry().
Referenced by append_primitive_curve(), blender::ed::curves::add_bezier::exec(), and blender::ed::curves::add_circle::exec().
| void blender::ed::curves::apply_selection_operation_at_index | ( | GMutableSpan | selection, |
| int | index, | ||
| eSelectOp | sel_op ) |
Apply a change to a single curve or point. Avoid using this when affecting many elements.
Definition at line 709 of file curves_selection.cc.
References apply_selection_operation_at_index(), SEL_OP_ADD, SEL_OP_SET, SEL_OP_SUB, SEL_OP_XOR, and selection.
Referenced by blender::ed::greasepencil::apply_mask_as_segment_selection(), blender::ed::greasepencil::apply_mask_as_selection(), apply_selection_operation_at_index(), select_box(), select_circle(), and select_lasso().
|
static |
Calculates number of points in resulting curve denoted by #curve_index and sets its #curve_offsets value.
Definition at line 80 of file curves_extrude.cc.
References blender::MutableSpan< T >::size().
Referenced by finish_curve(), and finish_curve_or_full_copy().
|
static |
Definition at line 158 of file curves_extrude.cc.
References finish_curve(), finish_curve_or_full_copy(), blender::IndexRange::first(), handle_range(), selection, and blender::Span< T >::size().
Referenced by extrude_curves().
| std::optional< FindClosestData > blender::ed::curves::closest_elem_find_screen_space | ( | const ViewContext & | vc, |
| OffsetIndices< int > | points_by_curve, | ||
| Span< float3 > | deformed_positions, | ||
| const VArray< bool > & | cyclic, | ||
| const float4x4 & | projection, | ||
| const IndexMask & | mask, | ||
| bke::AttrDomain | domain, | ||
| int2 | coord, | ||
| const FindClosestData & | initial ) |
Find the closest screen-space point or curve in projected region-space.
Definition at line 892 of file curves_selection.cc.
References BLI_assert_unreachable, closest_elem_find_screen_space(), blender::bke::Curve, ED_view3d_select_dist_px(), find_closest_curve_to_screen_co(), find_closest_point_to_screen_co(), mask(), blender::bke::Point, and ViewContext::region.
Referenced by closest_elem_find_screen_space(), ed_curves_select_pick(), ed_grease_pencil_select_pick(), and blender::ed::greasepencil::weight_sample_invoke().
|
static |
Merges copy intervals at curve endings to minimize number of copy operations. For example given in function 'extrude_curves' intervals [0, 3, 4, 4, 4] became [0, 4, 4]. Leading to only two copy operations.
Definition at line 22 of file curves_extrude.cc.
References blender::MutableSpan< T >::data(), blender::IndexRange::first(), blender::Span< T >::last(), blender::IndexRange::size(), and blender::Span< T >::size().
|
static |
Definition at line 345 of file curves_selection.cc.
References blender::VArrayCommon< T >::common_info(), blender::CommonVArrayInfo::data, if(), blender::index_mask::IndexMask::index_range(), init(), blender::threading::parallel_reduce(), blender::CommonVArrayInfo::Single, blender::VArrayCommon< T >::size(), blender::index_mask::IndexMask::slice(), blender::CommonVArrayInfo::Span, and blender::CommonVArrayInfo::type.
Referenced by contains(), has_anything_selected(), has_anything_selected(), has_anything_selected(), has_anything_selected(), and has_anything_selected().
|
static |
Definition at line 405 of file curves_selection.cc.
References contains().
|
static |
Definition at line 629 of file curves_draw.cc.
References BEZIER_HANDLE_ALIGN, BEZIER_HANDLE_FREE, copy_v3_v3(), blender::bke::SpanAttributeWriter< T >::finish(), is_cyclic(), blender::bke::MutableAttributeAccessor::lookup_or_add_for_write_only_span(), blender::ed::curves::CurveDrawData::min, blender::bke::Point, blender::ed::curves::CurveDrawData::radius, blender::ed::curves::CurveDrawData::range, and blender::bke::SpanAttributeWriter< T >::span.
Referenced by curves_draw_exec().
|
static |
Definition at line 695 of file curves_draw.cc.
References copy_v3_v3(), blender::bke::SpanAttributeWriter< T >::finish(), is_cyclic(), blender::bke::MutableAttributeAccessor::lookup_or_add_for_write_only_span(), blender::ed::curves::CurveDrawData::min, blender::bke::Point, blender::ed::curves::CurveDrawData::radius, blender::ed::curves::CurveDrawData::range, and blender::bke::SpanAttributeWriter< T >::span.
Referenced by curves_draw_exec().
|
static |
Definition at line 1143 of file curves_draw.cc.
References curve_draw_exit().
Referenced by curves_draw_modal().
|
static |
Definition at line 439 of file curves_draw.cc.
References ARRAY_SET_ITEMS, BLI_mempool_calloc(), ceil(), copy_v2_v2(), copy_v3_v3(), wmOperator::customdata, ED_region_tag_redraw(), int, invert_m4_m4(), len_squared_v2v2(), blender::ed::curves::CurveDrawData::location_world, blender::ed::curves::StrokeElem::location_world, blender::ed::curves::CurveDrawData::location_world_valid, blender::ed::curves::CurveDrawData::mval, blender::ed::curves::StrokeElem::mval, wmEvent::mval, ViewContext::obedit, blender::ed::curves::StrokeElem::pressure, blender::ed::curves::CurveDrawData::prev, ViewContext::region, Object::runtime, blender::ed::curves::CurveDrawData::sample, blender::ed::curves::CurveDrawData::selem, sqrt(), square_f(), stroke_elem_interp(), blender::ed::curves::CurveDrawData::stroke_elem_pool, stroke_elem_project_fallback_elem(), STROKE_SAMPLE_DIST_MAX_PX, blender::ed::curves::CurveDrawData::use_substeps, and blender::ed::curves::CurveDrawData::vc.
Referenced by curve_draw_event_add_first(), and curves_draw_modal().
|
static |
Definition at line 495 of file curves_draw.cc.
References copy_v3_v3(), cross_v3_v3v3(), curve_draw_event_add(), CURVE_DRAW_PAINTING, CURVE_PAINT_FLAG_DEPTH_STROKE_ENDPOINTS, CURVE_PAINT_PROJECT_SURFACE, ToolSettings::curve_paint_settings, CURVE_PAINT_SURFACE_PLANE_NORMAL_SURFACE, CURVE_PAINT_SURFACE_PLANE_NORMAL_VIEW, wmOperator::customdata, CurvePaintSettings::depth_mode, blender::ed::curves::CurveDrawData::depths, dot_v3v3(), ED_view3d_depth_read_cached_normal(), ELEM, CurvePaintSettings::flag, float, blender::ed::curves::CurveDrawData::init_event_type, is_zero_v3(), blender::ed::curves::CurveDrawData::location_world_valid, wmEvent::mval, normalize_v3_v3(), blender::ed::curves::CurveDrawData::offset, blender::ed::curves::CurveDrawData::plane, blender::ed::curves::CurveDrawData::prev, blender::ed::curves::CurveDrawData::project, ViewContext::region, ViewContext::rv3d, ViewContext::scene, blender::ed::curves::CurveDrawData::state, stroke_elem_project(), sub_v3_v3v3(), blender::ed::curves::CurveDrawData::surface_offset, CurvePaintSettings::surface_plane, Scene::toolsettings, blender::ed::curves::CurveDrawData::use_depth, blender::ed::curves::CurveDrawData::use_offset, blender::ed::curves::CurveDrawData::use_plane, blender::ed::curves::CurveDrawData::vc, and RegionView3D::viewinv.
Referenced by curves_draw_invoke(), and curves_draw_modal().
|
static |
Initialize values before calling 'exec' (when running interactively).
Definition at line 1151 of file curves_draw.cc.
References BLI_mempool_iternew(), BLI_mempool_iterstep(), BLI_mempool_len(), CurvePaintSettings::corner_angle, CURVE_PAINT_FLAG_CORNERS_DETECT, ToolSettings::curve_paint_settings, wmOperator::customdata, CurvePaintSettings::error_threshold, CurvePaintSettings::fit_method, CurvePaintSettings::flag, float, len_squared_v2v2(), len_v2v2(), len_v3v3(), blender::ed::curves::StrokeElem::location_local, M_PI, MEM_freeN(), MEM_mallocN, blender::ed::curves::StrokeElem::mval, blender::ed::curves::StrokeElem::pressure, wmOperator::ptr, CurvePaintSettings::radius_taper_end, CurvePaintSettings::radius_taper_start, RNA_property_boolean_set(), RNA_property_enum_set(), RNA_property_float_set(), RNA_property_is_set(), RNA_struct_find_property(), ViewContext::scene, square_f(), STROKE_CYCLIC_DIST_PX, blender::ed::curves::CurveDrawData::stroke_elem_pool, stroke_elem_pressure_set(), Scene::toolsettings, UI_SCALE_FAC, and blender::ed::curves::CurveDrawData::vc.
Referenced by curves_draw_modal().
|
static |
Definition at line 556 of file curves_draw.cc.
References BLI_mempool_destroy(), wmOperator::customdata, blender::ed::curves::CurveDrawData::depths, blender::ed::curves::CurveDrawData::draw_handle_view, ED_region_draw_cb_exit(), ED_view3d_depths_free(), MEM_freeN(), ViewContext::region, blender::ed::curves::CurveDrawData::stroke_elem_pool, ARegion::type, blender::ed::curves::CurveDrawData::vc, ViewContext::win, and WM_cursor_modal_restore().
Referenced by curve_draw_cancel(), and curves_draw_exec().
|
static |
Definition at line 577 of file curves_draw.cc.
References blender::ed::curves::CurveDrawData::bevel_radius, BKE_report(), BLI_assert, BLI_MEMPOOL_ALLOW_ITER, BLI_mempool_create(), ViewContext::bmain, C, CTX_data_edit_object(), CTX_data_ensure_evaluated_depsgraph(), CTX_data_main(), CTX_data_scene(), CTX_data_view_layer(), CURVE_PAINT_FLAG_DEPTH_STROKE_OFFSET_ABS, ToolSettings::curve_paint_settings, blender::ed::curves::CurveDrawData::curve_type, CurvePaintSettings::curve_type, wmOperator::customdata, depsgraph, ViewContext::depsgraph, ED_view3d_viewcontext_init(), ELEM, CurvePaintSettings::flag, blender::ed::curves::CurveDrawData::is_curve_2d, blender::ed::curves::CurveDrawData::max, MEM_callocN, MEM_freeN(), blender::ed::curves::CurveDrawData::min, ViewContext::obedit, blender::ed::curves::CurveDrawData::project, wmOperator::ptr, blender::ed::curves::CurveDrawData::radius, CurvePaintSettings::radius_max, CurvePaintSettings::radius_min, blender::ed::curves::CurveDrawData::range, ViewContext::region, wmOperator::reports, RNA_boolean_get(), RNA_collection_is_empty(), RPT_ERROR, ViewContext::rv3d, ViewContext::scene, blender::ed::curves::CurveDrawData::stroke_elem_pool, blender::ed::curves::CurveDrawData::surface_offset, CurvePaintSettings::surface_offset, Scene::toolsettings, blender::ed::curves::CurveDrawData::use_surface_offset_absolute, ViewContext::v3d, blender::ed::curves::CurveDrawData::vc, ViewContext::view_layer, and ViewContext::win.
Referenced by curves_draw_exec(), and curves_draw_invoke().
Definition at line 331 of file curves_draw.cc.
References blender::ed::curves::CurveDrawData::bevel_radius, BLI_mempool_iternew(), BLI_mempool_iterstep(), BLI_mempool_len(), copy_v3_v3(), wmOperator::customdata, float, GPU_batch_draw(), GPU_batch_preset_sphere(), GPU_batch_program_set_builtin(), GPU_batch_uniform_3fv, GPU_blend(), GPU_BLEND_ALPHA, GPU_BLEND_NONE, GPU_COMP_F32, GPU_DEPTH_LESS_EQUAL, GPU_DEPTH_NONE, GPU_depth_test(), GPU_FETCH_FLOAT, GPU_line_smooth(), GPU_line_width(), GPU_matrix_mul, GPU_matrix_pop(), GPU_matrix_push(), GPU_matrix_scale_1f(), GPU_matrix_translate_3f(), GPU_PRIM_LINE_STRIP, GPU_SHADER_3D_UNIFORM_COLOR, GPU_vertformat_attr_add(), imm_cpack(), immBegin(), immBindBuiltinProgram(), immEnd(), immUnbindProgram(), immVertex3fv(), immVertexFormat(), blender::ed::curves::StrokeElem::location_local, blender::ed::curves::StrokeElem::location_world, MEM_freeN(), MEM_mallocN, ViewContext::obedit, pos, blender::ed::curves::CurveDrawData::stroke_elem_pool, stroke_elem_radius(), TH_WIRE, UI_GetThemeColor3fv(), and blender::ed::curves::CurveDrawData::vc.
Referenced by curves_draw_invoke().
|
static |
Definition at line 321 of file curves_draw.cc.
References curve_draw_stroke_from_operator_elem(), wmOperator::ptr, RNA_BEGIN, and RNA_END.
Referenced by curves_draw_exec().
|
static |
Definition at line 293 of file curves_draw.cc.
References BLI_mempool_calloc(), wmOperator::customdata, blender::ed::curves::StrokeElem::location_local, blender::ed::curves::StrokeElem::location_world, mul_v3_m4v3(), blender::ed::curves::StrokeElem::mval, ViewContext::obedit, blender::ed::curves::StrokeElem::pressure, RNA_float_get(), RNA_float_get_array(), blender::ed::curves::CurveDrawData::stroke_elem_pool, and blender::ed::curves::CurveDrawData::vc.
Referenced by curve_draw_stroke_from_operator().
|
static |
Definition at line 306 of file curves_draw.cc.
References BLI_mempool_iternew(), BLI_mempool_iterstep(), curve_draw_stroke_to_operator_elem(), wmOperator::customdata, and blender::ed::curves::CurveDrawData::stroke_elem_pool.
Referenced by curves_draw_modal().
|
static |
Definition at line 283 of file curves_draw.cc.
References blender::ed::curves::StrokeElem::location_world, blender::ed::curves::StrokeElem::mval, blender::ed::curves::StrokeElem::pressure, wmOperator::ptr, RNA_collection_add(), RNA_float_set(), and RNA_float_set_array().
Referenced by curve_draw_stroke_to_operator().
| IndexMask blender::ed::curves::curve_mask_from_points | ( | const bke::CurvesGeometry & | curves, |
| const IndexMask & | point_mask, | ||
| const GrainSize | grain_size, | ||
| IndexMaskMemory & | memory ) |
Create a mask for all curves that have at least one point in the point mask.
Definition at line 19 of file curves_masks.cc.
References blender::IndexMask::from_predicate(), and blender::index_mask::IndexMask::to_bools().
Referenced by blender::ed::greasepencil::apply_mask_as_segment_selection().
|
static |
Definition at line 733 of file curves_draw.cc.
References blender::bke::attribute_filter_from_skip_ref(), BLI_mempool_iternew(), BLI_mempool_iterstep(), BLI_mempool_len(), C, blender::bke::AttributeAccessor::contains(), copy_v3_v3(), create_Bezier(), create_NURBS(), CU_BEZIER, blender::bke::Curve, curve_draw_exit(), curve_draw_init(), curve_draw_stroke_from_operator(), CURVE_PAINT_FIT_METHOD_REFIT, CURVE_PAINT_FIT_METHOD_SPLIT, CURVE_PAINT_FLAG_PRESSURE_RADIUS, ToolSettings::curve_paint_settings, blender::ed::curves::CurveDrawData::curve_type, CURVE_TYPE_BEZIER, CURVE_TYPE_NURBS, CURVE_TYPE_POLY, wmOperator::customdata, Object::data, DEG_id_tag_update(), blender::bke::fill_attribute_range_default(), blender::bke::SpanAttributeWriter< T >::finish(), CurvePaintSettings::flag, free(), Curves::geometry, get_curves_all_selection_attribute_names(), get_curves_bezier_selection_attribute_names(), get_curves_selection_attribute_names(), invert_m4_m4(), blender::ed::curves::CurveDrawData::is_curve_2d, is_cyclic(), blender::ed::curves::StrokeElem::location_local, blender::bke::MutableAttributeAccessor::lookup_or_add_for_write(), blender::bke::MutableAttributeAccessor::lookup_or_add_for_write_only_span(), M_PI, MEM_freeN(), MEM_mallocN, NC_GEOM, ND_DATA, NURBS_KNOT_MODE_BEZIER, NURBS_KNOT_MODE_ENDPOINT_BEZIER, ViewContext::obedit, OPERATOR_CANCELLED, OPERATOR_FINISHED, blender::bke::Point, blender::ed::curves::StrokeElem::pressure, wmOperator::ptr, CurvePaintSettings::radius_max, CurvePaintSettings::radius_min, CurvePaintSettings::radius_taper_end, CurvePaintSettings::radius_taper_start, remove_selection_attributes(), result, RNA_boolean_get(), RNA_enum_get(), RNA_float_get(), Object::runtime, ViewContext::scene, selection, blender::bke::SpanAttributeWriter< T >::span, blender::ed::curves::CurveDrawData::stroke_elem_pool, Scene::toolsettings, UNLIKELY, blender::ed::curves::CurveDrawData::vc, and WM_event_add_notifier().
Referenced by curves_draw_invoke(), curves_draw_modal(), and CURVES_OT_draw().
|
static |
Definition at line 1045 of file curves_draw.cc.
References BKE_report(), C, copy_v3_v3(), CU_POLY, Scene::cursor, curve_draw_event_add_first(), curve_draw_init(), curve_draw_stroke_3d(), CURVE_PAINT_FLAG_DEPTH_ONLY_SELECTED, CURVE_PAINT_PROJECT_SURFACE, ToolSettings::curve_paint_settings, blender::ed::curves::CurveDrawData::curve_type, curves_draw_exec(), wmOperator::customdata, ViewContext::depsgraph, CurvePaintSettings::depth_mode, blender::ed::curves::CurveDrawData::depths, dot_v3v3(), blender::ed::curves::CurveDrawData::draw_handle_view, ED_region_draw_cb_activate(), ED_view3d_depth_override(), ED_view3d_win_to_3d(), CurvePaintSettings::flag, float, blender::ed::curves::CurveDrawData::is_curve_2d, View3DCursor::location, blender::ed::curves::CurveDrawData::location_world, blender::ed::curves::CurveDrawData::location_world_valid, wmEvent::mval, negate_v3_v3(), normalize_v3_v3(), OB_WIRE, ViewContext::obedit, RegionView3D::ofs, OPERATOR_CANCELLED, OPERATOR_RUNNING_MODAL, blender::ed::curves::CurveDrawData::plane, blender::ed::curves::CurveDrawData::prev, blender::ed::curves::CurveDrawData::project, wmOperator::ptr, ViewContext::region, REGION_DRAW_POST_VIEW, wmOperator::reports, RNA_boolean_get(), RNA_struct_property_is_set(), RPT_WARNING, ViewContext::rv3d, blender::ed::curves::CurveDrawData::sample, ViewContext::scene, View3D::shading, Scene::toolsettings, ARegion::type, View3DShading::type, blender::ed::curves::CurveDrawData::use_depth, blender::ed::curves::CurveDrawData::use_plane, blender::ed::curves::CurveDrawData::use_substeps, ViewContext::v3d, V3D_DEPTH_ALL, V3D_DEPTH_SELECTED_ONLY, blender::ed::curves::CurveDrawData::vc, view3d_operator_needs_opengl(), RegionView3D::viewinv, ViewContext::win, WM_cursor_modal_set(), WM_CURSOR_PAINT_BRUSH, and WM_event_add_modal_handler().
Referenced by CURVES_OT_draw().
|
static |
Definition at line 1271 of file curves_draw.cc.
References C, curve_draw_cancel(), curve_draw_event_add(), curve_draw_event_add_first(), curve_draw_exec_precalc(), CURVE_DRAW_PAINTING, curve_draw_stroke_to_operator(), curves_draw_exec(), wmOperator::customdata, ED_region_tag_redraw(), ELEM, EVT_ESCKEY, float, blender::ed::curves::CurveDrawData::init_event_type, ISMOUSE_MOTION, KM_PRESS, KM_RELEASE, LEFTMOUSE, len_squared_v2v2(), blender::ed::curves::CurveDrawData::mval, wmEvent::mval, OPERATOR_CANCELLED, OPERATOR_FINISHED, OPERATOR_RUNNING_MODAL, blender::ed::curves::CurveDrawData::prev, ViewContext::region, ret, RIGHTMOUSE, square_f(), blender::ed::curves::CurveDrawData::state, STROKE_SAMPLE_DIST_MIN_PX, wmEvent::type, UNUSED_VARS, wmEvent::val, and blender::ed::curves::CurveDrawData::vc.
Referenced by CURVES_OT_draw().
|
static |
Definition at line 361 of file curves_extrude.cc.
References C, curves_extrude_exec(), extrude_curves(), get_unique_editable_curves(), and OPERATOR_FINISHED.
Referenced by curves_extrude_exec(), and CURVES_OT_extrude().
|
static |
Definition at line 1694 of file curves_ops.cc.
References blender::ed::object::add_generic_props(), blender::ed::object::add_unit_props_radius(), CURVES_OT_add_bezier(), editable_curves_in_edit_mode_poll(), blender::ed::curves::add_bezier::exec(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_add_bezier(), and operatortypes_curves().
|
static |
Definition at line 1634 of file curves_ops.cc.
References blender::ed::object::add_generic_props(), blender::ed::object::add_unit_props_radius(), CURVES_OT_add_circle(), editable_curves_in_edit_mode_poll(), blender::ed::curves::add_circle::exec(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_add_circle(), and operatortypes_curves().
| void blender::ed::curves::CURVES_OT_attribute_set | ( | wmOperatorType * | ot | ) |
Definition at line 206 of file curves_attribute_set.cc.
References active_attribute_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, blender::ed::geometry::register_rna_properties_for_attribute_types(), set_attribute_exec(), set_attribute_invoke(), and set_attribute_ui().
Referenced by operatortypes_curves().
|
static |
Definition at line 571 of file curves_ops.cc.
References blender::ed::curves::convert_from_particle_system::curves_convert_from_particle_system_exec(), blender::ed::curves::convert_from_particle_system::curves_convert_from_particle_system_poll(), CURVES_OT_convert_from_particle_system(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_convert_from_particle_system(), and operatortypes_curves().
|
static |
Definition at line 436 of file curves_ops.cc.
References blender::ed::curves::convert_to_particle_system::curves_convert_to_particle_system_exec(), curves_with_surface_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by operatortypes_curves().
|
static |
Definition at line 1424 of file curves_ops.cc.
References CURVE_TYPE_POLY, CURVES_OT_curve_type_set(), editable_curves_in_edit_mode_poll(), blender::ed::curves::curve_type_set::exec(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, RNA_def_boolean(), RNA_def_enum(), and rna_enum_curves_type_items.
Referenced by CURVES_OT_curve_type_set(), and operatortypes_curves().
|
static |
Definition at line 1381 of file curves_ops.cc.
References CURVES_OT_cyclic_toggle(), editable_curves_in_edit_mode_poll(), blender::ed::curves::cyclic_toggle::exec(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_cyclic_toggle(), and operatortypes_curves().
|
static |
Definition at line 1257 of file curves_ops.cc.
References CURVES_OT_delete(), blender::ed::curves::curves_delete::delete_exec(), editable_curves_in_edit_mode_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_delete(), and operatortypes_curves().
| void blender::ed::curves::CURVES_OT_draw | ( | wmOperatorType * | ot | ) |
Definition at line 1313 of file curves_draw.cc.
References CURVE_PAINT_FIT_METHOD_REFIT, curves_draw_exec(), curves_draw_invoke(), curves_draw_modal(), DEG2RADF, editable_curves_in_edit_mode_poll(), M_PI, OPTYPE_REGISTER, OPTYPE_UNDO, ot, PROP_ANGLE, PROP_HIDDEN, PROP_SKIP_SAVE, RNA_def_boolean(), RNA_def_collection_runtime(), RNA_def_enum(), RNA_def_float_distance(), RNA_def_property_flag(), RNA_def_property_subtype(), RNA_def_property_ui_range(), and rna_enum_curve_fit_method_items.
Referenced by operatortypes_curves().
|
static |
Definition at line 1295 of file curves_ops.cc.
References CURVES_OT_duplicate(), blender::ed::curves::curves_duplicate::delete_exec(), editable_curves_in_edit_mode_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_duplicate(), and operatortypes_curves().
| void blender::ed::curves::CURVES_OT_extrude | ( | wmOperatorType * | ot | ) |
Definition at line 369 of file curves_extrude.cc.
References curves_extrude_exec(), CURVES_OT_extrude(), editable_curves_in_edit_mode_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_extrude(), and operatortypes_curves().
|
static |
Definition at line 1751 of file curves_ops.cc.
References CURVE_TYPE_POLY, CURVES_OT_handle_type_set(), editable_curves_in_edit_mode_poll(), blender::ed::curves::set_handle_type::exec(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, RNA_def_enum(), rna_enum_curves_handle_type_items, and WM_menu_invoke().
Referenced by CURVES_OT_handle_type_set(), and operatortypes_curves().
|
static |
Definition at line 899 of file curves_ops.cc.
References CURVES_OT_select_all(), editable_curves_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, select_all_exec(), and WM_operator_properties_select_all().
Referenced by CURVES_OT_select_all(), and operatortypes_curves().
|
static |
Definition at line 1037 of file curves_ops.cc.
References CURVES_OT_select_ends(), editable_curves_point_domain_poll(), INT32_MAX, OPTYPE_REGISTER, OPTYPE_UNDO, ot, RNA_def_int(), select_ends_exec(), and select_ends_ui().
Referenced by CURVES_OT_select_ends(), and operatortypes_curves().
|
static |
Definition at line 1138 of file curves_ops.cc.
References CURVES_OT_select_less(), editable_curves_point_domain_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, and select_less_exec().
Referenced by CURVES_OT_select_less(), and operatortypes_curves().
|
static |
Definition at line 1084 of file curves_ops.cc.
References CURVES_OT_select_linked(), editable_curves_point_domain_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, and select_linked_exec().
Referenced by CURVES_OT_select_linked(), and operatortypes_curves().
|
static |
Definition at line 1111 of file curves_ops.cc.
References CURVES_OT_select_more(), editable_curves_point_domain_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, and select_more_exec().
Referenced by CURVES_OT_select_more(), and operatortypes_curves().
|
static |
Definition at line 956 of file curves_ops.cc.
References CURVES_OT_select_random(), editable_curves_poll(), INT32_MAX, INT32_MIN, OPTYPE_REGISTER, OPTYPE_UNDO, ot, RNA_def_float(), RNA_def_int(), select_random_exec(), and select_random_ui().
Referenced by CURVES_OT_select_random(), and operatortypes_curves().
|
static |
Definition at line 851 of file curves_ops.cc.
References CURVES_OT_set_selection_domain(), blender::ed::curves::set_selection_domain::curves_set_selection_domain_exec(), editable_curves_poll(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, PROP_HIDDEN, PROP_SKIP_SAVE, RNA_def_enum(), RNA_def_property_flag(), and rna_enum_attribute_curves_domain_items.
Referenced by CURVES_OT_set_selection_domain(), and operatortypes_curves().
|
static |
Definition at line 751 of file curves_ops.cc.
References CURVES_OT_snap_curves_to_surface(), editable_curves_with_surface_poll(), int, OPTYPE_REGISTER, OPTYPE_UNDO, ot, and RNA_def_enum().
Referenced by CURVES_OT_snap_curves_to_surface(), and operatortypes_curves().
|
static |
Definition at line 1529 of file curves_ops.cc.
References CURVES_OT_subdivide(), editable_curves_in_edit_mode_poll(), blender::ed::curves::subdivide::exec(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, PROP_SKIP_SAVE, RNA_def_int(), and RNA_def_property_flag().
Referenced by CURVES_OT_subdivide(), and operatortypes_curves().
|
static |
Definition at line 1227 of file curves_ops.cc.
References CURVES_OT_surface_set(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, blender::ed::curves::surface_set::surface_set_exec(), and blender::ed::curves::surface_set::surface_set_poll().
Referenced by CURVES_OT_surface_set(), and operatortypes_curves().
|
static |
Definition at line 1467 of file curves_ops.cc.
References CURVES_OT_switch_direction(), editable_curves_in_edit_mode_poll(), blender::ed::curves::switch_direction::exec(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_switch_direction(), and operatortypes_curves().
|
static |
Definition at line 1335 of file curves_ops.cc.
References CURVES_OT_tilt_clear(), editable_curves_in_edit_mode_poll(), blender::ed::curves::clear_tilt::exec(), OPTYPE_REGISTER, OPTYPE_UNDO, and ot.
Referenced by CURVES_OT_tilt_clear(), and operatortypes_curves().
| bool blender::ed::curves::curves_poll | ( | bContext * | C | ) |
Definition at line 166 of file curves_ops.cc.
References C, and curves_poll_impl().
Referenced by blender::ed::sculpt_paint::CURVES_OT_sculptmode_toggle().
|
static |
Definition at line 117 of file curves_ops.cc.
References C, CTX_data_active_object(), CTX_wm_operator_poll_msg_set(), ED_operator_object_active_editable_ex(), OB_CURVES, OB_MESH, and OB_MODE_EDIT.
Referenced by curves_poll(), curves_with_surface_poll(), editable_curves_in_edit_mode_poll(), editable_curves_poll(), and editable_curves_with_surface_poll().
| bool blender::ed::curves::curves_with_surface_poll | ( | bContext * | C | ) |
Definition at line 156 of file curves_ops.cc.
References C, and curves_poll_impl().
Referenced by CURVES_OT_convert_to_particle_system(), and blender::ed::sculpt_paint::min_distance_edit::min_distance_edit_poll().
| void blender::ed::curves::duplicate_curves | ( | bke::CurvesGeometry & | curves, |
| const IndexMask & | mask ) |
Definition at line 170 of file curves_edit.cc.
References attribute, BLI_assert_unreachable, blender::bke::Curve, blender::bke::AttributeIter::domain, blender::MutableSpan< T >::drop_front(), blender::bke::AttributeAccessor::foreach_attribute(), blender::array_utils::gather(), blender::bke::attribute_math::gather_group_to_group(), blender::offset_indices::gather_selected_offsets(), get_curves_selection_attribute_names(), blender::bke::MutableAttributeAccessor::lookup_for_write_span(), blender::bke::MutableAttributeAccessor::lookup_or_add_for_write_span(), mask(), blender::bke::AttributeIter::name, blender::bke::Point, remove_selection_attributes(), selection, blender::offset_indices::OffsetIndices< T >::slice(), blender::MutableSpan< T >::take_front(), and blender::offset_indices::OffsetIndices< T >::total_size().
Referenced by blender::ed::curves::curves_duplicate::delete_exec(), blender::ed::greasepencil::grease_pencil_duplicate_exec(), and blender::ed::greasepencil::grease_pencil_reproject_exec().
| void blender::ed::curves::duplicate_points | ( | bke::CurvesGeometry & | curves, |
| const IndexMask & | mask ) |
Definition at line 41 of file curves_edit.cc.
References blender::offset_indices::accumulate_counts_to_offsets(), blender::Vector< T, InlineBufferCapacity, Allocator >::append(), blender::Array< T, InlineBufferCapacity, Allocator >::as_mutable_span(), blender::Array< T, InlineBufferCapacity, Allocator >::as_span(), blender::Vector< T, InlineBufferCapacity, Allocator >::as_span(), attribute, BLI_assert_unreachable, blender::array_utils::copy(), blender::bke::Curve, blender::bke::AttributeIter::domain, blender::MutableSpan< T >::drop_back(), blender::IndexRange::drop_front(), blender::MutableSpan< T >::drop_front(), blender::array_utils::fill_index_range(), blender::array_utils::find_all_ranges(), blender::IndexRange::first(), blender::Vector< T, InlineBufferCapacity, Allocator >::first(), blender::bke::AttributeAccessor::foreach_attribute(), blender::bke::attribute_math::gather(), get_curves_selection_attribute_names(), blender::VArrayCommon< T >::get_internal_single(), blender::Vector< T, InlineBufferCapacity, Allocator >::index_range(), is_cyclic(), blender::Vector< T, InlineBufferCapacity, Allocator >::is_empty(), blender::VArrayCommon< T >::is_single(), blender::Vector< T, InlineBufferCapacity, Allocator >::last(), blender::bke::MutableAttributeAccessor::lookup_for_write_span(), blender::bke::MutableAttributeAccessor::lookup_or_add_for_write_span(), mask(), blender::bke::AttributeIter::name, blender::bke::Point, remove_selection_attributes(), selection, blender::IndexRange::size(), blender::Vector< T, InlineBufferCapacity, Allocator >::size(), and blender::IndexRange::start().
Referenced by blender::ed::curves::curves_duplicate::delete_exec(), blender::ed::greasepencil::grease_pencil_duplicate_exec(), and blender::ed::greasepencil::grease_pencil_reproject_exec().
| bool blender::ed::curves::editable_curves_in_edit_mode_poll | ( | bContext * | C | ) |
Definition at line 146 of file curves_ops.cc.
References C, and curves_poll_impl().
Referenced by active_attribute_poll(), CURVES_OT_add_bezier(), CURVES_OT_add_circle(), CURVES_OT_curve_type_set(), CURVES_OT_cyclic_toggle(), CURVES_OT_delete(), CURVES_OT_draw(), CURVES_OT_duplicate(), CURVES_OT_extrude(), CURVES_OT_handle_type_set(), CURVES_OT_subdivide(), CURVES_OT_switch_direction(), CURVES_OT_tilt_clear(), keymap_curves(), and undosys_type_register().
|
static |
Definition at line 171 of file curves_ops.cc.
References C, CTX_data_active_object(), CTX_wm_operator_poll_msg_set(), Object::data, editable_curves_poll(), blender::bke::Point, and Curves::selection_domain.
Referenced by CURVES_OT_select_ends(), CURVES_OT_select_less(), CURVES_OT_select_linked(), and CURVES_OT_select_more().
| bool blender::ed::curves::editable_curves_poll | ( | bContext * | C | ) |
Definition at line 161 of file curves_ops.cc.
References C, and curves_poll_impl().
Referenced by CURVES_OT_select_all(), CURVES_OT_select_random(), CURVES_OT_set_selection_domain(), editable_curves_point_domain_poll(), blender::ed::sculpt_paint::SCULPT_CURVES_OT_select_grow(), and blender::ed::sculpt_paint::SCULPT_CURVES_OT_select_random().
| bool blender::ed::curves::editable_curves_with_surface_poll | ( | bContext * | C | ) |
Definition at line 151 of file curves_ops.cc.
References C, and curves_poll_impl().
Referenced by CURVES_OT_snap_curves_to_surface().
| IndexMask blender::ed::curves::end_points | ( | const bke::CurvesGeometry & | curves, |
| const IndexMask & | curves_mask, | ||
| const int | amount_start, | ||
| const int | amount_end, | ||
| const bool | inverted, | ||
| IndexMaskMemory & | memory ) |
Definition at line 40 of file curves_masks.cc.
References end_points(), blender::index_mask::IndexMask::foreach_index(), and IndexMask::from_bools().
Referenced by end_points(), end_points(), select_ends_exec(), and blender::ed::greasepencil::select_ends_exec().
| IndexMask blender::ed::curves::end_points | ( | const bke::CurvesGeometry & | curves, |
| int | amount_start, | ||
| int | amount_end, | ||
| bool | inverted, | ||
| IndexMaskMemory & | memory ) |
Return a mask of all the end points in the curves.
| curves_mask | (optional): The curves that should be used in the resulting point mask. |
| amount_start | The amount of points to mask from the front. |
| amount_end | The amount of points to mask from the back. |
| inverted | Invert the resulting mask. |
Definition at line 59 of file curves_masks.cc.
References end_points().
| bke::GSpanAttributeWriter blender::ed::curves::ensure_selection_attribute | ( | bke::CurvesGeometry & | curves, |
| bke::AttrDomain | selection_domain, | ||
| eCustomDataType | create_type, | ||
| StringRef | attribute_name = ".selection" ) |
If the selection_id attribute doesn't exist, create it with the requested type (bool or float).
Definition at line 260 of file curves_selection.cc.
References blender::bke::MutableAttributeAccessor::add(), BLI_assert_unreachable, CD_PROP_BOOL, CD_PROP_FLOAT, blender::bke::AttributeAccessor::contains(), blender::bke::GSpanAttributeWriter::domain, blender::bke::AttributeAccessor::domain_size(), blender::bke::GSpanAttributeWriter::finish(), blender::VArray< T >::ForSingle(), blender::bke::MutableAttributeAccessor::lookup_for_write_span(), and blender::bke::MutableAttributeAccessor::remove().
Referenced by blender::ed::greasepencil::apply_mask_as_segment_selection(), blender::ed::greasepencil::apply_mask_as_selection(), blender::ed::sculpt_paint::greasepencil::deselect_stroke(), extrude_curves(), blender::ed::greasepencil::extrude_grease_pencil_curves(), blender::ed::greasepencil::grease_pencil_material_select_exec(), blender::ed::greasepencil::grease_pencil_paste_strokes_exec(), init_selection_writers(), select_adjacent(), select_alternate(), select_ends_exec(), and select_random_exec().
| void blender::ed::curves::ensure_surface_deformation_node_exists | ( | bContext & | C, |
| Object & | curves_ob ) |
Definition at line 61 of file curves_add.cc.
References C, CTX_data_main(), CTX_data_scene(), DATA_, ED_node_tree_propagate_change(), eModifierType_Nodes, ListBase::first, GeometryNodeAssetTraits::flag, GEO_NODE_ASSET_MODIFIER, GEO_NODE_DEFORM_CURVES_ON_SURFACE, bNodeTree::geometry_node_asset_traits, has_surface_deformation_node(), bNode::inputs, bNode::locx, blender::ed::object::modifier_add(), blender::bke::node_add_link(), blender::bke::node_add_static_node(), blender::bke::node_find_socket(), NodesModifierData::node_group, NODE_GROUP_INPUT, NODE_GROUP_OUTPUT, NODE_INTERFACE_SOCKET_INPUT, NODE_INTERFACE_SOCKET_OUTPUT, blender::bke::node_tree_add_tree(), bNode::outputs, SOCK_IN, SOCK_OUT, and bNodeTree::tree_interface.
Referenced by blender::ed::object::object_curves_empty_hair_add_exec(), and blender::ed::curves::surface_set::surface_set_exec().
|
static |
Definition at line 229 of file curves_extrude.cc.
References calc_curves_extrusion(), CD_PROP_BOOL, CD_PROP_FLOAT, blender::bke::curves::copy_only_curve_domain(), blender::bke::CurvesGeometry::curves_num(), ensure_selection_attribute(), blender::VArray< T >::ForSingle(), Curves::geometry, get_curves_selection_attribute_names(), blender::Span< T >::index_range(), blender::CPPType::is(), blender::index_mask::IndexMask::is_empty(), blender::MutableSpan< T >::last(), blender::bke::AttributeAccessor::lookup(), blender::bke::CurvesGeometry::offsets_for_write(), blender::threading::parallel_for(), blender::bke::Point, blender::bke::CurvesGeometry::resize(), retrieve_selected_points(), Curves::selection_domain, blender::index_mask::IndexMask::size(), and blender::GVArrayCommon::type().
Referenced by curves_extrude_exec().
| void blender::ed::curves::fill_selection | ( | GMutableSpan | selection, |
| bool | value ) |
Definition at line 315 of file curves_selection.cc.
References selection.
| void blender::ed::curves::fill_selection_false | ( | GMutableSpan | selection | ) |
Definition at line 295 of file curves_selection.cc.
References selection.
Referenced by append_primitive_curve(), blender::ed::sculpt_paint::greasepencil::deselect_stroke(), blender::ed::sculpt_paint::SelectionPaintOperationExecutor::execute(), blender::ed::greasepencil::grease_pencil_paste_strokes_exec(), select_all(), select_box(), select_circle(), select_lasso(), select_random_exec(), and blender::ed::greasepencil::selection_update().
| void blender::ed::curves::fill_selection_false | ( | GMutableSpan | selection, |
| const IndexMask & | mask ) |
Definition at line 325 of file curves_selection.cc.
References mask(), blender::index_mask::masked_fill(), and selection.
| void blender::ed::curves::fill_selection_true | ( | GMutableSpan | selection | ) |
Definition at line 305 of file curves_selection.cc.
References selection.
Referenced by append_primitive_curve(), blender::ed::sculpt_paint::AddOperationExecutor::execute(), select_all(), select_ends_exec(), select_linked(), and select_random_exec().
| void blender::ed::curves::fill_selection_true | ( | GMutableSpan | selection, |
| const IndexMask & | mask ) |
Definition at line 335 of file curves_selection.cc.
References mask(), blender::index_mask::masked_fill(), and selection.
|
static |
Definition at line 802 of file curves_selection.cc.
References find_closest_curve_to_screen_co(), blender::index_mask::IndexMask::index_range(), init(), blender::threading::parallel_reduce(), and pow2f().
Referenced by closest_elem_find_screen_space(), and find_closest_curve_to_screen_co().
|
static |
Definition at line 749 of file curves_selection.cc.
References find_closest_point_to_screen_co(), blender::index_mask::IndexMask::index_range(), init(), blender::threading::parallel_reduce(), and pow2f().
Referenced by closest_elem_find_screen_space(), and find_closest_point_to_screen_co().
|
static |
Definition at line 151 of file curves_selection.cc.
Referenced by foreach_selection_attribute_writer(), select_box(), select_circle(), select_lasso(), and select_linked().
|
static |
Definition at line 92 of file curves_extrude.cc.
References calc_curve_offset().
Referenced by calc_curves_extrusion(), and finish_curve_or_full_copy().
|
static |
Definition at line 123 of file curves_extrude.cc.
References calc_curve_offset(), and finish_curve().
Referenced by calc_curves_extrusion().
| void blender::ed::curves::foreach_selectable_curve_range | ( | const bke::CurvesGeometry & | curves, |
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| SelectionRangeFn | range_consumer ) |
Same logic as in foreach_selectable_point_range, just ranges reference curves instead of positions directly. Further positions can be referenced by using curves.points_by_curve() in a callback function.
Definition at line 233 of file curves_selection.cc.
References blender::index_mask::IndexMask::foreach_range(), blender::Span< T >::index_range(), and init_selectable_foreach().
Referenced by ed_curves_select_pick(), ed_grease_pencil_select_pick(), select_box(), select_circle(), and select_lasso().
| void blender::ed::curves::foreach_selectable_point_range | ( | const bke::CurvesGeometry & | curves, |
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| SelectionRangeFn | range_consumer ) |
Traverses all ranges of control points possible select. Callback function is provided with a range being visited, positions (deformed if possible) referenced by the range and selection attribute name positions belongs to: curves.positions() belong to ".selection", curves.handle_positions_left() belong to ".selection_handle_left", curves.handle_positions_right() belong to ".selection_handle_right".
Definition at line 204 of file curves_selection.cc.
References blender::index_mask::IndexMask::foreach_index(), blender::Span< T >::index_range(), and init_selectable_foreach().
Referenced by ed_curves_select_pick(), ed_grease_pencil_select_pick(), select_box(), select_circle(), and select_lasso().
| void blender::ed::curves::foreach_selection_attribute_writer | ( | bke::CurvesGeometry & | curves, |
| bke::AttrDomain | selection_domain, | ||
| blender::FunctionRef< void(bke::GSpanAttributeWriter &selection)> | fn ) |
Definition at line 174 of file curves_selection.cc.
References finish_attribute_writers(), init_selection_writers(), and selection.
Referenced by append_primitive_curve(), and select_all().
Definition at line 95 of file curves_selection.cc.
Referenced by curves_draw_exec(), get_curves_selection_attribute_names(), and selection_attribute_writer_by_name().
| Span< StringRef > blender::ed::curves::get_curves_bezier_selection_attribute_names | ( | const bke::CurvesGeometry & | curves | ) |
Returns [".selection_handle_left", ".selection_handle_right"] if argument contains Bezier curves, empty span otherwise.
Definition at line 102 of file curves_selection.cc.
References blender::bke::AttributeAccessor::contains().
Referenced by curves_draw_exec(), and init_selectable_foreach().
| Vector< MutableSpan< float3 > > blender::ed::curves::get_curves_positions_for_write | ( | bke::CurvesGeometry & | curves | ) |
Get get writable positions per selection attribute for given curve.
Definition at line 14 of file curves_data.cc.
References blender::Vector< T, InlineBufferCapacity, Allocator >::append(), and CURVE_TYPE_BEZIER.
Referenced by blender::ed::transform::curves::recalcData_curves(), and blender::ed::transform::greasepencil::recalcData_grease_pencil().
| Span< StringRef > blender::ed::curves::get_curves_selection_attribute_names | ( | const bke::CurvesGeometry & | curves | ) |
Get selection attribute names need for given curve and domain. Possible outcomes: [".selection", ".selection_handle_left", ".selection_handle_right"] if Bezier curves are present, [".selection"] otherwise.
Definition at line 86 of file curves_selection.cc.
References blender::bke::AttributeAccessor::contains(), and get_curves_all_selection_attribute_names().
Referenced by blender::ed::transform::curves::createTransCurvesVerts(), blender::ed::transform::greasepencil::createTransGreasePencilVerts(), curve_populate_trans_data_structs(), curves_draw_exec(), blender::ed::curves::set_selection_domain::curves_set_selection_domain_exec(), duplicate_curves(), duplicate_points(), extrude_curves(), has_anything_selected(), init_selection_writers(), and blender::ed::greasepencil::selection_update().
| Span< float3 > blender::ed::curves::get_selection_attribute_positions | ( | const bke::CurvesGeometry & | curves, |
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| const StringRef | attribute_name ) |
Get the position span associated with the given selection attribute name.
Definition at line 120 of file curves_selection.cc.
References BLI_assert_unreachable, and blender::bke::crazyspace::GeometryDeformation::positions.
Referenced by select_box_mask(), select_circle_mask(), and select_lasso_mask().
Definition at line 96 of file curves_ops.cc.
References blender::VectorSet< Key, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add(), blender::VectorSet< Key, ProbingStrategy, Hash, IsEqual, Slot, Allocator >::add_new(), C, CTX_data_active_object(), CTX_DATA_BEGIN, CTX_DATA_END, CTX_data_main(), and object_has_editable_curves().
Referenced by curves_extrude_exec(), blender::ed::curves::set_selection_domain::curves_set_selection_domain_exec(), blender::ed::curves::curves_delete::delete_exec(), blender::ed::curves::curves_duplicate::delete_exec(), blender::ed::curves::clear_tilt::exec(), blender::ed::curves::curve_type_set::exec(), blender::ed::curves::cyclic_toggle::exec(), blender::ed::curves::set_handle_type::exec(), blender::ed::curves::subdivide::exec(), blender::ed::curves::switch_direction::exec(), select_all_exec(), select_ends_exec(), select_less_exec(), select_linked_exec(), select_more_exec(), select_random_exec(), blender::ed::sculpt_paint::select_random::select_random_exec(), and set_attribute_exec().
|
static |
Creates copy intervals for selection #range in the context of #curve_index. If part of the #range is outside given curve, slices it and returns false indicating remaining still needs to be handled. If whole #range was handled returns true.
Definition at line 44 of file curves_extrude.cc.
References blender::IndexRange::first(), blender::IndexRange::last(), and blender::IndexRange::size().
Referenced by calc_curves_extrusion().
| bool blender::ed::curves::has_anything_selected | ( | const bke::CurvesGeometry & | curves | ) |
Return true if any element is selected, on either domain with either type.
Definition at line 420 of file curves_selection.cc.
References contains(), has_anything_selected(), and selection.
| bool blender::ed::curves::has_anything_selected | ( | const bke::CurvesGeometry & | curves, |
| bke::AttrDomain | selection_domain ) |
Definition at line 426 of file curves_selection.cc.
References has_anything_selected().
| bool blender::ed::curves::has_anything_selected | ( | const bke::CurvesGeometry & | curves, |
| bke::AttrDomain | selection_domain, | ||
| const IndexMask & | mask ) |
Definition at line 432 of file curves_selection.cc.
References contains(), get_curves_selection_attribute_names(), has_anything_selected(), mask(), and selection.
| bool blender::ed::curves::has_anything_selected | ( | GSpan | selection | ) |
Return true if any element in the span is selected, on either domain with either type.
Definition at line 446 of file curves_selection.cc.
References contains(), has_anything_selected(), and selection.
Definition at line 869 of file curves_ops.cc.
References blender::Span< T >::begin(), blender::Span< T >::end(), and has_anything_selected().
Referenced by blender::ed::sculpt_paint::greasepencil::find_curve_mapping_from_index(), blender::ed::greasepencil::grease_pencil_copy_strokes_exec(), blender::ed::greasepencil::grease_pencil_snap_compute_centroid(), blender::ed::greasepencil::grease_pencil_snap_to_cursor_exec(), blender::ed::greasepencil::grease_pencil_snap_to_grid_exec(), has_anything_selected(), has_anything_selected(), has_anything_selected(), has_anything_selected(), has_anything_selected(), has_anything_selected(), has_anything_selected(), select_all_exec(), blender::ed::greasepencil::select_all_exec(), select_alternate(), select_ends_exec(), select_linked(), select_random_exec(), and blender::ed::sculpt_paint::select_random::select_random_exec().
| bool blender::ed::curves::has_anything_selected | ( | const VArray< bool > & | varray, |
| const IndexMask & | indices_to_check ) |
Definition at line 415 of file curves_selection.cc.
References contains(), and has_anything_selected().
| bool blender::ed::curves::has_anything_selected | ( | const VArray< bool > & | varray, |
| const IndexRange | range_to_check ) |
Definition at line 410 of file curves_selection.cc.
References contains(), and has_anything_selected().
|
static |
Definition at line 29 of file curves_add.cc.
References has_surface_deformation_node().
Referenced by ensure_surface_deformation_node_exists(), has_surface_deformation_node(), and has_surface_deformation_node().
|
static |
Definition at line 44 of file curves_add.cc.
References eModifierType_Nodes, has_surface_deformation_node(), LISTBASE_FOREACH, Object::modifiers, and NodesModifierData::node_group.
|
static |
Definition at line 187 of file curves_selection.cc.
References CURVE_TYPE_BEZIER, get_curves_bezier_selection_attribute_names(), blender::bke::crazyspace::GeometryDeformation::positions, and blender::Span< T >::size().
Referenced by foreach_selectable_curve_range(), and foreach_selectable_point_range().
|
static |
Definition at line 138 of file curves_selection.cc.
References blender::Vector< T, InlineBufferCapacity, Allocator >::append(), CD_PROP_BOOL, ensure_selection_attribute(), get_curves_selection_attribute_names(), and blender::Span< T >::index_range().
Referenced by foreach_selection_attribute_writer(), select_box(), select_circle(), select_lasso(), and select_linked().
|
static |
Definition at line 470 of file curves_selection.cc.
References blender::array_utils::invert_booleans(), invert_selection(), and selection.
|
static |
Definition at line 486 of file curves_selection.cc.
References blender::array_utils::invert_booleans(), invert_selection(), mask(), and selection.
|
static |
Definition at line 461 of file curves_selection.cc.
References invert_selection(), blender::threading::parallel_for(), and selection.
Referenced by invert_selection(), invert_selection(), invert_selection(), invert_selection(), select_adjacent(), and select_all().
|
static |
Definition at line 480 of file curves_selection.cc.
References invert_selection(), mask(), and selection.
| void blender::ed::curves::keymap_curves | ( | wmKeyConfig * | keyconf | ) |
Definition at line 1821 of file curves_ops.cc.
References editable_curves_in_edit_mode_poll(), keymap_curves(), wmKeyMap::poll, RGN_TYPE_WINDOW, SPACE_EMPTY, and WM_keymap_ensure().
Referenced by ED_spacetypes_keymap(), and keymap_curves().
Definition at line 82 of file curves_ops.cc.
References BKE_id_is_editable(), data, ELEM, OB_CURVES, OB_MODE_EDIT, and OB_MODE_SCULPT_CURVES.
Referenced by get_unique_editable_curves().
| void blender::ed::curves::operatormacros_curves | ( | ) |
Definition at line 1795 of file curves_ops.cc.
References operatormacros_curves(), OPTYPE_REGISTER, OPTYPE_UNDO, ot, wmOperatorTypeMacro::ptr, RNA_boolean_set(), WM_operatortype_append_macro(), and WM_operatortype_macro_define().
Referenced by ED_spacemacros_init(), and operatormacros_curves().
| void blender::ed::curves::operatortypes_curves | ( | ) |
Definition at line 1767 of file curves_ops.cc.
References CURVES_OT_add_bezier(), CURVES_OT_add_circle(), CURVES_OT_attribute_set(), CURVES_OT_convert_from_particle_system(), CURVES_OT_convert_to_particle_system(), CURVES_OT_curve_type_set(), CURVES_OT_cyclic_toggle(), CURVES_OT_delete(), CURVES_OT_draw(), CURVES_OT_duplicate(), CURVES_OT_extrude(), CURVES_OT_handle_type_set(), CURVES_OT_select_all(), CURVES_OT_select_ends(), CURVES_OT_select_less(), CURVES_OT_select_linked(), CURVES_OT_select_more(), CURVES_OT_select_random(), CURVES_OT_set_selection_domain(), CURVES_OT_snap_curves_to_surface(), CURVES_OT_subdivide(), CURVES_OT_surface_set(), CURVES_OT_switch_direction(), CURVES_OT_tilt_clear(), operatortypes_curves(), and WM_operatortype_append().
Referenced by ED_spacetypes_init(), and operatortypes_curves().
Return an owning pointer to an array of point normals the same size as the number of control points. The normals depend on the normal mode for each curve and the "tilt" attribute and may be calculated for the evaluated points and sampled back to the control points.
Definition at line 43 of file curves_data.cc.
References blender::bke::curves_normals_point_domain_calc(), data, MEM_malloc_arrayN, and size().
| bke::CurvesGeometry blender::ed::curves::primitive_random_sphere | ( | const int | curves_size, |
| const int | points_per_curve ) |
Definition at line 110 of file curves_add.cc.
References blender::bke::SpanAttributeWriter< T >::finish(), float, blender::RandomNumberGenerator::get_float(), blender::MutableSpan< T >::index_range(), blender::bke::MutableAttributeAccessor::lookup_or_add_for_write_only_span(), M_PI, blender::math::normalize(), blender::bke::Point, safe_acosf(), blender::MutableSpan< T >::slice(), and blender::bke::SpanAttributeWriter< T >::span.
Referenced by blender::ed::object::object_curves_random_add_exec().
| IndexMask blender::ed::curves::random_mask | ( | const bke::CurvesGeometry & | curves, |
| bke::AttrDomain | selection_domain, | ||
| uint32_t | random_seed, | ||
| float | probability, | ||
| IndexMaskMemory & | memory ) |
Return a mask of random points or curves.
| mask | (optional): The elements that should be used in the resulting mask. This mask should be in the same domain as the selection_domain. |
| random_seed | The seed for the RandomNumberGenerator. |
| probability | Determines how likely a point/curve will be chosen. If set to 0.0, nothing will be in the mask, if set to 1.0 everything will be in the mask. |
Definition at line 87 of file curves_masks.cc.
References random_mask(), and selection.
| IndexMask blender::ed::curves::random_mask | ( | const bke::CurvesGeometry & | curves, |
| const IndexMask & | mask, | ||
| const bke::AttrDomain | selection_domain, | ||
| const uint32_t | random_seed, | ||
| const float | probability, | ||
| IndexMaskMemory & | memory ) |
Definition at line 68 of file curves_masks.cc.
References IndexMask::from_bools(), blender::RandomNumberGenerator::get_float(), mask(), random(), and random_mask().
Referenced by random_mask(), random_mask(), select_random_exec(), and blender::ed::greasepencil::select_random_exec().
| bool blender::ed::curves::remove_selection | ( | bke::CurvesGeometry & | curves, |
| bke::AttrDomain | selection_domain ) |
Remove (dissolve) selected curves or points based on the ".selection" attribute.
Definition at line 19 of file curves_edit.cc.
References BLI_assert_unreachable, blender::bke::Curve, blender::bke::AttributeAccessor::domain_size(), blender::IndexMask::from_bools(), blender::bke::AttributeAccessor::lookup_or_default(), mask(), blender::bke::Point, and selection.
Referenced by blender::ed::curves::curves_delete::delete_exec().
| void blender::ed::curves::remove_selection_attributes | ( | bke::MutableAttributeAccessor & | attributes, |
| Span< StringRef > | selection_attribute_names = get_curves_all_selection_attribute_names() ) |
Used to select everything or to delete selection attribute so that it will not have to be resized.
Definition at line 112 of file curves_selection.cc.
References blender::bke::MutableAttributeAccessor::remove().
Referenced by curves_draw_exec(), duplicate_curves(), duplicate_points(), and select_all().
| void blender::ed::curves::resize_curves | ( | bke::CurvesGeometry & | curves, |
| const IndexMask & | curves_to_resize, | ||
| Span< int > | new_sizes ) |
Resizes the curves in curves.
| curves_to_resize | The curves that should be resized. |
| new_sizes | The new size for each curve in curves_to_resize. If the size is smaller, the curve is trimmed from the end. If the size is larger, the end is extended and all attributes are default initialized. Sizes must be > 0. |
Definition at line 249 of file curves_edit.cc.
References blender::offset_indices::accumulate_counts_to_offsets(), blender::bke::attribute_name_is_anonymous(), blender::bke::CurvesGeometry::attributes_for_write(), BLI_assert, blender::index_mask::IndexMask::complement(), blender::GMutableSpan::copy_from(), blender::MutableSpan< T >::copy_from(), blender::offset_indices::copy_group_sizes(), blender::array_utils::copy_group_to_group(), blender::bke::curves::copy_only_curve_domain(), blender::bke::CurvesGeometry::curves_num(), blender::GMutableSpan::data(), blender::bke::AttributeIter::data_type, blender::bke::AttributeIter::domain, blender::IndexRange::drop_back(), MutableSpan< T >::drop_back(), blender::bke::GSpanAttributeWriter::finish(), blender::bke::AttributeAccessor::foreach_attribute(), blender::index_mask::IndexMask::foreach_index(), blender::bke::AttributeIter::get(), blender::index_mask::IndexMask::is_empty(), Span< T >::last(), blender::bke::MutableAttributeAccessor::lookup_or_add_for_write_only_span(), blender::bke::AttributeIter::name, blender::bke::CurvesGeometry::offsets(), blender::bke::CurvesGeometry::offsets_for_write(), blender::bke::Point, blender::bke::CurvesGeometry::points_by_curve(), blender::bke::CurvesGeometry::resize(), blender::array_utils::scatter(), blender::GMutableSpan::size(), blender::index_mask::IndexMask::size(), blender::IndexRange::size(), blender::Span< T >::size(), blender::GMutableSpan::slice(), blender::GSpan::slice(), blender::bke::GSpanAttributeWriter::span, blender::IndexRange::take_back(), blender::index_mask::IndexMask::to_range(), blender::GSpan::type(), blender::bke::CurvesGeometry::update_curve_types(), and blender::CPPType::value_initialize_n().
| IndexMask blender::ed::curves::retrieve_selected_curves | ( | const bke::CurvesGeometry & | curves, |
| IndexMaskMemory & | memory ) |
Find curves that have any point selected (a selection factor greater than zero), or curves that have their own selection factor greater than zero.
Definition at line 28 of file curves_selection.cc.
References blender::Array< T, InlineBufferCapacity, Allocator >::as_span(), blender::bke::Curve, blender::IndexMask::from_bools(), blender::IndexMask::from_predicate(), blender::bke::AttributeAccessor::lookup_meta_data(), blender::bke::AttributeAccessor::lookup_or_default(), blender::bke::Point, selection, and blender::IndexRange::size().
Referenced by blender::ed::spreadsheet::GeometryDataSource::apply_selection_filter(), blender::ed::curves::curves_duplicate::delete_exec(), blender::ed::curves::curve_type_set::exec(), blender::ed::curves::cyclic_toggle::exec(), blender::ed::curves::switch_direction::exec(), blender::ed::sculpt_paint::CombOperationExecutor::execute(), blender::ed::sculpt_paint::CurvesEffectOperationExecutor::execute(), blender::ed::sculpt_paint::DeleteOperationExecutor::execute(), blender::ed::sculpt_paint::DensitySubtractOperationExecutor::execute(), blender::ed::sculpt_paint::PinchOperationExecutor::execute(), blender::ed::sculpt_paint::PuffOperationExecutor::execute(), blender::ed::sculpt_paint::SlideOperationExecutor::execute(), blender::ed::sculpt_paint::SmoothOperationExecutor::execute(), blender::ed::sculpt_paint::SnakeHookOperatorExecutor::execute(), blender::ed::sculpt_paint::greasepencil::find_curve_mapping_from_index(), blender::ed::greasepencil::grease_pencil_copy_strokes_exec(), blender::ed::greasepencil::grease_pencil_move_to_layer_exec(), blender::ed::greasepencil::grease_pencil_snap_to_cursor_exec(), blender::ed::greasepencil::retrieve_editable_and_selected_fill_strokes(), blender::ed::greasepencil::retrieve_editable_and_selected_strokes(), retrieve_selected_curves(), and retrieve_selected_elements().
| IndexMask blender::ed::curves::retrieve_selected_curves | ( | const Curves & | curves_id, |
| IndexMaskMemory & | memory ) |
Definition at line 60 of file curves_selection.cc.
References Curves::geometry, and retrieve_selected_curves().
|
static |
Definition at line 58 of file curves_attribute_set.cc.
References BLI_assert_unreachable, blender::bke::Curve, blender::bke::Point, retrieve_selected_curves(), and retrieve_selected_points().
Referenced by set_attribute_exec(), and set_attribute_invoke().
| IndexMask blender::ed::curves::retrieve_selected_points | ( | const bke::CurvesGeometry & | curves, |
| IndexMaskMemory & | memory ) |
Find points that are selected (a selection factor greater than zero), or points in curves with a selection factor greater than zero).
Definition at line 66 of file curves_selection.cc.
References retrieve_selected_points().
Referenced by blender::ed::spreadsheet::GeometryDataSource::apply_selection_filter(), blender::ed::transform::curves::createTransCurvesVerts(), blender::ed::transform::greasepencil::createTransGreasePencilVerts(), blender::ed::curves::curves_duplicate::delete_exec(), ED_view3d_minmax_verts(), blender::ed::curves::clear_tilt::exec(), blender::ed::curves::subdivide::exec(), extrude_curves(), gizmo_3d_foreach_selected(), blender::ed::greasepencil::grease_pencil_copy_strokes_exec(), blender::ed::greasepencil::grease_pencil_separate_selected(), blender::ed::greasepencil::grease_pencil_snap_compute_centroid(), blender::ed::greasepencil::grease_pencil_snap_to_cursor_exec(), blender::ed::greasepencil::grease_pencil_snap_to_grid_exec(), blender::ed::greasepencil::retrieve_editable_and_selected_points(), retrieve_selected_elements(), retrieve_selected_points(), retrieve_selected_points(), blender::ed::sculpt_paint::select_grow::select_grow_invoke_per_curve(), and transverts_from_curves_positions_create().
| IndexMask blender::ed::curves::retrieve_selected_points | ( | const bke::CurvesGeometry & | curves, |
| StringRef | attribute_name, | ||
| IndexMaskMemory & | memory ) |
Definition at line 71 of file curves_selection.cc.
References blender::IndexMask::from_bools(), and blender::bke::Point.
| IndexMask blender::ed::curves::retrieve_selected_points | ( | const Curves & | curves_id, |
| IndexMaskMemory & | memory ) |
Definition at line 80 of file curves_selection.cc.
References Curves::geometry, and retrieve_selected_points().
| void blender::ed::curves::select_adjacent | ( | bke::CurvesGeometry & | curves, |
| bool | deselect ) |
(De)select all the adjacent points of the current selected points.
| curves_mask | (optional): The curves that should be affected. |
Definition at line 704 of file curves_selection.cc.
References select_adjacent().
| void blender::ed::curves::select_adjacent | ( | bke::CurvesGeometry & | curves, |
| const IndexMask & | curves_mask, | ||
| const bool | deselect ) |
Definition at line 616 of file curves_selection.cc.
References CD_PROP_BOOL, ensure_selection_attribute(), blender::IndexRange::first(), blender::index_mask::IndexMask::foreach_index(), invert_selection(), blender::IndexRange::last(), blender::bke::Point, select_adjacent(), and selection.
Referenced by select_adjacent(), select_adjacent(), select_less_exec(), and select_more_exec().
| IndexMask blender::ed::curves::select_adjacent_mask | ( | const bke::CurvesGeometry & | curves, |
| const IndexMask & | curves_mask, | ||
| const StringRef | attribute_name, | ||
| const bool | deselect, | ||
| IndexMaskMemory & | memory ) |
Definition at line 1289 of file curves_selection.cc.
References blender::IndexRange::drop_back(), blender::IndexRange::drop_front(), blender::IndexRange::first(), blender::index_mask::IndexMask::foreach_index(), IndexMask::from_bools(), blender::IndexRange::last(), blender::bke::Point, point, select_adjacent_mask(), selection, and blender::IndexRange::size().
Referenced by select_adjacent_mask(), select_adjacent_mask(), blender::ed::greasepencil::select_less_exec(), and blender::ed::greasepencil::select_more_exec().
| IndexMask blender::ed::curves::select_adjacent_mask | ( | const bke::CurvesGeometry & | curves, |
| StringRef | attribute_name, | ||
| bool | deselect, | ||
| IndexMaskMemory & | memory ) |
Mask of points adjacent to a selected point, or unselected point if deselect is true.
Definition at line 1341 of file curves_selection.cc.
References select_adjacent_mask().
| void blender::ed::curves::select_all | ( | bke::CurvesGeometry & | curves, |
| bke::AttrDomain | selection_domain, | ||
| int | action ) |
(De)select all the curves.
| mask | (optional): The elements that should be affected. This mask should be in the domain of the selection_domain. |
| action | One of SEL_TOGGLE, SEL_SELECT, SEL_DESELECT, or SEL_INVERT. See ED_select_utils.hh. |
Definition at line 526 of file curves_selection.cc.
References select_all(), and selection.
| void blender::ed::curves::select_all | ( | bke::CurvesGeometry & | curves, |
| const IndexMask & | mask, | ||
| const bke::AttrDomain | selection_domain, | ||
| int | action ) |
Definition at line 496 of file curves_selection.cc.
References fill_selection_false(), fill_selection_true(), foreach_selection_attribute_writer(), invert_selection(), mask(), remove_selection_attributes(), SEL_DESELECT, SEL_INVERT, SEL_SELECT, select_all(), and selection.
Referenced by select_all(), select_all(), select_all_exec(), blender::ed::greasepencil::select_all_exec(), and blender::ed::greasepencil::select_similar_by_layer().
|
static |
Definition at line 876 of file curves_ops.cc.
References C, DEG_id_tag_update(), get_unique_editable_curves(), has_anything_selected(), ID_RECALC_GEOMETRY, NC_GEOM, ND_DATA, OPERATOR_FINISHED, wmOperator::ptr, RNA_enum_get(), SEL_DESELECT, SEL_SELECT, SEL_TOGGLE, select_all(), and WM_event_add_notifier().
Referenced by CURVES_OT_select_all().
| void blender::ed::curves::select_alternate | ( | bke::CurvesGeometry & | curves, |
| const bool | deselect_ends ) |
Select alternated points in strokes with already selected points
| curves_mask | (optional): The curves that should be affected. |
Definition at line 611 of file curves_selection.cc.
References select_alternate().
| void blender::ed::curves::select_alternate | ( | bke::CurvesGeometry & | curves, |
| const IndexMask & | curves_mask, | ||
| const bool | deselect_ends ) |
Definition at line 567 of file curves_selection.cc.
References CD_PROP_BOOL, blender::IndexRange::drop_back(), blender::IndexRange::drop_front(), ensure_selection_attribute(), blender::IndexRange::first(), blender::index_mask::IndexMask::foreach_index(), has_anything_selected(), blender::IndexRange::is_empty(), blender::IndexRange::last(), blender::bke::Point, select_alternate(), selection, blender::IndexRange::shift(), and blender::IndexRange::size().
Referenced by select_alternate(), select_alternate(), and blender::ed::greasepencil::select_alternate_exec().
| bool blender::ed::curves::select_box | ( | const ViewContext & | vc, |
| bke::CurvesGeometry & | curves, | ||
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| const float4x4 & | projection, | ||
| const IndexMask & | selection_mask, | ||
| const IndexMask & | bezier_mask, | ||
| bke::AttrDomain | selection_domain, | ||
| const rcti & | rect, | ||
| eSelectOp | sel_op ) |
Select points or curves in a (screen-space) rectangle.
Definition at line 928 of file curves_selection.cc.
References apply_selection_operation_at_index(), BLI_rcti_isect_pt_v(), BLI_rcti_isect_segment(), blender::bke::Curve, blender::IndexRange::drop_back(), ED_view3d_project_float_v2_m4(), fill_selection_false(), finish_attribute_writers(), blender::IndexRange::first(), foreach_selectable_curve_range(), foreach_selectable_point_range(), init_selection_writers(), int2, blender::IndexRange::last(), mask(), blender::bke::Point, ViewContext::region, SEL_OP_SET, select_box(), selection, selection_attribute_writer_by_name(), and blender::IndexRange::size().
Referenced by select_box(), and view3d_box_select_exec().
| IndexMask blender::ed::curves::select_box_mask | ( | const ViewContext & | vc, |
| const bke::CurvesGeometry & | curves, | ||
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| const float4x4 & | projection, | ||
| const IndexMask & | selection_mask, | ||
| const IndexMask & | bezier_mask, | ||
| bke::AttrDomain | selection_domain, | ||
| StringRef | attribute_name, | ||
| const rcti & | rect, | ||
| IndexMaskMemory & | memory ) |
Select points or curves in a (screen-space) rectangle.
Definition at line 1349 of file curves_selection.cc.
References BLI_rcti_isect_pt_v(), BLI_rcti_isect_segment(), ED_view3d_project_float_v2_m4(), get_selection_attribute_positions(), int2, mask(), blender::bke::Point, ViewContext::region, select_box_mask(), and select_mask_from_predicates().
Referenced by do_grease_pencil_box_select(), and select_box_mask().
| bool blender::ed::curves::select_circle | ( | const ViewContext & | vc, |
| bke::CurvesGeometry & | curves, | ||
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| const float4x4 & | projection, | ||
| const IndexMask & | selection_mask, | ||
| const IndexMask & | bezier_mask, | ||
| bke::AttrDomain | selection_domain, | ||
| int2 | coord, | ||
| float | radius, | ||
| eSelectOp | sel_op ) |
Select points or curves in a (screen-space) circle.
Definition at line 1143 of file curves_selection.cc.
References apply_selection_operation_at_index(), blender::bke::Curve, dist_squared_to_line_segment_v2(), blender::math::distance_squared(), blender::IndexRange::drop_back(), ED_view3d_project_float_v2_m4(), fill_selection_false(), finish_attribute_writers(), blender::IndexRange::first(), foreach_selectable_curve_range(), foreach_selectable_point_range(), init_selection_writers(), blender::IndexRange::last(), mask(), blender::bke::Point, pow2f(), ViewContext::region, SEL_OP_SET, select_circle(), selection, selection_attribute_writer_by_name(), and blender::IndexRange::size().
Referenced by obedit_circle_select(), and select_circle().
| IndexMask blender::ed::curves::select_circle_mask | ( | const ViewContext & | vc, |
| const bke::CurvesGeometry & | curves, | ||
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| const float4x4 & | projection, | ||
| const IndexMask & | selection_mask, | ||
| const IndexMask & | bezier_mask, | ||
| bke::AttrDomain | selection_domain, | ||
| StringRef | attribute_name, | ||
| int2 | coord, | ||
| float | radius, | ||
| IndexMaskMemory & | memory ) |
Select points or curves in a (screen-space) circle.
Definition at line 1430 of file curves_selection.cc.
References dist_squared_to_line_segment_v2(), blender::math::distance_squared(), ED_view3d_project_float_v2_m4(), get_selection_attribute_positions(), mask(), blender::bke::Point, pow2f(), ViewContext::region, select_circle_mask(), and select_mask_from_predicates().
Referenced by grease_pencil_circle_select(), and select_circle_mask().
|
static |
Definition at line 988 of file curves_ops.cc.
References C, CD_PROP_BOOL, DEG_id_tag_update(), end_points(), ensure_selection_attribute(), fill_selection_true(), get_unique_editable_curves(), has_anything_selected(), ID_RECALC_GEOMETRY, blender::index_mask::masked_fill(), NC_GEOM, ND_DATA, OPERATOR_FINISHED, blender::bke::Point, wmOperator::ptr, RNA_int_get(), select_ends_exec(), selection, and WM_event_add_notifier().
Referenced by CURVES_OT_select_ends(), and select_ends_exec().
|
static |
Definition at line 1025 of file curves_ops.cc.
References col, IFACE_, wmOperator::layout, wmOperator::ptr, select_ends_ui(), UI_ITEM_NONE, uiItemR(), uiLayoutColumn(), uiLayoutSetPropDecorate(), and uiLayoutSetPropSep().
Referenced by CURVES_OT_select_ends(), and select_ends_ui().
| bool blender::ed::curves::select_lasso | ( | const ViewContext & | vc, |
| bke::CurvesGeometry & | curves, | ||
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| const float4x4 & | projection_matrix, | ||
| const IndexMask & | selection_mask, | ||
| const IndexMask & | bezier_mask, | ||
| bke::AttrDomain | selection_domain, | ||
| Span< int2 > | lasso_coords, | ||
| eSelectOp | sel_op ) |
Select points or curves in a (screen-space) poly shape.
Definition at line 1026 of file curves_selection.cc.
References apply_selection_operation_at_index(), BLI_lasso_boundbox(), BLI_lasso_is_edge_inside(), BLI_lasso_is_point_inside(), BLI_rcti_isect_pt_v(), BLI_rcti_isect_segment(), blender::bke::Curve, blender::IndexRange::drop_back(), ED_view3d_project_float_v2_m4(), fill_selection_false(), finish_attribute_writers(), blender::IndexRange::first(), foreach_selectable_curve_range(), foreach_selectable_point_range(), init_selection_writers(), int2, IS_CLIPPED, blender::IndexRange::last(), mask(), blender::bke::Point, ViewContext::region, SEL_OP_SET, select_lasso(), selection, selection_attribute_writer_by_name(), and blender::IndexRange::size().
Referenced by select_lasso(), and view3d_lasso_select().
| IndexMask blender::ed::curves::select_lasso_mask | ( | const ViewContext & | vc, |
| const bke::CurvesGeometry & | curves, | ||
| const bke::crazyspace::GeometryDeformation & | deformation, | ||
| const float4x4 & | projection, | ||
| const IndexMask & | selection_mask, | ||
| const IndexMask & | bezier_mask, | ||
| bke::AttrDomain | selection_domain, | ||
| StringRef | attribute_name, | ||
| Span< int2 > | lasso_coords, | ||
| IndexMaskMemory & | memory ) |
Select points or curves in a (screen-space) poly shape.
Definition at line 1385 of file curves_selection.cc.
References BLI_lasso_boundbox(), BLI_lasso_is_edge_inside(), BLI_lasso_is_point_inside(), BLI_rcti_isect_pt_v(), BLI_rcti_isect_segment(), ED_view3d_project_float_v2_m4(), get_selection_attribute_positions(), int2, IS_CLIPPED, mask(), blender::bke::Point, ViewContext::region, select_lasso_mask(), and select_mask_from_predicates().
Referenced by do_lasso_select_grease_pencil(), and select_lasso_mask().
|
static |
Definition at line 1123 of file curves_ops.cc.
References C, DEG_id_tag_update(), get_unique_editable_curves(), ID_RECALC_GEOMETRY, NC_GEOM, ND_DATA, OPERATOR_FINISHED, select_adjacent(), and WM_event_add_notifier().
Referenced by CURVES_OT_select_less().
| void blender::ed::curves::select_linked | ( | bke::CurvesGeometry & | curves | ) |
Select the points of all curves that have at least one point selected.
| curves_mask | (optional): The curves that should be affected. |
Definition at line 562 of file curves_selection.cc.
References select_linked().
| void blender::ed::curves::select_linked | ( | bke::CurvesGeometry & | curves, |
| const IndexMask & | curves_mask ) |
Definition at line 532 of file curves_selection.cc.
References CURVE_TYPE_BEZIER, fill_selection_true(), finish_attribute_writers(), blender::index_mask::IndexMask::foreach_index(), has_anything_selected(), blender::Vector< T, InlineBufferCapacity, Allocator >::index_range(), init_selection_writers(), blender::bke::Point, select_linked(), and selection.
Referenced by select_linked(), select_linked(), select_linked_exec(), blender::ed::greasepencil::select_linked_exec(), and blender::ed::greasepencil::select_set_mode_exec().
|
static |
Definition at line 1069 of file curves_ops.cc.
References C, DEG_id_tag_update(), get_unique_editable_curves(), ID_RECALC_GEOMETRY, NC_GEOM, ND_DATA, OPERATOR_FINISHED, select_linked(), and WM_event_add_notifier().
Referenced by CURVES_OT_select_linked().
| IndexMask blender::ed::curves::select_mask_from_predicates | ( | const bke::CurvesGeometry & | curves, |
| const IndexMask & | mask, | ||
| const bke::AttrDomain | selection_domain, | ||
| IndexMaskMemory & | memory, | ||
| PointSelectFn && | point_predicate, | ||
| LineSelectFn && | line_predicate ) |
Definition at line 1245 of file curves_selection.cc.
References blender::bke::Curve, blender::IndexRange::drop_back(), blender::IndexRange::first(), IndexMask::from_predicate(), is_cyclic(), blender::IndexRange::last(), mask(), blender::bke::Point, select_mask_from_predicates(), and blender::IndexRange::size().
Referenced by select_box_mask(), select_circle_mask(), select_lasso_mask(), and select_mask_from_predicates().
|
static |
Definition at line 1096 of file curves_ops.cc.
References C, DEG_id_tag_update(), get_unique_editable_curves(), ID_RECALC_GEOMETRY, NC_GEOM, ND_DATA, OPERATOR_FINISHED, select_adjacent(), and WM_event_add_notifier().
Referenced by CURVES_OT_select_more().
|
static |
Definition at line 913 of file curves_ops.cc.
References C, CD_PROP_BOOL, DEG_id_tag_update(), ensure_selection_attribute(), fill_selection_false(), fill_selection_true(), get_unique_editable_curves(), has_anything_selected(), ID_RECALC_GEOMETRY, NC_GEOM, ND_DATA, OPERATOR_FINISHED, wmOperator::ptr, random_mask(), RNA_float_get(), RNA_int_get(), seed, selection, and WM_event_add_notifier().
Referenced by CURVES_OT_select_random().
|
static |
Definition at line 948 of file curves_ops.cc.
References IFACE_, wmOperator::layout, wmOperator::ptr, select_random_ui(), UI_ITEM_NONE, UI_ITEM_R_SLIDER, and uiItemR().
Referenced by CURVES_OT_select_random(), and select_random_ui().
|
static |
Definition at line 158 of file curves_selection.cc.
References BLI_assert, BLI_assert_unreachable, blender::Span< T >::contains(), get_curves_all_selection_attribute_names(), blender::MutableSpan< T >::index_range(), blender::Span< T >::size(), and blender::StringRefBase::size().
Referenced by select_box(), select_circle(), and select_lasso().
|
static |
Definition at line 95 of file curves_attribute_set.cc.
References attribute, BKE_attributes_active_get(), BLI_SCOPED_DEFER, BUFFER_FOR_CPP_TYPE_VALUE, C, blender::bke::DataTypeConversions::convert_to_uninitialized(), CTX_data_active_object(), blender::bke::custom_data_type_to_cpp_type(), Object::data, DEG_id_tag_update(), blender::CPPType::destruct(), blender::CPPType::fill_assign_indices(), AttributeOwner::from_id(), blender::CPPType::get(), blender::GPointer::get(), blender::bke::get_implicit_type_conversions(), get_unique_editable_curves(), Curves::id, ID_RECALC_GEOMETRY, blender::bke::DataTypeConversions::is_convertible(), blender::bke::MutableAttributeAccessor::lookup_for_write_span(), CustomDataLayer::name, NC_GEOM, ND_DATA, OPERATOR_FINISHED, wmOperator::ptr, retrieve_selected_elements(), blender::ed::geometry::rna_property_for_attribute_type_retrieve_value(), selection, CustomDataLayer::type, validate_value(), and WM_event_add_notifier().
Referenced by CURVES_OT_attribute_set().
|
static |
Definition at line 150 of file curves_attribute_set.cc.
References attribute, BKE_attributes_active_get(), BLI_SCOPED_DEFER, BUFFER_FOR_CPP_TYPE_VALUE, C, blender::bke::attribute_math::convert_to_static_type(), blender::bke::cpp_type_to_custom_data_type(), CTX_data_active_object(), Object::data, blender::CPPType::destruct(), AttributeOwner::from_id(), Curves::geometry, Curves::id, blender::bke::AttributeAccessor::lookup(), CustomDataLayer::name, wmOperator::ptr, retrieve_selected_elements(), blender::ed::geometry::rna_property_for_attribute_type_set_value(), blender::ed::geometry::rna_property_for_type(), RNA_property_is_set(), selection, T, and WM_operator_props_popup().
Referenced by CURVES_OT_attribute_set().
|
static |
Definition at line 189 of file curves_attribute_set.cc.
References BKE_attributes_active_get(), C, blender::StringRefNull::c_str(), CTX_data_active_object(), AttributeOwner::from_id(), Curves::id, wmOperator::layout, CustomDataLayer::name, wmOperator::ptr, blender::ed::geometry::rna_property_name_for_type(), CustomDataLayer::type, UI_ITEM_NONE, uiItemR(), uiLayoutColumn(), uiLayoutSetPropDecorate(), and uiLayoutSetPropSep().
Referenced by CURVES_OT_attribute_set().
|
static |
Definition at line 150 of file curves_draw.cc.
References interp_v2_v2v2(), interp_v3_v3v3(), interpf(), blender::ed::curves::StrokeElem::location_local, blender::ed::curves::StrokeElem::location_world, blender::ed::curves::StrokeElem::mval, and blender::ed::curves::StrokeElem::pressure.
Referenced by curve_draw_event_add().
|
static |
Definition at line 136 of file curves_draw.cc.
References is_zero_v3(), blender::ed::curves::StrokeElem::location_local, blender::ed::curves::StrokeElem::location_world, madd_v3_v3fl(), mul_v3_m4v3(), blender::ed::curves::StrokeElem::normal_local, ViewContext::obedit, blender::ed::curves::StrokeElem::pressure, blender::ed::curves::CurveDrawData::project, stroke_elem_radius_from_pressure(), blender::ed::curves::CurveDrawData::surface_offset, blender::ed::curves::CurveDrawData::use_surface_offset_absolute, and blender::ed::curves::CurveDrawData::vc.
Referenced by curve_draw_exec_precalc().
|
static |
Sets the depth from StrokeElem.mval
Definition at line 164 of file curves_draw.cc.
References add_v3_v3(), copy_v3_v3(), ViewDepths::depth_range, blender::ed::curves::CurveDrawData::depths, double(), ED_view3d_depth_read_cached(), ED_view3d_depth_read_cached_normal(), ED_view3d_depth_unproject_v3(), ED_view3d_win_to_3d_on_plane(), ViewDepths::h, madd_v3_v3fl(), blender::ed::curves::CurveDrawData::offset, blender::ed::curves::CurveDrawData::plane, blender::ed::curves::CurveDrawData::project, ViewContext::region, blender::ed::curves::CurveDrawData::use_offset, blender::ed::curves::CurveDrawData::use_plane, blender::ed::curves::CurveDrawData::use_surface_offset_absolute, blender::ed::curves::CurveDrawData::vc, ViewDepths::w, and zero_v3().
Referenced by curve_draw_event_add_first(), and stroke_elem_project_fallback().
|
static |
Definition at line 224 of file curves_draw.cc.
References copy_v3_v3(), ED_view3d_win_to_3d(), is_zero_v3(), mul_transposed_mat3_m4_v3(), mul_v3_m4v3(), normalize_v3(), ViewContext::obedit, ViewContext::region, stroke_elem_project(), ViewContext::v3d, blender::ed::curves::CurveDrawData::vc, and zero_v3().
Referenced by stroke_elem_project_fallback_elem().
|
static |
Definition at line 259 of file curves_draw.cc.
References int, blender::ed::curves::StrokeElem::location_local, blender::ed::curves::StrokeElem::location_world, blender::ed::curves::StrokeElem::mval, blender::ed::curves::StrokeElem::normal_local, blender::ed::curves::StrokeElem::normal_world, blender::ed::curves::CurveDrawData::project, stroke_elem_project_fallback(), stroke_elem_radius(), and blender::ed::curves::CurveDrawData::surface_offset.
Referenced by curve_draw_event_add().
|
static |
Definition at line 131 of file curves_draw.cc.
References blender::ed::curves::StrokeElem::pressure, and stroke_elem_radius_from_pressure().
Referenced by curve_draw_stroke_3d(), and stroke_elem_project_fallback_elem().
|
static |
Definition at line 126 of file curves_draw.cc.
References blender::ed::curves::CurveDrawData::bevel_radius, blender::ed::curves::CurveDrawData::min, blender::ed::curves::CurveDrawData::radius, and blender::ed::curves::CurveDrawData::range.
Referenced by stroke_elem_pressure_set(), and stroke_elem_radius().
| void blender::ed::curves::transverts_from_curves_positions_create | ( | bke::CurvesGeometry & | curves, |
| TransVertStore * | tvs ) |
Allocate an array of TransVert for cursor/selection snapping (See ED_transverts_create_from_obedit in view3d_snap.cc).
Definition at line 25 of file curves_data.cc.
References copy_v3_v3(), TransVert::flag, TransVert::loc, MEM_calloc_arrayN, TransVert::oldloc, pos, retrieve_selected_points(), SELECT, selection, TransVertStore::transverts, and TransVertStore::transverts_tot.
Referenced by ED_transverts_create_from_obedit().
| void blender::ed::curves::undosys_type_register | ( | UndoType * | ut | ) |
Definition at line 135 of file curves_undo.cc.
References editable_curves_in_edit_mode_poll(), UndoType::flags, blender::ed::curves::undo::foreach_ID_ref(), UndoType::name, UndoType::poll, blender::ed::curves::undo::step_decode(), UndoType::step_decode, blender::ed::curves::undo::step_encode(), UndoType::step_encode, UndoType::step_foreach_ID_ref, blender::ed::curves::undo::step_free(), UndoType::step_free, UndoType::step_size, undosys_type_register(), and UNDOTYPE_FLAG_NEED_CONTEXT_FOR_ENCODE.
Referenced by ED_undosys_type_init(), and undosys_type_register().
|
static |
Definition at line 73 of file curves_attribute_set.cc.
References BLI_SCOPED_DEFER, BUFFER_FOR_CPP_TYPE_VALUE, blender::fn::multi_function::MultiFunction::call(), blender::CPPType::copy_assign(), blender::CPPType::destruct(), blender::bke::AttributeValidator::function, blender::bke::AttributeAccessor::lookup_validator(), and params.
Referenced by set_attribute_exec().