WIP: Initial version of a single-frame job compiler #104189

Closed
k8ie wants to merge 26 commits from k8ie/flamenco:single-frame into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
Showing only changes of commit b9aca93b54 - Show all commits

View File

@ -8,8 +8,6 @@ const JOB_TYPE = {
description: "Frame to render"}, description: "Frame to render"},
{ key: "chunk_size", type: "int32", default: 128, propargs: {min: 1}, description: "Number of samples to render in one Blender render task", { key: "chunk_size", type: "int32", default: 128, propargs: {min: 1}, description: "Number of samples to render in one Blender render task",
visible: "submission" }, visible: "submission" },
{ key: "denoising", type: "bool", required: true, default: false,
description: "Toggles OpenImageDenoise" },
k8ie marked this conversation as resolved Outdated

I think this can be moved into the hidden settings, with expr: "bpy.context.scene.cycles.use_denoising". That way the denoising is managed via the normal setting, and not yet again by Flamenco.

I think this can be moved into the hidden settings, with `expr: "bpy.context.scene.cycles.use_denoising"`. That way the denoising is managed via the normal setting, and not yet again by Flamenco.
// render_output_root + add_path_components determine the value of render_output_path. // render_output_root + add_path_components determine the value of render_output_path.
@ -24,7 +22,9 @@ const JOB_TYPE = {
// Automatically evaluated settings: // Automatically evaluated settings:
{ key: "blendfile", type: "string", required: true, description: "Path of the Blend file to render", visible: "web" }, { key: "blendfile", type: "string", required: true, description: "Path of the Blend file to render", visible: "web" },
{ key: "format", type: "string", required: true, eval: "C.scene.render.image_settings.file_format", visible: "web" }, { key: "format", type: "string", required: true, eval: "C.scene.render.image_settings.file_format", visible: "web" },
{ key: "uses_compositing", type: "bool", required: true, eval: "C.scene.use_nodes and C.scene.render.use_compositing", visible: "web" }, { key: "compositing", type: "bool", required: true, eval: "C.scene.use_nodes and C.scene.render.use_compositing", visible: "web" },
{ key: "denoising", type: "bool", required: true, eval: "C.scene.cycles.use_denoising", visible: "web",
description: "Toggles OpenImageDenoise" },
k8ie marked this conversation as resolved Outdated

The properties are typically named as 'imperative' ("do X", "use Y") and not 'descriptive' ("does X", "uses Y"). So this could be use_compositing.

The properties are typically named as 'imperative' ("do X", "use Y") and not 'descriptive' ("does X", "uses Y"). So this could be `use_compositing`.
Outdated
Review

Should I change denoising to be use_denoising or use_compositing to be just compositing? Just to keep things consistent.

Should I change `denoising` to be `use_denoising` or `use_compositing` to be just `compositing`? Just to keep things consistent.

Use use_denoising and use_compositing.

Use `use_denoising` and `use_compositing`.
{ key: "image_file_extension", type: "string", required: true, eval: "C.scene.render.file_extension", visible: "hidden", { key: "image_file_extension", type: "string", required: true, eval: "C.scene.render.file_extension", visible: "hidden",
description: "File extension used for the final export" }, description: "File extension used for the final export" },
{ key: "samples", type: "string", required: true, eval: "f'1-{C.scene.cycles.samples}'", visible: "web", { key: "samples", type: "string", required: true, eval: "f'1-{C.scene.cycles.samples}'", visible: "web",
@ -223,7 +223,7 @@ import bpy
C = bpy.context C = bpy.context
basepath = "${renderOutput}/" basepath = "${renderOutput}/"
filename = "${filename}"`; filename = "${filename}"`;
if (settings.uses_compositing) { if (settings.compositing) {
// Do the full composite+export pipeline // Do the full composite+export pipeline
// uses snippets from // uses snippets from
// https://github.com/state-of-the-art/BlendNet/blob/master/BlendNet/script-compose.py#L94 // https://github.com/state-of-the-art/BlendNet/blob/master/BlendNet/script-compose.py#L94