[Bf-blender-cvs] [25c8d72e204] blender-v3.3-release: Fix T100747: Cannot add "String" attribute to mesh

Philipp Oeser noreply at git.blender.org
Tue Sep 6 11:52:51 CEST 2022


Commit: 25c8d72e204b0d216a0cda54b8d66056f02a27b8
Author: Philipp Oeser
Date:   Fri Sep 2 11:58:44 2022 +0200
Branches: blender-v3.3-release
https://developer.blender.org/rB25c8d72e204b0d216a0cda54b8d66056f02a27b8

Fix T100747: Cannot add "String" attribute to mesh

Caused by {rB31365c6b9e4c}.

The new API `CustomDataAttributeProvider` just did not support
`CD_MASK_PROP_STRING`.

While strings dont perform nicely in their current form, still add
support back for the API.

Adding Strings to the supported types seems to survive just
fine, see attached example file.

Maniphest Tasks: T100747

Differential Revision: https://developer.blender.org/D15851

===================================================================

M	source/blender/blenkernel/intern/attribute_access_intern.hh

===================================================================

diff --git a/source/blender/blenkernel/intern/attribute_access_intern.hh b/source/blender/blenkernel/intern/attribute_access_intern.hh
index 1a2607d9403..9b784d02115 100644
--- a/source/blender/blenkernel/intern/attribute_access_intern.hh
+++ b/source/blender/blenkernel/intern/attribute_access_intern.hh
@@ -125,10 +125,7 @@ class DynamicAttributesProvider {
  */
 class CustomDataAttributeProvider final : public DynamicAttributesProvider {
  private:
-  static constexpr uint64_t supported_types_mask = CD_MASK_PROP_FLOAT | CD_MASK_PROP_FLOAT2 |
-                                                   CD_MASK_PROP_FLOAT3 | CD_MASK_PROP_INT32 |
-                                                   CD_MASK_PROP_COLOR | CD_MASK_PROP_BOOL |
-                                                   CD_MASK_PROP_INT8 | CD_MASK_PROP_BYTE_COLOR;
+  static constexpr uint64_t supported_types_mask = CD_MASK_PROP_ALL;
   const eAttrDomain domain_;
   const CustomDataAccessInfo custom_data_access_;



More information about the Bf-blender-cvs mailing list