===Python API===

New Constraint API.  Constraints are accessible through a "constraints"
attribute in poses and objects.  Would be REALLY NICE for armature users to
pound on this code.
This commit is contained in:
Ken Hughes
2006-05-07 14:57:58 +00:00
parent 8255bdce57
commit cd3af13a1b
11 changed files with 2011 additions and 37 deletions

View File

@@ -109,6 +109,7 @@ struct rctf;
#include "Pose.h"
#include "Group.h"
#include "Modifier.h"
#include "Constraint.h"
#include "gen_utils.h"
#include "EXPP_interface.h"
#include "BIF_editkey.h"
@@ -3594,7 +3595,9 @@ static PyObject *Object_getAttr( BPy_Object * obj, char *name )
if( StringEqual( name, "drawSize" ) )
return ( PyFloat_FromDouble( object->empty_drawsize ) );
if( StringEqual( name, "modifiers" ) )
return ModSeq_CreatePyObject( obj->object );
return ModSeq_CreatePyObject( object );
if( StringEqual( name, "constraints" ) )
return ObConstraintSeq_CreatePyObject( object );
/* not an attribute, search the methods table */
return Py_FindMethod( BPy_Object_methods, ( PyObject * ) obj, name );