Refs #8975 -- Add return to RenderDevice::poll() (#8977)

# Objective
Fixes #8975

## Solution
Return the value from wgpu::device::poll().

---

## Changelog
In render_device.rs
- RenderDevice::Poll()
This commit is contained in:
Skovrup1 2023-06-28 03:05:03 +02:00 committed by GitHub
parent ab58100fe3
commit c24520cb72
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -50,10 +50,16 @@ impl RenderDevice {
/// Check for resource cleanups and mapping callbacks.
///
/// Return `true` if the queue is empty, or `false` if there are more queue
/// submissions still in flight. (Note that, unless access to the [`wgpu::Queue`] is
/// coordinated somehow, this information could be out of date by the time
/// the caller receives it. `Queue`s can be shared between threads, so
/// other threads could submit new work at any time.)
///
/// no-op on the web, device is automatically polled.
#[inline]
pub fn poll(&self, maintain: wgpu::Maintain) {
self.device.poll(maintain);
pub fn poll(&self, maintain: wgpu::Maintain) -> bool {
self.device.poll(maintain)
}
/// Creates an empty [`CommandEncoder`](wgpu::CommandEncoder).