27 {
CD_PROP_FLOAT3,
"FLOAT_VECTOR", 0,
"Vector",
"3D vector with floating-point values"},
28 {
CD_PROP_COLOR,
"FLOAT_COLOR", 0,
"Color",
"RGBA color with 32-bit floating-point values"},
33 "RGBA color with 8-bit positive integer values"},
35 {
CD_PROP_BOOL,
"BOOLEAN", 0,
"Boolean",
"True or false"},
36 {
CD_PROP_FLOAT2,
"FLOAT2", 0,
"2D Vector",
"2D vector with floating-point values"},
37 {
CD_PROP_INT8,
"INT8", 0,
"8-Bit Integer",
"Smaller integer with a range from -128 to 127"},
38 {
CD_PROP_INT16_2D,
"INT16_2D", 0,
"2D 16-Bit Integer Vector",
"16-bit signed integer vector"},
39 {
CD_PROP_INT32_2D,
"INT32_2D", 0,
"2D Integer Vector",
"32-bit signed integer vector"},
40 {
CD_PROP_QUATERNION,
"QUATERNION", 0,
"Quaternion",
"Floating point quaternion rotation"},
42 {0,
nullptr, 0,
nullptr,
nullptr},
46 {
CD_PROP_COLOR,
"FLOAT_COLOR", 0,
"Color",
"RGBA color 32-bit floating-point values"},
51 "RGBA color with 8-bit positive integer values"},
52 {0,
nullptr, 0,
nullptr,
nullptr}};
58 {
CD_PROP_FLOAT3,
"FLOAT_VECTOR", 0,
"Vector",
"3D vector with floating-point values"},
59 {
CD_PROP_COLOR,
"FLOAT_COLOR", 0,
"Color",
"RGBA color with 32-bit floating-point values"},
64 "RGBA color with 8-bit positive integer values"},
66 {
CD_PROP_BOOL,
"BOOLEAN", 0,
"Boolean",
"True or false"},
67 {
CD_PROP_FLOAT2,
"FLOAT2", 0,
"2D Vector",
"2D vector with floating-point values"},
68 {
CD_PROP_FLOAT2,
"FLOAT2", 0,
"2D Vector",
"2D vector with floating-point values"},
69 {
CD_PROP_INT16_2D,
"INT16_2D", 0,
"2D 16-Bit Integer Vector",
"16-bit signed integer vector"},
70 {
CD_PROP_INT32_2D,
"INT32_2D", 0,
"2D Integer Vector",
"32-bit signed integer vector"},
71 {
CD_PROP_QUATERNION,
"QUATERNION", 0,
"Quaternion",
"Floating point quaternion rotation"},
73 {0,
nullptr, 0,
nullptr,
nullptr},
79 {int(AttrDomain::Point),
"POINT", 0,
"Point",
"Attribute on point"},
80 {int(AttrDomain::Edge),
"EDGE", 0,
"Edge",
"Attribute on mesh edge"},
81 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
82 {int(AttrDomain::Corner),
"CORNER", 0,
"Face Corner",
"Attribute on mesh face corner"},
85 {int(AttrDomain::Curve),
"CURVE", 0,
"Spline",
"Attribute on spline"},
86 {int(AttrDomain::Instance),
"INSTANCE", 0,
"Instance",
"Attribute on instance"},
87 {int(AttrDomain::Layer),
"LAYER", 0,
"Layer",
"Attribute on Grease Pencil layer"},
88 {0,
nullptr, 0,
nullptr,
nullptr},
92 {int(AttrDomain::Point),
"POINT", 0,
"Point",
"Attribute on point"},
93 {int(AttrDomain::Edge),
"EDGE", 0,
"Edge",
"Attribute on mesh edge"},
94 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
95 {int(AttrDomain::Corner),
"CORNER", 0,
"Face Corner",
"Attribute on mesh face corner"},
96 {0,
nullptr, 0,
nullptr,
nullptr},
100 {int(AttrDomain::Point),
"POINT", 0,
"Point",
"Attribute on point"},
101 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
102 {int(AttrDomain::Corner),
"CORNER", 0,
"Face Corner",
"Attribute on mesh face corner"},
103 {0,
nullptr, 0,
nullptr,
nullptr},
107 {int(AttrDomain::Point),
"POINT", 0,
"Point",
"Attribute on point"},
108 {int(AttrDomain::Edge),
"EDGE", 0,
"Edge",
"Attribute on mesh edge"},
109 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
110 {0,
nullptr, 0,
nullptr,
nullptr},
114 {int(AttrDomain::Point),
"POINT", 0,
"Point",
"Attribute on point"},
115 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
116 {int(AttrDomain::Curve),
"CURVE", 0,
"Spline",
"Attribute on spline"},
117 {0,
nullptr, 0,
nullptr,
nullptr},
121 {int(AttrDomain::Point),
"POINT", 0,
"Point",
"Attribute on point"},
122 {int(AttrDomain::Edge),
"EDGE", 0,
"Edge",
"Attribute on mesh edge"},
123 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
124 {int(AttrDomain::Curve),
"CURVE", 0,
"Spline",
"Attribute on spline"},
125 {0,
nullptr, 0,
nullptr,
nullptr},
129 {int(AttrDomain::Edge),
"EDGE", 0,
"Edge",
"Attribute on mesh edge"},
130 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
131 {0,
nullptr, 0,
nullptr,
nullptr},
135 {int(AttrDomain::Point),
"POINT", 0,
"Point",
"Attribute on point"},
136 {int(AttrDomain::Edge),
"EDGE", 0,
"Edge",
"Attribute on mesh edge"},
137 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
138 {int(AttrDomain::Curve),
"CURVE", 0,
"Spline",
"Attribute on spline"},
139 {int(AttrDomain::Instance),
"INSTANCE", 0,
"Instance",
"Attribute on instance"},
140 {int(AttrDomain::Layer),
"LAYER", 0,
"Layer",
"Attribute on Grease Pencil layer"},
141 {0,
nullptr, 0,
nullptr,
nullptr},
145 {int(AttrDomain::Auto),
"AUTO", 0,
"Auto",
""},
146 {int(AttrDomain::Point),
"POINT", 0,
"Point",
"Attribute on point"},
147 {int(AttrDomain::Edge),
"EDGE", 0,
"Edge",
"Attribute on mesh edge"},
148 {int(AttrDomain::Face),
"FACE", 0,
"Face",
"Attribute on mesh faces"},
149 {int(AttrDomain::Corner),
"CORNER", 0,
"Face Corner",
"Attribute on mesh face corner"},
150 {int(AttrDomain::Curve),
"CURVE", 0,
"Spline",
"Attribute on spline"},
151 {int(AttrDomain::Instance),
"INSTANCE", 0,
"Instance",
"Attribute on instance"},
152 {int(AttrDomain::Layer),
"LAYER", 0,
"Layer",
"Attribute on Grease Pencil layer"},
153 {0,
nullptr, 0,
nullptr,
nullptr},
157 {int(AttrDomain::Point),
"POINT", 0,
"Vertex",
""},
158 {int(AttrDomain::Corner),
"CORNER", 0,
"Face Corner",
""},
159 {0,
nullptr, 0,
nullptr,
nullptr}};
162 {int(AttrDomain::Point),
"POINT", 0,
"Control Point",
""},
163 {int(AttrDomain::Curve),
"CURVE", 0,
"Curve",
""},
164 {0,
nullptr, 0,
nullptr,
nullptr}};
168# include <fmt/format.h>
191 ID *owner_id =
ptr->owner_id;
200 if (&layers_data->
layers[
i] == layer) {
210 if (&curve_data->
layers[
i] == layer) {
216 if (&point_data->
layers[
i] == layer) {
230 if (
ptr->type == &RNA_GreasePencilDrawing) {
236static std::optional<std::string> rna_Attribute_path(
const PointerRNA *
ptr)
239 char layer_name_esc[
sizeof(layer->
name) * 2];
241 return fmt::format(
"attributes[\"{}\"]", layer_name_esc);
248 return &RNA_FloatAttribute;
250 return &RNA_IntAttribute;
252 return &RNA_FloatVectorAttribute;
254 return &RNA_FloatColorAttribute;
256 return &RNA_ByteColorAttribute;
258 return &RNA_StringAttribute;
260 return &RNA_BoolAttribute;
262 return &RNA_Float2Attribute;
264 return &RNA_ByteIntAttribute;
266 return &RNA_Short2Attribute;
268 return &RNA_Int2Attribute;
270 return &RNA_QuaternionAttribute;
272 return &RNA_Float4x4Attribute;
284static void rna_Attribute_name_set(
PointerRNA *
ptr,
const char *value)
291static int rna_Attribute_name_editable(
const PointerRNA *
ptr,
const char **r_info)
296 *r_info =
N_(
"Cannot modify name of required geometry attribute");
310 bool include_instances,
318 int(AttrDomain::Point),
"POINT", 0,
N_(
"Vertex"),
N_(
"Attribute per point/vertex")};
324 !
ELEM(domain_item->
value,
int(AttrDomain::Point)))
329 !
ELEM(domain_item->
value,
int(AttrDomain::Point),
int(AttrDomain::Curve)))
334 int(AttrDomain::Point),
335 int(AttrDomain::Edge),
336 int(AttrDomain::Face),
337 int(AttrDomain::Corner)))
342 !
ELEM(domain_item->
value,
int(AttrDomain::Layer)))
346 if (!include_instances && domain_item->
value ==
int(AttrDomain::Instance)) {
415 ID *
id =
ptr->owner_id;
426static void rna_ByteColorAttributeValue_color_get(
PointerRNA *
ptr,
float *values)
432static void rna_ByteColorAttributeValue_color_set(
PointerRNA *
ptr,
const float *values)
438static void rna_ByteColorAttributeValue_color_srgb_get(
PointerRNA *
ptr,
float *values)
441 values[0] =
col->r / 255.0f;
442 values[1] =
col->g / 255.0f;
443 values[2] =
col->b / 255.0f;
444 values[3] =
col->a / 255.0f;
447static void rna_ByteColorAttributeValue_color_srgb_set(
PointerRNA *
ptr,
const float *values)
456static void rna_FloatColorAttributeValue_color_srgb_get(
PointerRNA *
ptr,
float *values)
462static void rna_FloatColorAttributeValue_color_srgb_set(
PointerRNA *
ptr,
const float *values)
470static void rna_StringAttributeValue_s_get(
PointerRNA *
ptr,
char *value)
473 const int len = std::min<int>(mstring->
s_len,
sizeof(mstring->
s) - 1);
474 memcpy(value, mstring->
s,
len);
482 const int len = std::min<int>(mstring->
s_len,
sizeof(mstring->
s) - 1);
486static void rna_StringAttributeValue_s_set(
PointerRNA *
ptr,
const char *value)
493 memcpy(mstring->
s, value, mstring->
s_len);
531 attribute_ptr->invalidate();
549 const AttributeOwner owner = owner_from_attribute_pointer_rna(&attribute_pointer);
572 if (customdata ==
nullptr) {
577 }
while (!iter->
valid);
584 rna_AttributeGroup_next_domain(owner, iter,
ptr, rna_Attributes_layer_skip);
593 rna_AttributeGroup_next_domain(owner, iter, &iter->
parent, rna_Attributes_layer_skip);
602 if (type ==
nullptr) {
612 rna_AttributeGroup_next_domain(owner, iter,
ptr, rna_Attributes_noncolor_layer_skip);
621 rna_AttributeGroup_next_domain(owner, iter, &iter->
parent, rna_Attributes_noncolor_layer_skip);
630 if (type ==
nullptr) {
661 if (
STREQ(key,
".uv_seam")) {
674static int rna_AttributeGroupID_active_index_get(
PointerRNA *
ptr)
706static void rna_AttributeGroupID_active_index_set(
PointerRNA *
ptr,
int value)
712static void rna_AttributeGroupID_active_index_range(
725 rna_Attribute_update_data(bmain, scene,
ptr);
728static void rna_AttributeGroup_update_active_color(
Main * ,
732 ID *
id =
ptr->owner_id;
741static int rna_AttributeGroupID_domain_size(
ID *
id,
const int domain)
757 return attribute_ptr;
760static void rna_AttributeGroupMesh_active_color_set(
PointerRNA *
ptr,
764 ID *
id =
ptr->owner_id;
774static int rna_AttributeGroupMesh_active_color_index_get(
PointerRNA *
ptr)
786static void rna_AttributeGroupMesh_active_color_index_set(
PointerRNA *
ptr,
int value)
793 fprintf(stderr,
"%s: error setting active color index to %d\n", __func__, value);
800static void rna_AttributeGroupMesh_active_color_index_range(
811static int rna_AttributeGroupMesh_render_color_index_get(
PointerRNA *
ptr)
820static void rna_AttributeGroupMesh_render_color_index_set(
PointerRNA *
ptr,
int value)
827 fprintf(stderr,
"%s: error setting render color index to %d\n", __func__, value);
834static void rna_AttributeGroupMesh_render_color_index_range(
845static void rna_AttributeGroupMesh_default_color_name_get(
PointerRNA *
ptr,
char *value)
847 const ID *
id =
ptr->owner_id;
852static int rna_AttributeGroupMesh_default_color_name_length(
PointerRNA *
ptr)
854 const ID *
id =
ptr->owner_id;
859static void rna_AttributeGroupMesh_default_color_name_set(
PointerRNA *
ptr,
const char *value)
861 ID *
id =
ptr->owner_id;
871static void rna_AttributeGroupMesh_active_color_name_get(
PointerRNA *
ptr,
char *value)
873 const ID *
id =
ptr->owner_id;
878static int rna_AttributeGroupMesh_active_color_name_length(
PointerRNA *
ptr)
880 const ID *
id =
ptr->owner_id;
885static void rna_AttributeGroupMesh_active_color_name_set(
PointerRNA *
ptr,
const char *value)
887 ID *
id =
ptr->owner_id;
897static PointerRNA rna_AttributeGroupGreasePencilDrawing_new(
ID *grease_pencil_id,
919static void rna_AttributeGroupGreasePencilDrawing_remove(
ID *grease_pencil_id,
946static void rna_AttributeGroupGreasePencilDrawing_active_set(
PointerRNA *
ptr,
961static bool rna_AttributeGroupGreasePencilDrawing_active_poll(
PointerRNA *
ptr,
969static int rna_AttributeGroupGreasePencilDrawing_active_index_get(
PointerRNA *
ptr)
976static void rna_AttributeGroupGreasePencilDrawing_active_index_set(
PointerRNA *
ptr,
int value)
983static void rna_AttributeGroupGreasePencilDrawing_active_index_range(
1012 srna,
"Float Attribute",
"Geometry attribute that stores floating-point values");
1018 "rna_Attribute_data_begin",
1019 "rna_iterator_array_next",
1020 "rna_iterator_array_end",
1021 "rna_iterator_array_get",
1022 "rna_Attribute_data_length",
1031 srna,
"Float Attribute Value",
"Floating-point value in geometry attribute");
1043 srna =
RNA_def_struct(brna,
"FloatVectorAttribute",
"Attribute");
1046 srna,
"Float Vector Attribute",
"Geometry attribute that stores floating-point 3D vectors");
1052 "rna_Attribute_data_begin",
1053 "rna_iterator_array_next",
1054 "rna_iterator_array_end",
1055 "rna_iterator_array_get",
1056 "rna_Attribute_data_length",
1063 srna =
RNA_def_struct(brna,
"FloatVectorAttributeValue",
nullptr);
1066 srna,
"Float Vector Attribute Value",
"Vector value in geometry attribute");
1084 "Float Color Attribute",
1085 "Geometry attribute that stores RGBA colors as floating-point values "
1086 "using 32-bits per channel");
1092 "rna_Attribute_data_begin",
1093 "rna_iterator_array_next",
1094 "rna_iterator_array_end",
1095 "rna_iterator_array_get",
1096 "rna_Attribute_data_length",
1103 srna =
RNA_def_struct(brna,
"FloatColorAttributeValue",
nullptr);
1118 "rna_FloatColorAttributeValue_color_srgb_get",
1119 "rna_FloatColorAttributeValue_color_srgb_set",
1133 "Byte Color Attribute",
1134 "Geometry attribute that stores RGBA colors as positive integer values "
1135 "using 8-bits per channel");
1141 "rna_Attribute_data_begin",
1142 "rna_iterator_array_next",
1143 "rna_iterator_array_end",
1144 "rna_iterator_array_get",
1145 "rna_Attribute_data_length",
1160 "rna_ByteColorAttributeValue_color_get",
1161 "rna_ByteColorAttributeValue_color_set",
1170 "rna_ByteColorAttributeValue_color_srgb_get",
1171 "rna_ByteColorAttributeValue_color_srgb_set",
1185 srna,
"Integer Attribute",
"Geometry attribute that stores integer values");
1191 "rna_Attribute_data_begin",
1192 "rna_iterator_array_next",
1193 "rna_iterator_array_end",
1194 "rna_iterator_array_get",
1195 "rna_Attribute_data_length",
1222 "rna_Attribute_data_begin",
1223 "rna_iterator_array_next",
1224 "rna_iterator_array_end",
1225 "rna_iterator_array_get",
1226 "rna_Attribute_data_length",
1238 "rna_StringAttributeValue_s_get",
1239 "rna_StringAttributeValue_s_length",
1240 "rna_StringAttributeValue_s_set");
1257 "rna_Attribute_data_begin",
1258 "rna_iterator_array_next",
1259 "rna_iterator_array_end",
1260 "rna_iterator_array_get",
1261 "rna_Attribute_data_length",
1282 srna,
"8-bit Integer Attribute",
"Geometry attribute that stores 8-bit integers");
1288 "rna_Attribute_data_begin",
1289 "rna_iterator_array_next",
1290 "rna_iterator_array_end",
1291 "rna_iterator_array_get",
1292 "rna_Attribute_data_length",
1301 srna,
"8-bit Integer Attribute Value",
"8-bit value in geometry attribute");
1314 "2D 16-Bit Integer Vector Attribute",
1315 "Geometry attribute that stores 2D integer vectors");
1321 "rna_Attribute_data_begin",
1322 "rna_iterator_array_next",
1323 "rna_iterator_array_end",
1324 "rna_iterator_array_get",
1325 "rna_Attribute_data_length",
1334 srna,
"2D 16-Bit Integer Vector Attribute Value",
"2D value in geometry attribute");
1351 srna,
"2D Integer Vector Attribute",
"Geometry attribute that stores 2D integer vectors");
1357 "rna_Attribute_data_begin",
1358 "rna_iterator_array_next",
1359 "rna_iterator_array_end",
1360 "rna_iterator_array_get",
1361 "rna_Attribute_data_length",
1370 srna,
"2D Integer Vector Attribute Value",
"2D value in geometry attribute");
1392 "rna_Attribute_data_begin",
1393 "rna_iterator_array_next",
1394 "rna_iterator_array_end",
1395 "rna_iterator_array_get",
1396 "rna_Attribute_data_length",
1402 srna =
RNA_def_struct(brna,
"QuaternionAttributeValue",
nullptr);
1405 srna,
"Quaternion Attribute Value",
"Rotation value in geometry attribute");
1422 srna,
"4x4 Matrix Attribute",
"Geometry attribute that stores a 4 by 4 float matrix");
1428 "rna_Attribute_data_begin",
1429 "rna_iterator_array_next",
1430 "rna_iterator_array_end",
1431 "rna_iterator_array_get",
1432 "rna_Attribute_data_length",
1458 srna,
"Float2 Attribute",
"Geometry attribute that stores floating-point 2D vectors");
1464 "rna_Attribute_data_begin",
1465 "rna_iterator_array_next",
1466 "rna_iterator_array_end",
1467 "rna_iterator_array_get",
1468 "rna_Attribute_data_length",
1513 prop,
"rna_Attribute_domain_get",
nullptr,
"rna_Attribute_domain_itemf");
1520 prop,
"Is Internal",
"The attribute is meant for internal use by Blender");
1554 parm =
RNA_def_string(func,
"name",
"Attribute", 0,
"Name",
"Name of geometry attribute");
1564 int(AttrDomain::Point),
1566 "Type of element that attribute is stored on");
1569 parm =
RNA_def_pointer(func,
"attribute",
"Attribute",
"",
"New geometry attribute");
1576 parm =
RNA_def_pointer(func,
"attribute",
"Attribute",
"",
"Geometry Attribute");
1585 "rna_AttributeGroupID_active_get",
1586 "rna_AttributeGroupID_active_set",
1594 prop,
"Active Attribute Index",
"Active attribute index or -1 when none are active");
1598 "rna_AttributeGroupID_active_index_get",
1599 "rna_AttributeGroupID_active_index_set",
1600 "rna_AttributeGroupID_active_index_range");
1604 func =
RNA_def_function(srna,
"domain_size",
"rna_AttributeGroupID_domain_size");
1609 int(AttrDomain::Point),
1611 "Type of element that attribute is stored on");
1613 parm =
RNA_def_int(func,
"size", 0, 0, INT_MAX,
"Size",
"Size of the domain", 0, INT_MAX);
1634 "rna_AttributeGroupMesh_active_color_get",
1635 "rna_AttributeGroupMesh_active_color_set",
1645 "rna_AttributeGroupMesh_active_color_index_get",
1646 "rna_AttributeGroupMesh_active_color_index_set",
1647 "rna_AttributeGroupMesh_active_color_index_range");
1652 "Active Render Color Index",
1653 "The index of the color attribute used as a fallback for rendering");
1656 "rna_AttributeGroupMesh_render_color_index_get",
1657 "rna_AttributeGroupMesh_render_color_index_set",
1658 "rna_AttributeGroupMesh_render_color_index_range");
1664 "rna_AttributeGroupMesh_default_color_name_get",
1665 "rna_AttributeGroupMesh_default_color_name_length",
1666 "rna_AttributeGroupMesh_default_color_name_set");
1669 "Default Color Attribute",
1670 "The name of the default color attribute used as a fallback for rendering");
1675 "rna_AttributeGroupMesh_active_color_name_get",
1676 "rna_AttributeGroupMesh_active_color_name_length",
1677 "rna_AttributeGroupMesh_active_color_name_set");
1679 "Active Color Attribute",
1680 "The name of the active color attribute for display and editing");
1687 srna =
RNA_def_struct(brna,
"AttributeGroupPointCloud",
nullptr);
1709 srna =
RNA_def_struct(brna,
"AttributeGroupGreasePencil",
nullptr);
1723 srna =
RNA_def_struct(brna,
"AttributeGroupGreasePencilDrawing",
nullptr);
1728 func =
RNA_def_function(srna,
"new",
"rna_AttributeGroupGreasePencilDrawing_new");
1731 parm =
RNA_def_string(func,
"name",
"Attribute", 0,
"Name",
"Name of geometry attribute");
1741 int(AttrDomain::Point),
1743 "Type of element that attribute is stored on");
1746 parm =
RNA_def_pointer(func,
"attribute",
"Attribute",
"",
"New geometry attribute");
1750 func =
RNA_def_function(srna,
"remove",
"rna_AttributeGroupGreasePencilDrawing_remove");
1753 parm =
RNA_def_pointer(func,
"attribute",
"Attribute",
"",
"Geometry Attribute");
1762 "rna_AttributeGroupGreasePencilDrawing_active_get",
1763 "rna_AttributeGroupGreasePencilDrawing_active_set",
1765 "rna_AttributeGroupGreasePencilDrawing_active_poll");
1771 prop,
"Active Attribute Index",
"Active attribute index or -1 when none are active");
1775 "rna_AttributeGroupGreasePencilDrawing_active_index_get",
1776 "rna_AttributeGroupGreasePencilDrawing_active_index_set",
1777 "rna_AttributeGroupGreasePencilDrawing_active_index_range");
1782 srna,
"domain_size",
"rna_AttributeGroupGreasePencilDrawing_domain_size");
1787 int(AttrDomain::Point),
1789 "Type of element that attribute is stored on");
1791 parm =
RNA_def_int(func,
"size", 0, 0, INT_MAX,
"Size",
"Size of the domain", 0, INT_MAX);
1802 "rna_AttributeGroup_iterator_begin",
1803 "rna_AttributeGroup_iterator_next",
1804 "rna_iterator_array_end",
1805 "rna_AttributeGroup_iterator_get",
1806 "rna_AttributeGroup_length",
1808 "rna_AttributeGroup_lookup_string",
1832 "rna_AttributeGroup_color_iterator_begin",
1833 "rna_AttributeGroup_color_iterator_next",
1834 "rna_iterator_array_end",
1835 "rna_AttributeGroup_color_iterator_get",
1836 "rna_AttributeGroup_color_length",
void BKE_id_attributes_default_color_set(struct ID *id, std::optional< blender::StringRef > name)
struct CustomDataLayer * BKE_attribute_new(AttributeOwner &owner, blender::StringRef name, eCustomDataType type, blender::bke::AttrDomain domain, struct ReportList *reports)
std::optional< blender::StringRefNull > BKE_attributes_active_name_get(AttributeOwner &owner)
int BKE_attribute_to_index(const AttributeOwner &owner, const CustomDataLayer *layer, AttrDomainMask domain_mask, eCustomDataMask layer_mask)
struct CustomDataLayer * BKE_attribute_search_for_write(AttributeOwner &owner, blender::StringRef name, eCustomDataMask type, AttrDomainMask domain_mask)
blender::bke::AttrDomain BKE_attribute_domain(const AttributeOwner &owner, const struct CustomDataLayer *layer)
CustomData * BKE_attributes_iterator_next_domain(AttributeOwner &owner, struct CustomDataLayer *layers)
int BKE_attribute_domain_size(const AttributeOwner &owner, int domain)
std::optional< blender::StringRef > BKE_id_attributes_default_color_name(const struct ID *id)
CustomDataLayer * BKE_attribute_from_index(AttributeOwner &owner, int lookup_index, AttrDomainMask domain_mask, eCustomDataMask layer_mask)
bool BKE_attribute_remove(AttributeOwner &owner, blender::StringRef name, struct ReportList *reports)
void BKE_attributes_active_set(AttributeOwner &owner, blender::StringRef name)
const struct CustomDataLayer * BKE_attribute_search(const AttributeOwner &owner, blender::StringRef name, eCustomDataMask type, AttrDomainMask domain_mask)
const struct CustomDataLayer * BKE_id_attributes_color_find(const struct ID *id, blender::StringRef name)
int * BKE_attributes_active_index_p(AttributeOwner &owner)
void BKE_id_attributes_active_color_clear(struct ID *id)
bool BKE_attribute_required(const AttributeOwner &owner, blender::StringRef name)
int BKE_attribute_data_length(AttributeOwner &owner, struct CustomDataLayer *layer)
std::optional< blender::StringRef > BKE_id_attributes_active_color_name(const struct ID *id)
#define ATTR_DOMAIN_MASK_COLOR
#define ATTR_DOMAIN_AS_MASK(domain)
bool BKE_attribute_rename(AttributeOwner &owner, blender::StringRef old_name, blender::StringRef new_name, struct ReportList *reports)
int BKE_attributes_length(const AttributeOwner &owner, AttrDomainMask domain_mask, eCustomDataMask mask)
void BKE_id_attributes_active_color_set(struct ID *id, std::optional< blender::StringRef > name)
void BKE_attributes_active_clear(AttributeOwner &owner)
CustomData interface, see also DNA_customdata_types.h.
void CustomData_ensure_data_is_mutable(CustomDataLayer *layer, int totelem)
size_t CustomData_get_elem_size(const CustomDataLayer *layer)
#define CD_TYPE_AS_MASK(_type)
MINLINE unsigned char round_fl_to_uchar_clamp(float a)
MINLINE void srgb_to_linearrgb_uchar4(float linear[4], const unsigned char srgb[4])
MINLINE void srgb_to_linearrgb_v4(float linear[4], const float srgb[4])
MINLINE void linearrgb_to_srgb_uchar4(unsigned char srgb[4], const float linear[4])
MINLINE void linearrgb_to_srgb_v4(float srgb[4], const float linear[4])
char * BLI_strdup(const char *str) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1) ATTR_MALLOC
int char char int int int int size_t BLI_strnlen(const char *str, size_t maxlen) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1)
size_t BLI_str_escape(char *__restrict dst, const char *__restrict src, size_t dst_maxncpy) ATTR_NONNULL(1
void DEG_id_tag_update(ID *id, unsigned int flags)
const EnumPropertyItem * rna_enum_attribute_domain_itemf(const AttributeOwner &owner, bool include_instances, bool *r_free)
BMesh const char void * data
AttributeOwnerType type() const
static AttributeOwner from_id(ID *id)
GreasePencilDrawing * get_grease_pencil_drawing() const
void copy_unsafe(char *dst) const
constexpr int64_t size() const
float length(VecOp< float, D >) RET
#define CD_MASK_COLOR_ALL
#define MAX_CUSTOMDATA_LAYER_NAME_NO_PREFIX
bool allow_procedural_attribute_access(StringRef attribute_name)
uint32_t struct_size(Span< shader::ShaderCreateInfo::PushConst > push_constants)
void rna_iterator_array_begin(CollectionPropertyIterator *iter, PointerRNA *ptr, void *data, int itemsize, int length, bool free_ptr, IteratorSkipFunc skip)
const PointerRNA PointerRNA_NULL
void * rna_iterator_array_get(CollectionPropertyIterator *iter)
void rna_iterator_array_next(CollectionPropertyIterator *iter)
void rna_pointer_create_with_ancestors(const PointerRNA &parent, StructRNA *type, void *data, PointerRNA &r_ptr)
PointerRNA RNA_pointer_create_discrete(ID *id, StructRNA *type, void *data)
PointerRNA RNA_pointer_create_with_parent(const PointerRNA &parent, StructRNA *type, void *data)
static void rna_def_attribute_float4x4(BlenderRNA *brna)
static void rna_def_attribute_group_id_common(StructRNA *srna)
const EnumPropertyItem rna_enum_attribute_domain_only_mesh_items[]
static void rna_def_attribute_short2(BlenderRNA *brna)
static void rna_def_attribute_int8(BlenderRNA *brna)
const EnumPropertyItem rna_enum_color_attribute_domain_items[]
static void rna_def_attribute_bool(BlenderRNA *brna)
static void rna_def_attribute(BlenderRNA *brna)
const EnumPropertyItem rna_enum_attribute_domain_with_auto_items[]
static void rna_def_attribute_quaternion(BlenderRNA *brna)
static void rna_def_attribute_group_grease_pencil(BlenderRNA *brna)
static void rna_def_attribute_group_mesh(BlenderRNA *brna)
const EnumPropertyItem rna_enum_attribute_domain_only_mesh_no_corner_items[]
static void rna_def_attribute_int2(BlenderRNA *brna)
const EnumPropertyItem rna_enum_attribute_domain_point_edge_face_curve_items[]
const EnumPropertyItem rna_enum_attribute_domain_edge_face_items[]
const EnumPropertyItem rna_enum_attribute_curves_domain_items[]
const EnumPropertyItem rna_enum_attribute_domain_point_face_curve_items[]
static void rna_def_attribute_float_vector(BlenderRNA *brna)
static void rna_def_attribute_group_grease_pencil_drawing(BlenderRNA *brna)
const EnumPropertyItem rna_enum_attribute_domain_only_mesh_no_edge_items[]
static void rna_def_attribute_float_color(BlenderRNA *brna)
static void rna_def_attribute_float(BlenderRNA *brna)
const EnumPropertyItem rna_enum_attribute_domain_items[]
static void rna_def_attribute_int(BlenderRNA *brna)
static void rna_def_attribute_byte_color(BlenderRNA *brna)
void RNA_def_attribute(BlenderRNA *brna)
static void rna_def_attribute_float2(BlenderRNA *brna)
void rna_def_attributes_common(StructRNA *srna, const AttributeOwnerType type)
const EnumPropertyItem rna_enum_attribute_domain_without_corner_items[]
static void rna_def_attribute_group_pointcloud(BlenderRNA *brna)
const EnumPropertyItem rna_enum_attribute_type_items[]
static void rna_def_attribute_group_curves(BlenderRNA *brna)
const EnumPropertyItem rna_enum_attribute_type_with_auto_items[]
const EnumPropertyItem rna_enum_color_attribute_type_items[]
static void rna_def_attribute_string(BlenderRNA *brna)
void RNA_def_property_boolean_sdna(PropertyRNA *prop, const char *structname, const char *propname, int64_t booleanbit)
void RNA_def_struct_name_property(StructRNA *srna, PropertyRNA *prop)
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
void RNA_def_struct_refine_func(StructRNA *srna, const char *refine)
void RNA_def_struct_path_func(StructRNA *srna, const char *path)
void RNA_def_parameter_clear_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
void RNA_def_property_string_funcs(PropertyRNA *prop, const char *get, const char *length, const char *set)
void RNA_def_function_return(FunctionRNA *func, PropertyRNA *ret)
void RNA_def_property_float_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
void RNA_def_property_ui_text(PropertyRNA *prop, const char *name, const char *description)
void RNA_def_property_string_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_srna(PropertyRNA *prop, const char *type)
void RNA_def_property_collection_funcs(PropertyRNA *prop, const char *begin, const char *next, const char *end, const char *get, const char *length, const char *lookupint, const char *lookupstring, const char *assignint)
void RNA_def_struct_ui_text(StructRNA *srna, const char *name, const char *description)
void RNA_def_property_boolean_funcs(PropertyRNA *prop, const char *get, const char *set)
void RNA_def_property_multi_array(PropertyRNA *prop, int dimension, const int length[])
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, const int default_value, const char *ui_name, const char *ui_description)
void RNA_def_property_enum_items(PropertyRNA *prop, const EnumPropertyItem *item)
void RNA_def_struct_sdna(StructRNA *srna, const char *structname)
FunctionRNA * RNA_def_function(StructRNA *srna, const char *identifier, const char *call)
void RNA_def_property_array(PropertyRNA *prop, int length)
void RNA_def_property_range(PropertyRNA *prop, double min, double max)
PropertyRNA * RNA_def_pointer(StructOrFunctionRNA *cont_, const char *identifier, const char *type, const char *ui_name, const char *ui_description)
void RNA_def_property_string_maxlength(PropertyRNA *prop, int maxlength)
void RNA_def_property_struct_type(PropertyRNA *prop, const char *type)
void RNA_def_function_ui_description(FunctionRNA *func, const char *description)
void RNA_def_property_update(PropertyRNA *prop, int noteflag, const char *func)
const int rna_matrix_dimsize_4x4[]
PropertyRNA * RNA_def_property(StructOrFunctionRNA *cont_, const char *identifier, int type, int subtype)
void RNA_def_property_enum_funcs(PropertyRNA *prop, const char *get, const char *set, const char *item)
void RNA_def_property_editable_func(PropertyRNA *prop, const char *editable)
StructRNA * RNA_def_struct(BlenderRNA *brna, const char *identifier, const char *from)
void RNA_enum_item_end(EnumPropertyItem **items, int *totitem)
void RNA_def_function_flag(FunctionRNA *func, int flag)
void RNA_def_property_clear_flag(PropertyRNA *prop, PropertyFlag flag)
void RNA_def_property_pointer_funcs(PropertyRNA *prop, const char *get, const char *set, const char *type_fn, const char *poll)
void RNA_def_property_enum_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_enum_item_add(EnumPropertyItem **items, int *totitem, const EnumPropertyItem *item)
void RNA_def_property_int_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
void RNA_def_property_float_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_int_sdna(PropertyRNA *prop, const char *structname, const char *propname)
PropertyRNA * RNA_def_int(StructOrFunctionRNA *cont_, const char *identifier, const int default_value, const int hardmin, const int hardmax, const char *ui_name, const char *ui_description, const int softmin, const int softmax)
void RNA_def_property_override_flag(PropertyRNA *prop, PropertyOverrideFlag flag)
void RNA_def_parameter_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
void rna_AttributeGroup_iterator_next(CollectionPropertyIterator *iter)
void rna_AttributeGroup_color_iterator_next(CollectionPropertyIterator *iter)
int rna_AttributeGroup_length(PointerRNA *ptr)
int rna_AttributeGroup_color_length(PointerRNA *ptr)
bool rna_AttributeGroup_lookup_string(PointerRNA *ptr, const char *key, PointerRNA *r_ptr)
PointerRNA rna_AttributeGroup_color_iterator_get(CollectionPropertyIterator *iter)
void rna_AttributeGroup_iterator_begin(CollectionPropertyIterator *iter, PointerRNA *ptr)
void rna_AttributeGroup_color_iterator_begin(CollectionPropertyIterator *iter, PointerRNA *ptr)
PointerRNA rna_AttributeGroup_iterator_get(CollectionPropertyIterator *iter)
union CollectionPropertyIterator::@277172262001176145116102322066145204253046376362 internal
char * default_color_attribute
char * active_color_attribute
void WM_main_add_notifier(uint type, void *reference)