Logo Search packages:      
Sourcecode: blender version File versions  Download package

Scene::SceneObjects Class Reference

List of all members.

Detailed Description

The SceneObjects (Scene ObjectSeq) object
      This object gives access to the Objects in a Scene in Blender.

            from Blender import Scene
            scn = Scene.GetCurrent()
            scn.objects.selected = [] # select none
            scn.objects.selected = scn.objects # select all
            scn.objects.context = scn.objects # select all and move into the scenes display layer
            # get a list of mesh objects
            obs = [ob for ob in scn.objects if ob.type == 'Mesh']
            # Select only these mesh objects
            scn.objects.selected = obs
            # print all object names
            for ob in scn.objects: print ob.name
            # make a list of objects that you can add and remove to
            # will not affect the current scene
            scene_obs = list(scn.objects)

@ivar selected: an iterator over all the selected objects in a scene.
@type selected: sequence of L{Object}
@ivar context: an iterator over all the visible selected objects in a scene.
@type context: sequence of L{Object}
@ivar active: the active object in the scene.
@type active: L{Object}
@ivar camera: the active camera in the scene.
@type camera: L{Object}

Definition at line 337 of file Scene.py.

Public Member Functions

def link
def new
def unlink

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index