blender/doc/python_api/rst
Benoit Bolsee 4213eca5fc BGE VideoTexture: add depth buffer access to ImageViewport and ImageRender.
2 new attributes to ImageViewport and ImageRender object:
depth: set to True to retrieve the depth buffer as an array of float
       (not suitable for texture source).
zbuff: set to True to retrieve the depth buffer as a grey scale pixel array
       (suitable for texture source).

A new mode 'F' is added to VideoTexture.imageToArray() to allow returning the image
buffer as a one dimensional array of float. This mode should only be used to retrieve
the depth buffer of ImageViewport and ImageRender objects.

Example:

viewport = VideoTexture.ImageViewport()
viewport.depth = True
depth = VideoTexture.imageToArray(viewport,'F')
# show depth of bottom left pixel
# 1.0 = infinite, 0.0 = on near clip plane.
print(depth[0])
2012-10-20 22:28:44 +00:00
..
bge.constraints.rst rst bge touch ups: making the title of the examples slightly more noticeable 2012-01-23 19:53:23 +00:00
bge.events.rst py api: sphinx doc corrections, pep8 cleanup and style edits, also added __all__ to some modules which were missing it. 2011-07-31 03:15:37 +00:00
bge.logic.rst Added example of KX_GameObject subclassing to game engine docs. 2012-10-02 14:15:02 +00:00
bge.render.rst Spellfixes: colour -> color 2012-07-04 12:19:50 +00:00
bge.texture.rst BGE VideoTexture: add depth buffer access to ImageViewport and ImageRender. 2012-10-20 22:28:44 +00:00
bge.types.rst rename BGE KX_GameObject attrs 2012-10-09 06:03:57 +00:00
bgl.rst patch [#31216] OpenGL urls updated by Julien DUROURE (julien) 2012-05-01 20:45:03 +00:00
change_log.rst api changelog for 2.64 and 2.63 (which I missed last release) 2012-10-09 01:07:08 +00:00
gpu.rst Style cleanup of gpu rst file. 2012-02-09 06:38:54 +00:00
include__bmesh.rst expanding bmesh example (py api) 2012-05-22 18:14:34 +00:00
info_best_practice.rst spelling cleanup: spelling corrections from user zeffii on IRC. 2012-08-19 15:28:24 +00:00
info_gotcha.rst doc type correction 2012-08-22 15:04:11 +00:00
info_overview.rst remove blender 2.5 references in docs 2012-01-12 15:16:08 +00:00
info_quickstart.rst added note in docs about not beaing able to create new data by calling the class direct. 2012-01-31 22:37:36 +00:00
info_tips_and_tricks.rst code cleanup: remove unused variable assignents and added bmesh submodule links, doc correction reported by dfelinto. 2012-03-09 21:23:15 +00:00