diff options
author | Willian Padovani Germano <wpgermano@gmail.com> | 2004-07-25 20:55:45 +0400 |
---|---|---|
committer | Willian Padovani Germano <wpgermano@gmail.com> | 2004-07-25 20:55:45 +0400 |
commit | c50e3f374fe08713b573559904c5f53d852c5e13 (patch) | |
tree | c5bc2eb290f96c6ad4916de6f5b15c57ffcb79a7 /source/blender/python/api2_2x/doc/Radio.py | |
parent | fe9336eb880a1a97121e5f2a6a94c93870d4549b (diff) |
BPython:
- new submodule Scene.Radio, for radiosity: still incomplete, but in shape for demos, updated SConscript to include it;
- new functions in Window module;
- doc updates: adding a todo file and a new start page for our docs: API_intro.py + other updates;
- small fix in Ipo.c provided by Damien McGuinnes (thanks!): Nathan has a patch with IPO additions and fixes for this and more, but until it is committed, there's this fix for Ipo.getCurve('LocX'), LocY, Z and QuatW,X,Y,Z too, according to Damien.
Other files:
- radpreprocess.c: added check for "during_script()" so eventual msgs don't popup during scripts;
- drawmesh.c: made a pointer (display list) be checked before accessed, fixes crash in scripts that forget to update display lists for subsurf meshes when a 3d view is in textured view mode.
Script: updated bevel_center by Loic Berthe.
Diffstat (limited to 'source/blender/python/api2_2x/doc/Radio.py')
-rw-r--r-- | source/blender/python/api2_2x/doc/Radio.py | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/source/blender/python/api2_2x/doc/Radio.py b/source/blender/python/api2_2x/doc/Radio.py new file mode 100644 index 00000000000..380cb298104 --- /dev/null +++ b/source/blender/python/api2_2x/doc/Radio.py @@ -0,0 +1,66 @@ +# Blender.Scene.Radio module and the Radiosity PyType object + +""" +The Blender.Scene.Radio submodule. + +Radio +===== + +This module gives access to B{Scene Radiosity Contexts} in Blender. + +Example:: + import Blender + from Blender import Scene + + # Only the current scene has a radiosity context. + # Naturally, any scene can be made the current one + # with scene.makeCurrent() + + scn = Scene.GetCurrent() + + # this is the only way to access the radiosity object: + + radio = scn.getRadiosityContext() + + radio.setDrawType('Gouraud') + radio.setMode('ShowLimits', 'Z') + + radio.collectMeshes() # prepare patches + radio.go() # calculate radiosity + Blender.Redraw(-1) + + +@type Modes: readonly dictionary +@var Modes: + - ShowLimits + - Z + +@type DrawTypes: readonly dictionary +@var DrawTypes: + - Wire + - Solid + - Gouraud +""" + +class Radio: + """ + The Radiosity object + ==================== + This object wraps the current Scene's radiosity context in Blender. + """ + + def go(): + """ + Start the radiosity simulation. Remember to call L{collectMeshes} first. + """ + + def collectMeshes(): + """ + Convert selected visible meshes to patches for radiosity calculation. + """ + + def freeData(): + """ + Release all memory used by radiosity. + """ + |