Blender V4.3
blender::ed::transform::curves Namespace Reference

Functions

static void calculate_curve_point_distances_for_proportional_editing (const Span< float3 > positions, MutableSpan< float > r_distances)
 
static MutableSpan< float3append_positions_to_custom_data (const IndexMask selection, Span< float3 > positions, TransCustomData &custom_data)
 
static void createTransCurvesVerts (bContext *, TransInfo *t)
 
static void recalcData_curves (TransInfo *t)
 
static OffsetIndices< intrecent_position_offsets (TransCustomData &custom_data, int num)
 
static void fill_map (const CurveType curve_type, const IndexRange curve_points, const OffsetIndices< int > position_offsets_in_td, const int handles_offset, MutableSpan< int > map)
 

Function Documentation

◆ append_positions_to_custom_data()

◆ calculate_curve_point_distances_for_proportional_editing()

static void blender::ed::transform::curves::calculate_curve_point_distances_for_proportional_editing ( const Span< float3 > positions,
MutableSpan< float > r_distances )
static

Definition at line 34 of file transform_convert_curves.cc.

References blender::math::distance(), and visited.

◆ createTransCurvesVerts()

static void blender::ed::transform::curves::createTransCurvesVerts ( bContext * ,
TransInfo * t )
static

Definition at line 83 of file transform_convert_curves.cc.

References blender::Vector< T, InlineBufferCapacity, Allocator >::append(), blender::Vector< T, InlineBufferCapacity, Allocator >::as_span(), BEZIER_HANDLE_ALIGN, BEZIER_HANDLE_AUTO, blender::Vector< T, InlineBufferCapacity, Allocator >::clear(), create_curves_transform_custom_data(), curve_populate_trans_data_structs(), CURVE_TYPE_BEZIER, TransDataContainer::custom, Object::data, TransDataContainer::data, TransInfo::data_container, TransInfo::data_container_len, TransDataContainer::data_len, ELEM, blender::bke::SpanAttributeWriter< T >::finish(), TransInfo::flag, TransCustomData::free_cb, blender::index_mask::IndexMask::from_indices(), blender::index_mask::IndexMask::from_initializers(), blender::index_mask::IndexMask::from_union(), blender::offset_indices::gather_selected_offsets(), Curves::geometry, blender::ed::curves::get_curves_selection_attribute_names(), blender::MutableSpan< T >::index_range(), blender::Span< T >::index_range(), blender::bke::curves::indices_for_type(), CurvesTransformData::memory, TransInfo::mode, TransDataContainer::obedit, blender::bke::Point, CurvesTransformData::positions, blender::ed::curves::retrieve_selected_points(), blender::Array< T, InlineBufferCapacity, Allocator >::size(), blender::Vector< T, InlineBufferCapacity, Allocator >::size(), size(), blender::bke::SpanAttributeWriter< T >::span, T_PROP_CONNECTED, T_PROP_EDIT_ALL, TFM_CURVE_SHRINKFATTEN, TFM_TILT, blender::offset_indices::OffsetIndices< T >::total_size(), and TransCustomDataContainer::type.

◆ fill_map()

static void blender::ed::transform::curves::fill_map ( const CurveType curve_type,
const IndexRange curve_points,
const OffsetIndices< int > position_offsets_in_td,
const int handles_offset,
MutableSpan< int > map )
static

Creates map of indices to tc.data representing the curves. For bezier curves it uses the layout [L0, P0, R0, L1, P1, R1, L2, P2, R2], where [P0, P1, P2], [L0, L1, L2] and [R0, R1, R2] are positions, left handles and right handles respectively. Other curve types just use the positions [P0, P1, ..., Pn] of the control points directly.

Definition at line 267 of file transform_convert_curves.cc.

References CURVE_TYPE_BEZIER, blender::IndexRange::index_range(), blender::threading::parallel_for(), and blender::IndexRange::start().

◆ recalcData_curves()

◆ recent_position_offsets()