summaryrefslogtreecommitdiff
path: root/cnn_v3
diff options
context:
space:
mode:
Diffstat (limited to 'cnn_v3')
-rw-r--r--cnn_v3/training/blender_export.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/cnn_v3/training/blender_export.py b/cnn_v3/training/blender_export.py
index 5ad7273..d0ac41d 100644
--- a/cnn_v3/training/blender_export.py
+++ b/cnn_v3/training/blender_export.py
@@ -122,7 +122,11 @@ def configure_scene(args):
# automatically. This is more reliable than the compositor FileOutput
# approach (which requires per-pass socket wiring that varies by Blender
# version and may silently omit passes).
- scene.render.image_settings.file_format = "OPEN_EXR_MULTILAYER"
+ if _is_blender5():
+ scene.render.image_settings.file_format = "OPEN_EXR"
+ scene.render.image_settings.use_multilayer = True
+ else:
+ scene.render.image_settings.file_format = "OPEN_EXR_MULTILAYER"
scene.render.image_settings.exr_codec = "ZIP"
out_abs = os.path.abspath(args.output)
os.makedirs(out_abs, exist_ok=True)