Hi,
I wrote a plugin for blender 2.57 and try now to fix the problems I have when running the plugin in blender 2.63.
In my old script I create some different file output nodes (image,depth,...) and render multiple views of a scene in a loop (not using the timeline) storing the different outputs with a increasing filename counter:
in 2.57 this works:
| Code: |
nodes = bpy.data.scenes[0].node_tree.nodes
imgOutNode = nodes["File Output"]
depthOutNode = nodes["Depth_File_Output"]
for n in range(something):
fileindex = "%3.3i_" % (n)
imgOutNode.filepath = path.join(filepath,'images/',fileindex)
depthOutNode.filepath = path.join(filepath,'depth/',fileindex)
|
(This has rendered sequences: 000_Image0001.png, 001_Image0001.png,...)
But the .filepath property doesn't exist anymore in the node objects.
I found out that they now have the base_path proberty:
| Code: |
fileindex = "%5.5i_" % (n)
imgOutNode.base_path = path.join(filepath,'images/')
depthOutNode.base_path = path.join(filepath,'depth/')
|
But I have no idea how to access now the output filename. How can I change for each output node the name similar to this:
| Code: |
imgOutNode.secretFileName = fileindex
depthOutNode.secretFileName = fileindex
|
Hope my description is not that confusing and anyone can help me with this...!?
Hi,
you can set the name of the image via
[code]
imgOutNode.file_slots[0].path = "name_of_output_img"
[/code]
Hope that helps.
Regards, Flo