29 if (grease_pencil_ !=
nullptr) {
39 if (grease_pencil_ !=
nullptr) {
43 grease_pencil_ =
nullptr;
49 return grease_pencil_ !=
nullptr;
56 grease_pencil_ = grease_pencil;
57 ownership_ = ownership;
64 grease_pencil_ =
nullptr;
70 return grease_pencil_;
80 return grease_pencil_;
85 return grease_pencil_ ==
nullptr;
Low-level operations for grease pencil.
GreasePencil * BKE_grease_pencil_copy_for_eval(const GreasePencil *grease_pencil_src)
void BKE_id_free(Main *bmain, void *idv)
GeometryComponent(Type type)
bool has_grease_pencil() const
std::optional< AttributeAccessor > attributes() const final
std::optional< MutableAttributeAccessor > attributes_for_write() final
const GreasePencil * get() const
~GreasePencilComponent() override
bool owns_direct_data() const override
GreasePencil * get_for_write()
GeometryComponentPtr copy() const override
void ensure_owns_direct_data() override
bool is_empty() const final
void replace(GreasePencil *grease_pencil, GeometryOwnershipType ownership=GeometryOwnershipType::Owned)
const AttributeAccessorFunctions & get_attribute_accessor_functions()
ImplicitSharingPtr< GeometryComponent > GeometryComponentPtr