Fix output file format problem
parent
58015c11be
commit
c6dfcb6655
|
@ -135,7 +135,7 @@ class GPEXP_OT_split_to_scene(bpy.types.Operator):
|
||||||
if err:
|
if err:
|
||||||
self.report({'ERROR'}, err)
|
self.report({'ERROR'}, err)
|
||||||
return {"CANCELLED"}
|
return {"CANCELLED"}
|
||||||
|
|
||||||
elif self.mode == 'INDIVIDUAL':
|
elif self.mode == 'INDIVIDUAL':
|
||||||
print('split selected object individually in separated scenes')
|
print('split selected object individually in separated scenes')
|
||||||
errors = []
|
errors = []
|
||||||
|
|
|
@ -223,11 +223,11 @@ def connect_render_layer(rlayer, ng=None, out=None, frame=None):
|
||||||
if groupout.links and groupout.links[0].to_node.type == 'OUTPUT_FILE':
|
if groupout.links and groupout.links[0].to_node.type == 'OUTPUT_FILE':
|
||||||
# if already connected to outfile just skip cause user might have customised the name
|
# if already connected to outfile just skip cause user might have customised the name
|
||||||
return
|
return
|
||||||
|
|
||||||
slot_name = f'{lname}/{lname}_'
|
|
||||||
out_name = f'OUT_{obname}' # or get output from frame
|
out_name = f'OUT_{obname}' # or get output from frame
|
||||||
if not out:
|
if not out:
|
||||||
out = nodes.get(out_name)
|
out = nodes.get(out_name)
|
||||||
|
|
||||||
if not out:
|
if not out:
|
||||||
# color = (0.2,0.3,0.5)
|
# color = (0.2,0.3,0.5)
|
||||||
out = fn.create_node('CompositorNodeOutputFile', tree=node_tree, location=(fn.real_loc(ng)[0]+500, fn.real_loc(ng)[1]+50), width=600) # =(ng.location[0]+600, ng.location[1]+50)
|
out = fn.create_node('CompositorNodeOutputFile', tree=node_tree, location=(fn.real_loc(ng)[0]+500, fn.real_loc(ng)[1]+50), width=600) # =(ng.location[0]+600, ng.location[1]+50)
|
||||||
|
@ -240,6 +240,13 @@ def connect_render_layer(rlayer, ng=None, out=None, frame=None):
|
||||||
else:
|
else:
|
||||||
out.base_path = f'//render/{out_base}'
|
out.base_path = f'//render/{out_base}'
|
||||||
|
|
||||||
|
if out.format.file_format == 'OPEN_EXR_MULTILAYER':
|
||||||
|
# Direct name in multilayer
|
||||||
|
slot_name = lname
|
||||||
|
else:
|
||||||
|
# base_path/ named_folder/image_####
|
||||||
|
slot_name = f'{lname}/{lname}_'
|
||||||
|
|
||||||
## out_input = out.inputs.get(slot_name) # ok for non-numbered outputs
|
## out_input = out.inputs.get(slot_name) # ok for non-numbered outputs
|
||||||
|
|
||||||
out_input = None
|
out_input = None
|
||||||
|
|
Loading…
Reference in New Issue