vulkan: Rename name mistake to handle
This commit is contained in:
parent
dd8a5a97ea
commit
001547dbc2
5 changed files with 22 additions and 22 deletions
|
@ -13,7 +13,7 @@ pub struct SwapchainSupportDetails(
|
|||
pub struct VkSurface {
|
||||
instance: Arc<VkInstance>,
|
||||
|
||||
pub(super) surface: vk::SurfaceKHR,
|
||||
pub(super) handle: vk::SurfaceKHR,
|
||||
}
|
||||
|
||||
impl VkSurface {
|
||||
|
@ -34,7 +34,7 @@ impl VkSurface {
|
|||
|
||||
log::debug!("Surface created ({:?})", surface);
|
||||
|
||||
Ok(Self { instance, surface })
|
||||
Ok(Self { instance, handle: surface })
|
||||
}
|
||||
|
||||
pub fn physical_device_queue_supported(
|
||||
|
@ -48,7 +48,7 @@ impl VkSurface {
|
|||
.get_physical_device_surface_support(
|
||||
physical_device.handle,
|
||||
queue_index,
|
||||
self.surface,
|
||||
self.handle,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
@ -61,17 +61,17 @@ impl VkSurface {
|
|||
let formats = self
|
||||
.instance
|
||||
.surface_loader
|
||||
.get_physical_device_surface_formats(physical_device.handle, self.surface)?;
|
||||
.get_physical_device_surface_formats(physical_device.handle, self.handle)?;
|
||||
|
||||
let capabilities = self
|
||||
.instance
|
||||
.surface_loader
|
||||
.get_physical_device_surface_capabilities(physical_device.handle, self.surface)?;
|
||||
.get_physical_device_surface_capabilities(physical_device.handle, self.handle)?;
|
||||
|
||||
let present_modes = self
|
||||
.instance
|
||||
.surface_loader
|
||||
.get_physical_device_surface_present_modes(physical_device.handle, self.surface)?;
|
||||
.get_physical_device_surface_present_modes(physical_device.handle, self.handle)?;
|
||||
|
||||
Ok(SwapchainSupportDetails(
|
||||
formats,
|
||||
|
@ -87,8 +87,8 @@ impl Drop for VkSurface {
|
|||
unsafe {
|
||||
self.instance
|
||||
.surface_loader
|
||||
.destroy_surface(self.surface, None);
|
||||
.destroy_surface(self.handle, None);
|
||||
}
|
||||
log::debug!("Surface destroyed ({:?})", self.surface);
|
||||
log::debug!("Surface destroyed ({:?})", self.handle);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue