Module Camera
[frames | no frames]

Module Camera

The Blender.Camera submodule.

Camera Data

This module provides access to Camera Data objects in Blender.

Example:
 from Blender import Camera, Object, Scene
 c = Camera.New('ortho').    # create new ortho camera data
 c.lens = 35.0               # set lens value
 cur = Scene.getCurrent().   # get current scene
 ob = Object.New('Camera').  # make camera object
 ob.link(c).                 # link camera data with this object
 cur.link(ob).               # link object into scene
 cur.setCurrentCamera(ob).   # make this camera the active";

Classes
Camera This object gives access to Camera-specific data in Blender.

Function Summary
Blender Camera or a list of Blender Cameras Get(name)
Get the Camera Data object(s) from Blender.
Blender Camera New(type, name)
Create a new Camera Data object.

Function Details

Get(name=None)

Get the Camera Data object(s) from Blender.
Parameters:
name - The name of the Camera Data.
           (type=string)
Returns:
It depends on the name parameter:
  • (name): The Camera Data object with the given name;
  • (): A list with all Camera Data objects in the current scene.

           (type=Blender Camera or a list of Blender Cameras)

New(type='persp', name='CamData')

Create a new Camera Data object.
Parameters:
type - The Camera type: 'persp' or 'ortho'.
           (type=string)
name - The Camera Data name.
           (type=string)
Returns:
The created Camera Data object.
           (type=Blender Camera)

Generated by Epydoc 2.0 on Mon Feb 2 18:51:07 2004 http://epydoc.sf.net