Replay Mod (Fabric & Forge)

Replay Mod (Fabric & Forge)

787k Downloads

Add UI and rendering on different threads

TheChocolateOre opened this issue ยท 3 comments

commented

I haven't checked the code, but I suspect that the UI and rendering take place in the same thread, making the UI not very responsive during rendering (especially with anti-aliasing enabled).

commented

both Minecraft and ffmpeg are mostly single-threaded, if you want them to use multiple threads, you'll have to rewrite Minecraft and ffmpeg so they can use multiple threads

commented

This seems very difficult to implement: Nearly all of MC assumes there to only be one render thread.
So we'd basically have to detach the UI from MC completely (or ensure that everything it uses is actually thread-safe, which it probably is not) and do it all on our own.

What makes it even worse is that the low-level render setup of MC has changed quite a few times, so we'd basically get a different problem to solve for each of the major versions.

commented

Yeah, I was visualizing moving towards rendering as background jobs, so the user can freely create more camera paths or even exist the replay and open another one. Reading your comments, at best could be implemented as a fragile hack(if even possible), with too many hours of work.

Feel free to close this.