Stop prefetching before undoing.
Details
Diff Detail
- Repository
- rB Blender
Event Timeline
I think this code should be moved into WM_jobs_kill_all, and it should stop prefetching in all scenes, not just the active one.
Do you mean by that that I should use WM_jobs API, so that prefetch job is added to wm->jobs?
I could do that, I am not sure why I didn't. I guess I thought that prefetch would be fundamentally inpompatible, but it doesn't really look like it is.
For this fix prefetch doesn't have to be moved to the jobs system, just the call to BKE_sequencer_prefetch_stop() should be moved into WM_jobs_kill_all() so that it is called from all the same places.
Letting prefetch use the jobs system is fine as well, but probably better for master than 2.83.
WM_jobs_kill_all() would have to have access to bmain to see all prefetch jobs - they are owned by scene.
I can make BKE_sequencer_prefetch_stop_all() and access bmain global...