Need help solving how to render an image and then save to a filepath while in a loop.
The following takes a photo and exports; however it isn't rendered.
sce = bpy.context.scene.name
bpy.data.scenes[sce].render.filepath = 'filepath'+str(i+1)+'.png'
bpy.ops.render.opengl(write_still=True)
What needs to be changed?
bpy.context.scene.render.filepath = "rndr_###.png"
, next you would have to set the frame usingbpy.context.scene.frame_set(#)
within the loop, see: What is the Python script to set the current frame and finally you might want to reset the output path. Also, I recommend take the tour to learn about how this site works: blender.stackexchange.com/tour thanks. $\endgroup$