56 pointcloud->attributes_for_write().remove(
".selection");
61 pointcloud->attributes_for_write().lookup_or_add_for_write_span<
bool>(
63 selection_attr.
span.take_back(selection.
size()).fill(
true);
74 ot->
name =
"Duplicate";
75 ot->
idname =
"POINTCLOUD_OT_duplicate";
General operations for point clouds.
GMutableSpan take_front(const int64_t n) const
GMutableSpan take_back(const int64_t n) const
CommonVArrayInfo common_info() const
const CPPType & type() const
GAttributeReader get() const
bool add(const StringRef name, const AttrDomain domain, const AttrType data_type, const AttributeInit &initializer)
GSpanAttributeWriter lookup_or_add_for_write_only_span(StringRef name, AttrDomain domain, AttrType data_type)
void gather(const GVArray &src, const IndexMask &indices, GMutableSpan dst, exec_mode::Mode mode=exec_mode::parallel)
void copy(const GVArray &src, GMutableSpan dst, exec_mode::Mode mode=exec_mode::parallel)
bool editable_pointcloud_in_edit_mode_poll(bContext *C)
static wmOperatorStatus duplicate_exec(bContext *C, wmOperator *)
void POINTCLOUD_OT_duplicate(wmOperatorType *ot)
static void duplicate_points(PointCloud &pointcloud, const IndexMask &mask)
IndexMask retrieve_selected_points(const PointCloud &pointcloud, IndexMaskMemory &memory)
VectorSet< PointCloud * > get_unique_editable_pointclouds(const bContext &C)
void BKE_pointcloud_nomain_to_pointcloud(PointCloud *pointcloud_src, PointCloud *pointcloud_dst)
void DEG_id_tag_update(ID *id, unsigned int flags)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
PointCloud * BKE_pointcloud_new_nomain(PointCloudType type, int totpoint)
MutableVArraySpan< T > span
wmOperatorStatus(*) exec(bContext *C, wmOperator *op) ATTR_WARN_UNUSED_RESULT
bool(*) poll(bContext *C) ATTR_WARN_UNUSED_RESULT