Fix T97159: AOV Pass in Cycles always gets Alpha Value of 1 for whole image
As far as I can see, it makes a lot of sense to have the alpha channel here, it matches the 2.x behavior and also matches what Eevee is doing. Differential Revision: https://developer.blender.org/D14595
This commit is contained in:
@@ -226,7 +226,7 @@ def list_render_passes(scene, srl):
|
|||||||
if aov.type == 'VALUE':
|
if aov.type == 'VALUE':
|
||||||
yield (aov.name, "X", 'VALUE')
|
yield (aov.name, "X", 'VALUE')
|
||||||
else:
|
else:
|
||||||
yield (aov.name, "RGB", 'COLOR')
|
yield (aov.name, "RGBA", 'COLOR')
|
||||||
|
|
||||||
# Light groups.
|
# Light groups.
|
||||||
for lightgroup in srl.lightgroups:
|
for lightgroup in srl.lightgroups:
|
||||||
|
@@ -32,7 +32,7 @@ ccl_device void svm_node_aov_color(KernelGlobals kg,
|
|||||||
kernel_data.film.pass_stride;
|
kernel_data.film.pass_stride;
|
||||||
ccl_global float *buffer = render_buffer + render_buffer_offset +
|
ccl_global float *buffer = render_buffer + render_buffer_offset +
|
||||||
(kernel_data.film.pass_aov_color + node.z);
|
(kernel_data.film.pass_aov_color + node.z);
|
||||||
kernel_write_pass_float3(buffer, make_float3(val.x, val.y, val.z));
|
kernel_write_pass_float4(buffer, make_float4(val.x, val.y, val.z, 1.0f));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -321,7 +321,7 @@ PassInfo Pass::get_info(const PassType type, const bool include_albedo, const bo
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case PASS_AOV_COLOR:
|
case PASS_AOV_COLOR:
|
||||||
pass_info.num_components = 3;
|
pass_info.num_components = 4;
|
||||||
break;
|
break;
|
||||||
case PASS_AOV_VALUE:
|
case PASS_AOV_VALUE:
|
||||||
pass_info.num_components = 1;
|
pass_info.num_components = 1;
|
||||||
|
Reference in New Issue
Block a user