Hi guys,
I have some Problems with Blender’s background mode.
I created a script that generates a 3D scene and an animation. Now I want to render this scene in two ways:
- just some “random” frames as png
- the whole animation
It’s working great when I use a normal command like blender -P myScript.py, but when I use blender -b -P myScript.py it crashes with the following error:
15618 Segmentation fault LD_LIBRARY_PATH=/opt/python2.5.2/lib:$LD_LIBRARY_PATH /opt/blender2.46/blender $*
I was looking for the line that let Blender crash and I found it:
context.renderAnim();
This is the code:
context = Scene.GetCurrent().getRenderingContext();
self.renderSettings(context);
for i in range(0, len(self.__preview_frames)):
frame = self.__preview_frames[i];
context.imageSizeX(800);
context.imageSizeY(600);
context.extensions = True;
context.renderPath = self.__path;
context.framesPerSec(25);
context.imageType = Scene.Render.PNG;
context.sFrame = frame;
context.eFrame = frame;
<b>context.renderAnim();</b>
And here’s my question:
Is it possible to render images or animations in backround mode via scripts with renderAnim()?
I hope somebody can help me with this problem. Thanks.
KoRn