diff options
author | Geoffrey Bantle <hairbat@yahoo.com> | 2007-06-04 23:18:19 +0400 |
---|---|---|
committer | Geoffrey Bantle <hairbat@yahoo.com> | 2007-06-04 23:18:19 +0400 |
commit | ba958bea0f4b49f87644fdf02cbc2ebba826a6b8 (patch) | |
tree | c77b55535bcedafc71b11e279c9c00f5256f7d31 /source/blender/makesdna/DNA_meshdata_types.h | |
parent | d5ee6fc865f16bd3abe1ad7d2fe6aa0be43576a9 (diff) |
-> Custom Properties for Mesh entities
In order to give import/export script authors the ability to add properties
to inidividual faces, vertices and edges in the same manner as they are able
to do with ID structures three new custom data types have been added to blender
for floats, integers and strings.
Things to note:
-Since property Layers are custom data, they are added to all verts, edges
or faces at once.
-Only one property layer for each unique property name may exist. In other
words, you cannot have a float layer as well as an integer layer
both with the same name.
-No user interface for this exists at the moment.
The following methods and attributes have been added to the Blender.Mesh
Python module and it's object types:
->MVert/Edge/FaceSeq:
addPropertyLayer(name, type)
removePropertyLayer(name)
renamePropertyLayer(original name, new name)
properties(readonly list.)
->MVert/Edge/Face
getProperty(name)
setProperty(name, value)
->Mesh module
PropertyTypes (readonly dictionary)
Diffstat (limited to 'source/blender/makesdna/DNA_meshdata_types.h')
-rw-r--r-- | source/blender/makesdna/DNA_meshdata_types.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/source/blender/makesdna/DNA_meshdata_types.h b/source/blender/makesdna/DNA_meshdata_types.h index af9c1ae629d..b2aecc57269 100644 --- a/source/blender/makesdna/DNA_meshdata_types.h +++ b/source/blender/makesdna/DNA_meshdata_types.h @@ -86,6 +86,18 @@ typedef struct MTFace { short mode, tile, unwrap; } MTFace; +/*Custom Data Properties*/ +typedef struct MFloatProperty{ + float f; +} MFloatProperty; +typedef struct MIntProperty{ + int i; +} MIntProperty; +typedef struct MStringProperty{ + char s[256]; +} MStringProperty; + + /* Multiresolution modeling */ typedef struct MultiresCol { float a, r, g, b; |