Fix T81250: Crash after undoing with prefetching
Main DB and it's structs can point to different address after undoing. In this case problem was that bmain was not updated. Same fix was done for scene as well. Reviewed By: sergey Differential Revision: https://developer.blender.org/D9240
This commit is contained in:
parent
31629c1363
commit
8d1978a8e0
Notes:
blender-bot
2023-09-08 04:55:43 +02:00
Referenced by commit 8b6ce77f16
, VSE: Fix prefetch initialization sequence
Referenced by issue #81250, Crashes when undoing VSE
|
@ -319,6 +319,7 @@ static void seq_prefetch_update_scene(Scene *scene)
|
|||
return;
|
||||
}
|
||||
|
||||
pfjob->scene = scene;
|
||||
seq_prefetch_free_depsgraph(pfjob);
|
||||
seq_prefetch_init_depsgraph(pfjob);
|
||||
}
|
||||
|
@ -499,15 +500,14 @@ static PrefetchJob *seq_prefetch_start(const SeqRenderData *context, float cfra)
|
|||
BLI_mutex_init(&pfjob->prefetch_suspend_mutex);
|
||||
BLI_condition_init(&pfjob->prefetch_suspend_cond);
|
||||
|
||||
pfjob->bmain = context->bmain;
|
||||
pfjob->bmain_eval = BKE_main_new();
|
||||
|
||||
pfjob->scene = context->scene;
|
||||
seq_prefetch_init_depsgraph(pfjob);
|
||||
}
|
||||
}
|
||||
seq_prefetch_update_scene(context->scene);
|
||||
seq_prefetch_update_context(context);
|
||||
pfjob->bmain = context->bmain;
|
||||
|
||||
pfjob->cfra = cfra;
|
||||
pfjob->num_frames_prefetched = 1;
|
||||
|
|
Loading…
Reference in New Issue