34 if (pointcloud_ !=
nullptr) {
44 if (pointcloud_ !=
nullptr) {
48 pointcloud_ =
nullptr;
54 return pointcloud_ !=
nullptr;
61 pointcloud_ = pointcloud;
62 ownership_ = ownership;
69 pointcloud_ =
nullptr;
90 return pointcloud_ ==
nullptr;
112 pointcloud_->count_memory(memory);
125 points.tag_positions_changed();
131 points.tag_radii_changed();
143 return &pointcloud->
pdata;
147 return &pointcloud->
pdata;
149 [](
const void *owner) ->
int {
182 fn.domain_size = [](
const void *owner,
const AttrDomain domain) {
183 if (owner ==
nullptr) {
194 fn.domain_supported = [](
const void * ,
const AttrDomain domain) {
197 fn.adapt_domain = [](
const void * ,
223blender::bke::MutableAttributeAccessor PointCloud::attributes_for_write()
225 return blender::bke::MutableAttributeAccessor(
229namespace blender::bke {
void BKE_id_free(Main *bmain, void *idv)
General operations for point clouds.
PointCloud * BKE_pointcloud_copy_for_eval(const PointCloud *pointcloud_src)
GeometryComponent(Type type)
GeometryComponentPtr copy() const override
void count_memory(MemoryCounter &memory) const override
bool owns_direct_data() const override
void replace(PointCloud *pointcloud, GeometryOwnershipType ownership=GeometryOwnershipType::Owned)
const PointCloud * get() const
std::optional< MutableAttributeAccessor > attributes_for_write() final
bool is_empty() const final
bool has_pointcloud() const
void ensure_owns_direct_data() override
std::optional< AttributeAccessor > attributes() const final
PointCloud * get_for_write()
AttributeAccessorFunctions accessor_functions_for_providers()
ImplicitSharingPtr< GeometryComponent > GeometryComponentPtr
static ComponentAttributeProviders create_attribute_providers_for_point_cloud()
static void tag_component_positions_changed(void *owner)
static void tag_component_radius_changed(void *owner)
static const AttributeAccessorFunctions & get_pointcloud_accessor_functions_ref()
static AttributeAccessorFunctions get_pointcloud_accessor_functions()