Cycles: Fixed OpenCL kernel build.
transform_direction() can't handle parameters in constant address space. Creating a local copy of the parameter satisfies the OpenCL compiler. CUDA and CPU compilers should be able to optimize this away I hope.
This commit is contained in:
parent
2eafae4e39
commit
2f1d3ba6da
|
@ -93,7 +93,8 @@ ccl_device_inline void kernel_update_denoising_features(KernelGlobals *kg,
|
|||
}
|
||||
|
||||
/* Transform normal into camera space. */
|
||||
normal = transform_direction(&kernel_data.cam.worldtocamera, normal);
|
||||
const Transform worldtocamera = kernel_data.cam.worldtocamera;
|
||||
normal = transform_direction(&worldtocamera, normal);
|
||||
|
||||
L->denoising_normal += ensure_finite3(state->denoising_feature_weight * normal);
|
||||
L->denoising_albedo += ensure_finite3(state->denoising_feature_weight * albedo);
|
||||
|
|
Loading…
Reference in New Issue