|
Blender V4.3
|
#include <attribute_access_intern.hh>
Inherits blender::bke::BuiltinAttributeProvider.
Public Member Functions | |
| BuiltinCustomDataLayerProvider (std::string attribute_name, const AttrDomain domain, const eCustomDataType data_type, const DeletableEnum deletable, const CustomDataAccessInfo custom_data_access, const UpdateOnChange update_on_change, const AttributeValidator validator={}, const GPointer default_value={}) | |
| GAttributeReader | try_get_for_read (const void *owner) const final |
| GAttributeWriter | try_get_for_write (void *owner) const final |
| bool | try_delete (void *owner) const final |
| bool | try_create (void *owner, const AttributeInit &initializer) const final |
| bool | exists (const void *owner) const final |
Public Member Functions inherited from blender::bke::BuiltinAttributeProvider | |
| BuiltinAttributeProvider (std::string name, const AttrDomain domain, const eCustomDataType data_type, const DeletableEnum deletable, AttributeValidator validator={}, const GPointer default_value={}) | |
| StringRefNull | name () const |
| AttrDomain | domain () const |
| eCustomDataType | data_type () const |
| AttributeValidator | validator () const |
Additional Inherited Members | |
Public Types inherited from blender::bke::BuiltinAttributeProvider | |
| enum | DeletableEnum { Deletable , NonDeletable } |
Protected Attributes inherited from blender::bke::BuiltinAttributeProvider | |
| const std::string | name_ |
| const AttrDomain | domain_ |
| const eCustomDataType | data_type_ |
| const DeletableEnum | deletable_ |
| const AttributeValidator | validator_ |
| const GPointer | default_value_ |
This provider is used to provide access to builtin attributes. It supports making internal types available as different types.
It also supports named builtin attributes, and will look up attributes in CustomData by name if the stored type is the same as the attribute type.
Definition at line 173 of file attribute_access_intern.hh.
|
inline |
Definition at line 179 of file attribute_access_intern.hh.
|
finalvirtual |
Implements blender::bke::BuiltinAttributeProvider.
Definition at line 432 of file attribute_access.cc.
References CustomData_has_layer_named(), blender::bke::BuiltinAttributeProvider::data_type_, blender::bke::CustomDataAccessInfo::get_const_custom_data, and blender::bke::BuiltinAttributeProvider::name_.
|
finalvirtual |
Implements blender::bke::BuiltinAttributeProvider.
Definition at line 404 of file attribute_access.cc.
References blender::bke::add_custom_data_layer_from_attribute_init(), blender::bke::AttributeInit::Construct, CustomData_has_layer_named(), blender::bke::BuiltinAttributeProvider::data_type_, blender::bke::BuiltinAttributeProvider::default_value_, blender::bke::CustomDataAccessInfo::get_custom_data, blender::bke::CustomDataAccessInfo::get_element_num, blender::bke::BuiltinAttributeProvider::name_, and blender::bke::AttributeInit::type.
|
finalvirtual |
Implements blender::bke::BuiltinAttributeProvider.
Definition at line 384 of file attribute_access.cc.
References CustomData_free_layer_named(), blender::bke::BuiltinAttributeProvider::Deletable, blender::bke::BuiltinAttributeProvider::deletable_, blender::bke::CustomDataAccessInfo::get_custom_data, blender::bke::CustomDataAccessInfo::get_element_num, and blender::bke::BuiltinAttributeProvider::name_.
|
finalvirtual |
Implements blender::bke::BuiltinAttributeProvider.
Definition at line 330 of file attribute_access.cc.
References blender::bke::custom_data_type_to_cpp_type(), CustomData_get_named_layer_index(), blender::bke::BuiltinAttributeProvider::data_type_, blender::bke::BuiltinAttributeProvider::domain_, blender::GVArray::ForSpan(), blender::bke::CustomDataAccessInfo::get_const_custom_data, blender::bke::CustomDataAccessInfo::get_element_num, CustomData::layers, and blender::bke::BuiltinAttributeProvider::name_.
|
finalvirtual |
Implements blender::bke::BuiltinAttributeProvider.
Definition at line 355 of file attribute_access.cc.
References blender::bke::custom_data_type_to_cpp_type(), CustomData_get_layer_named_for_write(), data, blender::bke::BuiltinAttributeProvider::data_type_, blender::bke::BuiltinAttributeProvider::domain_, blender::GVMutableArray::ForSpan(), blender::bke::CustomDataAccessInfo::get_custom_data, blender::bke::CustomDataAccessInfo::get_element_num, blender::bke::BuiltinAttributeProvider::name_, and update().