diff options
Diffstat (limited to 'source/blender/makesrna')
-rw-r--r-- | source/blender/makesrna/intern/rna_attribute.c | 10 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_mesh.c | 16 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_modifier.c | 4 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_particle.c | 2 |
4 files changed, 16 insertions, 16 deletions
diff --git a/source/blender/makesrna/intern/rna_attribute.c b/source/blender/makesrna/intern/rna_attribute.c index b11250cf891..6f3688b66f5 100644 --- a/source/blender/makesrna/intern/rna_attribute.c +++ b/source/blender/makesrna/intern/rna_attribute.c @@ -28,7 +28,7 @@ const EnumPropertyItem rna_enum_attribute_type_items[] = { {CD_PROP_INT32, "INT", 0, "Integer", "32-bit integer"}, {CD_PROP_FLOAT3, "FLOAT_VECTOR", 0, "Vector", "3D vector with floating-point values"}, {CD_PROP_COLOR, "FLOAT_COLOR", 0, "Color", "RGBA color with floating-point values"}, - {CD_MLOOPCOL, "BYTE_COLOR", 0, "Byte Color", "RGBA color with 8-bit values"}, + {CD_PROP_BYTE_COLOR, "BYTE_COLOR", 0, "Byte Color", "RGBA color with 8-bit values"}, {CD_PROP_STRING, "STRING", 0, "String", "Text string"}, {CD_PROP_BOOL, "BOOLEAN", 0, "Boolean", "True or false"}, {CD_PROP_FLOAT2, "FLOAT2", 0, "2D Vector", "2D vector with floating-point values"}, @@ -42,7 +42,7 @@ const EnumPropertyItem rna_enum_attribute_type_with_auto_items[] = { {CD_PROP_INT32, "INT", 0, "Integer", "32-bit integer"}, {CD_PROP_FLOAT3, "FLOAT_VECTOR", 0, "Vector", "3D vector with floating-point values"}, {CD_PROP_COLOR, "FLOAT_COLOR", 0, "Color", "RGBA color with floating-point values"}, - {CD_MLOOPCOL, "BYTE_COLOR", 0, "Byte Color", "RGBA color with 8-bit values"}, + {CD_PROP_BYTE_COLOR, "BYTE_COLOR", 0, "Byte Color", "RGBA color with 8-bit values"}, {CD_PROP_STRING, "STRING", 0, "String", "Text string"}, {CD_PROP_BOOL, "BOOLEAN", 0, "Boolean", "True or false"}, {CD_PROP_FLOAT2, "FLOAT2", 0, "2D Vector", "2D vector with floating-point values"}, @@ -113,7 +113,7 @@ static StructRNA *srna_by_custom_data_layer_type(const CustomDataType type) return &RNA_FloatVectorAttribute; case CD_PROP_COLOR: return &RNA_FloatColorAttribute; - case CD_MLOOPCOL: + case CD_PROP_BYTE_COLOR: return &RNA_ByteColorAttribute; case CD_PROP_STRING: return &RNA_StringAttribute; @@ -231,7 +231,7 @@ static void rna_Attribute_data_begin(CollectionPropertyIterator *iter, PointerRN case CD_PROP_COLOR: struct_size = sizeof(MPropCol); break; - case CD_MLOOPCOL: + case CD_PROP_BYTE_COLOR: struct_size = sizeof(MLoopCol); break; case CD_PROP_STRING: @@ -423,7 +423,7 @@ int rna_AttributeGroup_color_length(PointerRNA *ptr) { return BKE_id_attributes_length(ptr->owner_id, ATTR_DOMAIN_MASK_POINT | ATTR_DOMAIN_MASK_CORNER, - CD_MASK_PROP_COLOR | CD_MASK_MLOOPCOL); + CD_MASK_PROP_COLOR | CD_MASK_PROP_BYTE_COLOR); } int rna_AttributeGroup_length(PointerRNA *ptr) diff --git a/source/blender/makesrna/intern/rna_mesh.c b/source/blender/makesrna/intern/rna_mesh.c index 7e2b6d9c8ef..0e7c332f6a4 100644 --- a/source/blender/makesrna/intern/rna_mesh.c +++ b/source/blender/makesrna/intern/rna_mesh.c @@ -753,9 +753,9 @@ static void rna_MeshUVLoopLayer_clone_set(PointerRNA *ptr, bool value) /* vertex_color_layers */ -DEFINE_CUSTOMDATA_LAYER_COLLECTION(vertex_color, ldata, CD_MLOOPCOL) +DEFINE_CUSTOMDATA_LAYER_COLLECTION(vertex_color, ldata, CD_PROP_BYTE_COLOR) DEFINE_CUSTOMDATA_LAYER_COLLECTION_ACTIVEITEM( - vertex_color, ldata, CD_MLOOPCOL, active, MeshLoopColorLayer) + vertex_color, ldata, CD_PROP_BYTE_COLOR, active, MeshLoopColorLayer) static void rna_MeshLoopColorLayer_data_begin(CollectionPropertyIterator *iter, PointerRNA *ptr) { @@ -773,22 +773,22 @@ static int rna_MeshLoopColorLayer_data_length(PointerRNA *ptr) static bool rna_MeshLoopColorLayer_active_render_get(PointerRNA *ptr) { - return rna_CustomDataLayer_active_get(ptr, rna_mesh_ldata(ptr), CD_MLOOPCOL, 1); + return rna_CustomDataLayer_active_get(ptr, rna_mesh_ldata(ptr), CD_PROP_BYTE_COLOR, 1); } static bool rna_MeshLoopColorLayer_active_get(PointerRNA *ptr) { - return rna_CustomDataLayer_active_get(ptr, rna_mesh_ldata(ptr), CD_MLOOPCOL, 0); + return rna_CustomDataLayer_active_get(ptr, rna_mesh_ldata(ptr), CD_PROP_BYTE_COLOR, 0); } static void rna_MeshLoopColorLayer_active_render_set(PointerRNA *ptr, bool value) { - rna_CustomDataLayer_active_set(ptr, rna_mesh_ldata(ptr), value, CD_MLOOPCOL, 1); + rna_CustomDataLayer_active_set(ptr, rna_mesh_ldata(ptr), value, CD_PROP_BYTE_COLOR, 1); } static void rna_MeshLoopColorLayer_active_set(PointerRNA *ptr, bool value) { - rna_CustomDataLayer_active_set(ptr, rna_mesh_ldata(ptr), value, CD_MLOOPCOL, 0); + rna_CustomDataLayer_active_set(ptr, rna_mesh_ldata(ptr), value, CD_PROP_BYTE_COLOR, 0); } /* sculpt_vertex_color_layers */ @@ -1340,7 +1340,7 @@ static char *rna_MeshLoopColorLayer_path(PointerRNA *ptr) static char *rna_MeshColor_path(PointerRNA *ptr) { - return rna_LoopCustomData_data_path(ptr, "vertex_colors", CD_MLOOPCOL); + return rna_LoopCustomData_data_path(ptr, "vertex_colors", CD_PROP_BYTE_COLOR); } static char *rna_MeshVertColorLayer_path(PointerRNA *ptr) @@ -1564,7 +1564,7 @@ static PointerRNA rna_Mesh_vertex_color_new(struct Mesh *me, if (index != -1) { ldata = rna_mesh_ldata_helper(me); - cdl = &ldata->layers[CustomData_get_layer_index_n(ldata, CD_MLOOPCOL, index)]; + cdl = &ldata->layers[CustomData_get_layer_index_n(ldata, CD_PROP_BYTE_COLOR, index)]; } RNA_pointer_create(&me->id, &RNA_MeshLoopColorLayer, cdl, &ptr); diff --git a/source/blender/makesrna/intern/rna_modifier.c b/source/blender/makesrna/intern/rna_modifier.c index 16045e6cddf..c2ab4897d60 100644 --- a/source/blender/makesrna/intern/rna_modifier.c +++ b/source/blender/makesrna/intern/rna_modifier.c @@ -1389,7 +1389,7 @@ static const EnumPropertyItem *rna_DataTransferModifier_layers_select_src_itemf( cdata = &me_eval->ldata; } - CustomDataType types[2] = {CD_PROP_COLOR, CD_MLOOPCOL}; + CustomDataType types[2] = {CD_PROP_COLOR, CD_PROP_BYTE_COLOR}; int idx = 0; for (int i = 0; i < 2; i++) { @@ -1485,7 +1485,7 @@ static const EnumPropertyItem *rna_DataTransferModifier_layers_select_dst_itemf( Object *ob_dst = CTX_data_active_object(C); /* XXX Is this OK? */ if (ob_dst && ob_dst->data) { - CustomDataType types[2] = {CD_PROP_COLOR, CD_MLOOPCOL}; + CustomDataType types[2] = {CD_PROP_COLOR, CD_PROP_BYTE_COLOR}; Mesh *me_dst = ob_dst->data; CustomData *cdata = STREQ(RNA_property_identifier(prop), "layers_vcol_vert_select_dst") ? diff --git a/source/blender/makesrna/intern/rna_particle.c b/source/blender/makesrna/intern/rna_particle.c index 03f800d14d1..6f2264680c8 100644 --- a/source/blender/makesrna/intern/rna_particle.c +++ b/source/blender/makesrna/intern/rna_particle.c @@ -676,7 +676,7 @@ static void rna_ParticleSystem_mcol_on_emitter(ParticleSystem *particlesystem, int vcol_no, float r_mcol[3]) { - if (!CustomData_has_layer(&modifier->mesh_final->ldata, CD_MLOOPCOL)) { + if (!CustomData_has_layer(&modifier->mesh_final->ldata, CD_PROP_BYTE_COLOR)) { BKE_report(reports, RPT_ERROR, "Mesh has no VCol data"); zero_v3(r_mcol); return; |