LookDev: When HDRI could not be reloaded we should switch to world
authorJeroen Bakker <j.bakker@atmind.nl>
Wed, 6 Jun 2018 13:25:05 +0000 (15:25 +0200)
committerJeroen Bakker <j.bakker@atmind.nl>
Wed, 6 Jun 2018 13:26:09 +0000 (15:26 +0200)
Thanks for reporting sergey!

source/blender/draw/engines/eevee/eevee_lookdev.c

index 8ef52f8c553a68803a620b5408e9c7ab169ab786..5c626b42ddde0d30bbc2cb42f81e91eebeafa974 100644 (file)
@@ -42,7 +42,7 @@ void EEVEE_lookdev_cache_init(
        const DRWContextState *draw_ctx = DRW_context_state_get();
        View3D *v3d = draw_ctx->v3d;
        if (LOOK_DEV_MODE_ENABLED(v3d)) {
-               StudioLight *sl = BKE_studiolight_find(v3d->shading.studio_light, STUDIOLIGHT_ORIENTATION_WORLD);
+               StudioLight *sl = BKE_studiolight_find(v3d->shading.studio_light, STUDIOLIGHT_INTERNAL | STUDIOLIGHT_ORIENTATION_WORLD);
                if ((sl->flag & STUDIOLIGHT_ORIENTATION_WORLD)) {
                        struct Gwn_Batch *geom = DRW_cache_fullscreen_quad_get();
                        GPUTexture *tex;