diff options
author | Tamito Kajiyama <rd6t-kjym@asahi-net.or.jp> | 2012-10-29 05:09:12 +0400 |
---|---|---|
committer | Tamito Kajiyama <rd6t-kjym@asahi-net.or.jp> | 2012-10-29 05:09:12 +0400 |
commit | 15ed8343437c6b304de72cd14591455da1d5b3ec (patch) | |
tree | cbe40f76668f5e8539744c4d2f8aeaa0ded72f52 /doc | |
parent | 5acd5d14970c829c2873623716a67beeb6da5278 (diff) | |
parent | dd106b5c7a129e00bebe121c4da8cb90a16d48cb (diff) |
Merged changes in the trunk up to revision 51718.
Conflicts resolved:
source/blender/blenloader/intern/readfile.c
source/blender/makesrna/intern/rna_scene.c
release/datafiles/startup.blend
Diffstat (limited to 'doc')
-rw-r--r-- | doc/python_api/rst/bge.texture.rst | 23 | ||||
-rw-r--r-- | doc/python_api/rst/info_overview.rst | 2 | ||||
-rw-r--r-- | doc/python_api/rst/info_quickstart.rst | 20 |
3 files changed, 41 insertions, 4 deletions
diff --git a/doc/python_api/rst/bge.texture.rst b/doc/python_api/rst/bge.texture.rst index 07d83f66bd4..0c9e9da0661 100644 --- a/doc/python_api/rst/bge.texture.rst +++ b/doc/python_api/rst/bge.texture.rst @@ -351,6 +351,15 @@ When the texture object is deleted, the new texture is deleted and the old textu use whole viewport to render + .. attribute:: depth + + use depth component of render as array of float - not suitable for texture source, + should only be used with bge.texture.imageToArray(mode='F') + + .. attribute:: zbuff + + use depth component of render as grey scale color - suitable for texture source + .. class:: ImageViewport() Image source from viewport @@ -399,6 +408,15 @@ When the texture object is deleted, the new texture is deleted and the old textu use whole viewport to capture + .. attribute:: depth + + use depth component of viewport as array of float - not suitable for texture source, + should only be used with bge.texture.imageToArray(mode='F') + + .. attribute:: zbuff + + use depth component of viewport as grey scale color - suitable for texture source + .. class:: Texture(gameObj) Texture objects @@ -518,13 +536,16 @@ When the texture object is deleted, the new texture is deleted and the old textu 0 to force a fixed 0 color channel and 1 to force a fixed 255 color channel. Example: "BGR" will return 3 bytes per pixel with the Blue, Green and Red channels in that order. "RGB1" will return 4 bytes per pixel with the Red, Green, Blue channels in that order and the alpha channel forced to 255. + A special mode "F" allows to return the image as an array of float. This mode should only be used to retrieve + the depth buffer of the ImageViewport and ImageRender object. The default mode is "RGBA". + :type mode: string :rtype: :class:`~bgl.buffer` :return: A object representing the image as one dimensional array of bytes of size (pixel_size*width*height), line by line starting from the bottom of the image. The pixel size and format is determined by the mode - parameter. + parameter. For mode 'F', the array is a one dimensional array of float of size (width*height). .. function:: materialID(object,name) diff --git a/doc/python_api/rst/info_overview.rst b/doc/python_api/rst/info_overview.rst index 30c45213570..818eb692be9 100644 --- a/doc/python_api/rst/info_overview.rst +++ b/doc/python_api/rst/info_overview.rst @@ -71,7 +71,7 @@ The only difference between addons and built-in python modules is that addons mu The user preferences addon listing uses **bl_info** to display information about each addon. -`See Addons <http://wiki.blender.org/index.php/Dev:2.6/Py/Scripts/Guidelines/Addons>`_ for details on the **bl_info** dictionary. +`See Addons <http://wiki.blender.org/index.php/Dev:2.5/Py/Scripts/Guidelines/Addons>`_ for details on the **bl_info** dictionary. Integration through Classes diff --git a/doc/python_api/rst/info_quickstart.rst b/doc/python_api/rst/info_quickstart.rst index 19ec8059aca..62ad4e9c4d8 100644 --- a/doc/python_api/rst/info_quickstart.rst +++ b/doc/python_api/rst/info_quickstart.rst @@ -2,8 +2,8 @@ Quickstart Introduction *********************** -Intro -===== +Preface +======= This API is generally stable but some areas are still being added and improved. @@ -58,6 +58,22 @@ A quick list of helpful things to know before starting: * To examine further scripts distributed with Blender, see ``~/.blender/scripts/startup/bl_ui`` for the user interface and ``~/.blender/scripts/startup/bl_op`` for operators. +Running Scripts +--------------- + +The two most common ways to execute python scripts are using the built-in text editor or entering commands in the python console. + +Both the **Text Editor** and **Python Console** are space types you can select from the view header. + +Rather then manually configuring your spaces for Python development, you may prefer to use the **Scripting** screen, included default with Blender, accessible from the top headers screen selector. + +From the text editor you can open ``.py`` files or paste then from the clipboard, then test using **Run Script**. + +The Python Console is typically used for typing in snippets and for testing to get immediate feedback, but can also have entire scripts pasted into it. + +Scripts can also run from the command line with Blender but to learn Blender/Python this isn't essential. + + Key Concepts ============ |