Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoseph Eagar <joeedh@gmail.com>2006-11-17 09:14:15 +0300
committerJoseph Eagar <joeedh@gmail.com>2006-11-17 09:14:15 +0300
commit4c5fcf136b510ddb2aeb9c1c9afbc155e95ce12c (patch)
tree1cf7b5790e151d5f9b2cb39e6ccd2f320bd64b2b /source/blender/python/api2_2x/NMesh.c
parentc8ca36a9c8b9f8fabf1b8f09507f35349017cfbf (diff)
=ID Properties Update=
This commit adds file reading/writing of ID properties to all ID types, and also adds python access for NMesh, Mesh, Scene and Image. Note that the file reading code might need some more work for certain future/planned features to save right. Also I updated a few comments in idprop.c.
Diffstat (limited to 'source/blender/python/api2_2x/NMesh.c')
-rw-r--r--source/blender/python/api2_2x/NMesh.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/python/api2_2x/NMesh.c b/source/blender/python/api2_2x/NMesh.c
index fe97a7c916a..164011fee6e 100644
--- a/source/blender/python/api2_2x/NMesh.c
+++ b/source/blender/python/api2_2x/NMesh.c
@@ -73,6 +73,7 @@
#include "Object.h"
#include "Key.h"
#include "Mathutils.h"
+#include "IDProp.h"
#include "constant.h"
#include "gen_utils.h"
@@ -1718,6 +1719,9 @@ static PyObject *NMesh_getattr( PyObject * self, char *name )
if( strcmp( name, "name" ) == 0 )
return EXPP_incr_ret( me->name );
+ else if ( strcmp( name, "properties" ) == 0 )
+ return BPy_Wrap_IDProperty( (ID*)me->mesh, IDP_GetProperties((ID*)me->mesh, 1) );
+
else if( strcmp( name, "mode" ) == 0 )
return PyInt_FromLong( me->mode );