diff options
Diffstat (limited to 'source/blender/editors/render/render_update.c')
-rw-r--r-- | source/blender/editors/render/render_update.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/source/blender/editors/render/render_update.c b/source/blender/editors/render/render_update.c index f11a8177bf8..46c3417e8c2 100644 --- a/source/blender/editors/render/render_update.c +++ b/source/blender/editors/render/render_update.c @@ -48,12 +48,14 @@ #include "BKE_context.h" #include "BKE_DerivedMesh.h" #include "BKE_icons.h" +#include "BKE_layer.h" #include "BKE_main.h" #include "BKE_material.h" #include "BKE_node.h" #include "BKE_paint.h" #include "BKE_scene.h" +#include "GPU_lamp.h" #include "GPU_material.h" #include "GPU_buffers.h" @@ -374,6 +376,7 @@ static void texture_changed(Main *bmain, Tex *tex) Lamp *la; World *wo; Scene *scene; + SceneLayer *sl; Object *ob; bNode *node; bool texture_draw = false; @@ -382,8 +385,11 @@ static void texture_changed(Main *bmain, Tex *tex) BKE_icon_changed(BKE_icon_id_ensure(&tex->id)); /* paint overlays */ - for (scene = bmain->scene.first; scene; scene = scene->id.next) - BKE_paint_invalidate_overlay_tex(scene, tex); + for (scene = bmain->scene.first; scene; scene = scene->id.next) { + for (sl = scene->render_layers.first; sl; sl = sl->next) { + BKE_paint_invalidate_overlay_tex(scene, sl, tex); + } + } /* find materials */ for (ma = bmain->mat.first; ma; ma = ma->id.next) { |