Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorBrecht Van Lommel <brecht@blender.org>2022-03-03 15:49:08 +0300
committerBrecht Van Lommel <brecht@blender.org>2022-03-03 15:49:08 +0300
commit0f7793303118a7e3bf62168e9e8bca4d9e28f873 (patch)
tree51b8e077c02f6b2b603208c6556d2ce58a62cff9 /intern
parentffaaa0bcbf477c30cf3665b9330bbbb767397169 (diff)
parent9c2e385509becf22924293a81470f25a88300b62 (diff)
Merge branch 'blender-v3.1-release'
Diffstat (limited to 'intern')
-rw-r--r--intern/cycles/kernel/light/light.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/intern/cycles/kernel/light/light.h b/intern/cycles/kernel/light/light.h
index 1c0e97b1675..b08b4ebc068 100644
--- a/intern/cycles/kernel/light/light.h
+++ b/intern/cycles/kernel/light/light.h
@@ -381,11 +381,19 @@ ccl_device bool light_sample_from_distant_ray(KernelGlobals kg,
float costheta = dot(-lightD, ray_D);
float cosangle = klight->distant.cosangle;
+ /* Workaround to prevent a hang in the classroom scene with AMD HIP drivers 22.10,
+ * Remove when a compiler fix is available. */
+#ifdef __HIP__
+ ls->shader = klight->shader_id;
+#endif
+
if (costheta < cosangle)
return false;
ls->type = type;
+#ifndef __HIP__
ls->shader = klight->shader_id;
+#endif
ls->object = PRIM_NONE;
ls->prim = PRIM_NONE;
ls->lamp = lamp;