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
diff options
context:
space:
mode:
authorAntony Riakiotakis <kalast@gmail.com>2015-01-27 17:37:49 +0300
committerAntony Riakiotakis <kalast@gmail.com>2015-01-27 17:41:45 +0300
commit77848f23a49235b031b6d2d5b71654d12b7e66ad (patch)
treedcceb51d065c8df868c60d9994538ca72c030fd0 /source/blender/windowmanager
parentd687625ad8df6ebcf14d6d28e46aa8b165628dc3 (diff)
Fix T43371 lamps not updated on appenidng. Remove GPU materials on
appeniding.
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r--source/blender/windowmanager/intern/wm_operators.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c
index 000f9f1eada..3097ad41a6f 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -102,6 +102,8 @@
#include "ED_util.h"
#include "ED_view3d.h"
+#include "GPU_material.h"
+
#include "RNA_access.h"
#include "RNA_define.h"
#include "RNA_enum_types.h"
@@ -2682,7 +2684,9 @@ static int wm_link_append_exec(bContext *C, wmOperator *op)
/* recreate dependency graph to include new objects */
DAG_scene_relations_rebuild(bmain, scene);
-
+
+ /* free gpu materials, some materials depend on existing objects, such as lamps so freeing correctly refreshes */
+ GPU_materials_free();
BLO_blendhandle_close(bh);
/* XXX TODO: align G.lib with other directory storage (like last opened image etc...) */