From 52d8e64b857530c85efb6e1c38b4b4fd40d9c345 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 5 Jun 2009 12:48:58 +0000 Subject: PyRNA - Support for python to convert a PyObject into a collection (uses a list of dicts - quite verbose :/) - Operators can now take collection args when called from python. - Support for printing operators that use collections (macro recording). - Added RNA_pointer_as_string which prints all pointer prop values as a python dict. Example that can run in the in test.py (F7 key) bpy.ops.VIEW3D_OT_select_lasso(path=[{"loc":(0, 0), "time":0}, {"loc":(1000, 0), "time":0}, {"loc":(1000, 1000), "time":0}], type='SELECT') for some reason lasso locations always print as 0,0. Need to look into why this is. --- source/blender/python/intern/bpy_rna.h | 1 + 1 file changed, 1 insertion(+) (limited to 'source/blender/python/intern/bpy_rna.h') diff --git a/source/blender/python/intern/bpy_rna.h b/source/blender/python/intern/bpy_rna.h index a97d450fb2f..a2a3015912b 100644 --- a/source/blender/python/intern/bpy_rna.h +++ b/source/blender/python/intern/bpy_rna.h @@ -69,6 +69,7 @@ PyObject *pyrna_prop_CreatePyObject( PointerRNA *ptr, PropertyRNA *prop ); /* operators also need this to set args */ int pyrna_py_to_prop(PointerRNA *ptr, PropertyRNA *prop, void *data, PyObject *value); +int pyrna_pydict_to_props(PointerRNA *ptr, PyObject *kw, const char *error_prefix); PyObject * pyrna_prop_to_py(PointerRNA *ptr, PropertyRNA *prop); /* functions for setting up new props - experemental */ -- cgit v1.2.3