Fix #33114: crash with render frame update script and GLSL.
This commit is contained in:
@@ -378,6 +378,12 @@ static void scene_changed(Main *bmain, Scene *UNUSED(scene))
|
||||
|
||||
void ED_render_id_flush_update(Main *bmain, ID *id)
|
||||
{
|
||||
/* this can be called from render or baking thread when a python script makes
|
||||
* changes, in that case we don't want to do any editor updates, and making
|
||||
* GPU changes is not possible because OpenGL only works in the main thread */
|
||||
if (!BLI_thread_is_main())
|
||||
return;
|
||||
|
||||
switch (GS(id->name)) {
|
||||
case ID_MA:
|
||||
material_changed(bmain, (Material *)id);
|
||||
|
Reference in New Issue
Block a user