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:
authorCampbell Barton <ideasman42@gmail.com>2006-08-26 13:53:26 +0400
committerCampbell Barton <ideasman42@gmail.com>2006-08-26 13:53:26 +0400
commit66bc55e8a6c21b62d46dae4b3621469617578df6 (patch)
tree3ad51850f6693b618d1d69780cea4d4b0162f9b0 /source/blender/python/api2_2x/Scene.h
parentee302f869314bc47097c34fb16f5d9636b1f52c3 (diff)
Added a new iterator type to the scene - scene.objects should eventualy be used in place of scene.getChildren() and linking objects to the scene.
Diffstat (limited to 'source/blender/python/api2_2x/Scene.h')
-rw-r--r--source/blender/python/api2_2x/Scene.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/python/api2_2x/Scene.h b/source/blender/python/api2_2x/Scene.h
index 56a97ab6bf6..6967a569859 100644
--- a/source/blender/python/api2_2x/Scene.h
+++ b/source/blender/python/api2_2x/Scene.h
@@ -38,6 +38,7 @@
/* The Scene PyType Object defined in Scene.c */
extern PyTypeObject Scene_Type;
+extern PyTypeObject SceneObSeq_Type;
#define BPy_Scene_Check(v) \
((v)->ob_type == &Scene_Type)
@@ -51,6 +52,14 @@ typedef struct {
// Python Scene_Type helper functions needed by Blender (the Init function) and Object modules.
+/* Scene object sequence, iterate on the scene object listbase*/
+typedef struct {
+ PyObject_VAR_HEAD /* required python macro */
+ BPy_Scene *bpyscene; /* link to the python scene so we can know if its been removed */
+ Base *iter; /* so we can iterate over the objects */
+} BPy_SceneObSeq;
+
+
PyObject *Scene_Init( void );
PyObject *Scene_CreatePyObject( Scene * cam );
Scene *Scene_FromPyObject( PyObject * pyobj );