Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorJoseph Gilbert <ascotan@gmail.com>2006-05-26 01:10:28 +0400
committerJoseph Gilbert <ascotan@gmail.com>2006-05-26 01:10:28 +0400
commit1b577b7f0df9e482a222bf8e51b98349739ed7d7 (patch)
treeb313c9495b93930fa3d7fbd885d2ffabb842dfa2 /source
parentaf87c651a5a8cce6fb78aa3727b097211eadcbf8 (diff)
*python documention & bug fix
- added documentation to Render - saveRenderedImage has an option to save the zbuffer along with the image (off by default) - fixed a really annoying runtime error of uninitialized data being passed to a method in pipeline.c during a render
Diffstat (limited to 'source')
-rw-r--r--source/blender/python/api2_2x/doc/Render.py4
-rw-r--r--source/blender/python/api2_2x/sceneRender.c2
-rw-r--r--source/blender/render/intern/source/pipeline.c2
3 files changed, 6 insertions, 2 deletions
diff --git a/source/blender/python/api2_2x/doc/Render.py b/source/blender/python/api2_2x/doc/Render.py
index 09d6a0bac62..4aef017b6ad 100644
--- a/source/blender/python/api2_2x/doc/Render.py
+++ b/source/blender/python/api2_2x/doc/Render.py
@@ -107,11 +107,13 @@ class RenderData:
Render a series of frames to an output directory.
"""
- def saveRenderedImage(filename):
+ def saveRenderedImage(filename, zbuffer=0):
"""
Saves the image rendered using RenderData.render() to the filename and path
given in the variable 'filename'
@param filename: The path+filename for the rendered image.
+ @type zbuffer: int
+ @param zbuffer: Whether or not to render the zbuffer along with the image.
@type filename: string
@since: 2.40
@requires: You must have an image currently rendered before calling this method
diff --git a/source/blender/python/api2_2x/sceneRender.c b/source/blender/python/api2_2x/sceneRender.c
index 5d81be2e7e4..864dca200cd 100644
--- a/source/blender/python/api2_2x/sceneRender.c
+++ b/source/blender/python/api2_2x/sceneRender.c
@@ -918,6 +918,8 @@ PyObject *RenderData_SaveRenderedImage ( BPy_RenderData * self, PyObject *args )
if( strlen(self->renderContext->pic) + strlen(name_str) > sizeof(filepath)-1 )
return EXPP_ReturnPyObjError( PyExc_ValueError, "full filename too long" );
+ if zbuff !=0 zbuff = 1; //required 1/0
+
BLI_strncpy( filepath, self->renderContext->pic, sizeof(filepath) );
strcat(filepath, name_str);
diff --git a/source/blender/render/intern/source/pipeline.c b/source/blender/render/intern/source/pipeline.c
index 263b044cd94..58d3dd8414c 100644
--- a/source/blender/render/intern/source/pipeline.c
+++ b/source/blender/render/intern/source/pipeline.c
@@ -1070,7 +1070,7 @@ static void threaded_tile_processor(Render *re)
RenderPart *pa, *nextpa;
RenderResult *rr= re->result;
rctf viewplane= re->viewplane;
- int maxthreads, rendering=1, counter= 1, drawtimer=0, hasdrawn, minx;
+ int maxthreads, rendering=1, counter= 1, drawtimer=0, hasdrawn, minx=0;
if(rr==NULL)
return;