diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2017-06-29 20:05:26 +0300 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2017-06-29 20:07:21 +0300 |
commit | 98c8b5a6fbdc47eb13d3d2d19457135ef54774cd (patch) | |
tree | 257edfb226fa01d75cee5ffa20badd330e3f2ec1 | |
parent | 2c62493891ae46af3c3c4b5475412127d0641c8e (diff) |
No need to free all the shaders when appending or reloading libraries
To recompile all the shaders is expensive. And something to be avoided at all costs.
It was needed before because for every new lamp in the file we needed to
recompile the shaders. Now this is no longer required since we are using
UBOs for the sahders.
-rw-r--r-- | source/blender/windowmanager/intern/wm_files_link.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/source/blender/windowmanager/intern/wm_files_link.c b/source/blender/windowmanager/intern/wm_files_link.c index ff37765b683..af0d2be8097 100644 --- a/source/blender/windowmanager/intern/wm_files_link.c +++ b/source/blender/windowmanager/intern/wm_files_link.c @@ -504,9 +504,6 @@ static int wm_link_append_exec(bContext *C, wmOperator *op) /* recreate dependency graph to include new objects */ DEG_scene_relations_rebuild(bmain, scene); - - /* free gpu materials, some materials depend on existing objects, such as lamps so freeing correctly refreshes */ - GPU_materials_free(); /* XXX TODO: align G.lib with other directory storage (like last opened image etc...) */ BLI_strncpy(G.lib, root, FILE_MAX); @@ -802,9 +799,6 @@ static void lib_relocate_do( /* recreate dependency graph to include new objects */ DEG_scene_relations_rebuild(bmain, scene); - - /* free gpu materials, some materials depend on existing objects, such as lamps so freeing correctly refreshes */ - GPU_materials_free(); } void WM_lib_reload(Library *lib, bContext *C, ReportList *reports) |