Fix T63802: textured lights not working with OSL
authorBrecht Van Lommel <brechtvanlommel@gmail.com>
Mon, 13 May 2019 22:40:25 +0000 (00:40 +0200)
committerBrecht Van Lommel <brechtvanlommel@gmail.com>
Mon, 13 May 2019 22:40:25 +0000 (00:40 +0200)
intern/cycles/kernel/kernel_shader.h

index 351b623..c80124d 100644 (file)
@@ -1092,7 +1092,7 @@ ccl_device void shader_eval_surface(KernelGlobals *kg,
 
 #ifdef __OSL__
   if (kg->osl) {
-    if (sd->object == OBJECT_NONE) {
+    if (sd->object == OBJECT_NONE && sd->lamp == LAMP_NONE) {
       OSLShader::eval_background(kg, sd, state, path_flag);
     }
     else {