bevy_app_compute
bevy_app_compute copied to clipboard
Update to bevy 0.14 (and other changes)
Updated to bevy 0.14 (and updated other dependencies to most recent versions).
Also in this PR:
The AppComputeWorker::run method was blocking the main thread from executing for large GPU loads because the poll method was using MaintainBase::Wait instead of MaintainBase::Poll, causing it to wait until the GPU was finished executing before exiting the function. I have swapped the code to use MaintainBase::Poll, so the run method will no longer block the execution of the thread it's on. Note that this is disabled by default, so no currently functionality will be changed. To make it asynchronous, call the asynchronous method in the WorkerBuilder to set to "Poll" mode. The maximum time argument specifies how long you are willing to wait for a response from the GPU before pausing the frame for the GPU to complete its operation.
Note that this PR should be diffed against #14 instead of the current main branch.
@AnthonyTornetta I tried updating the crate to use [email protected], but later found out that you are doing that too. It seemed that the original author has not time for merge this PR. I think we should just publish it under a new crate name.
@ivanceras Enjoy https://crates.io/crates/bevy_easy_compute
@AnthonyTornetta thank you for doing this initiative.