Expose the DxgiAdapter in the Hal adapter (#7852)

This commit is contained in:
Simon Hausmann 2025-06-26 22:34:59 +02:00 committed by GitHub
parent 12808193fe
commit 208fe4c23d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 0 deletions

View File

@ -85,6 +85,7 @@ Bottom level categories:
#### DX12
- Get `vertex_index` & `instance_index` builtins working for indirect draws. By @teoxoy in [#7535](https://github.com/gfx-rs/wgpu/pull/7535)
- Added `wgpu_hal::dx12::Adapter::as_raw()`. By @tronical in [##7852](https://github.com/gfx-rs/wgpu/pull/7852)
#### Vulkan

View File

@ -604,6 +604,12 @@ pub struct Adapter {
unsafe impl Send for Adapter {}
unsafe impl Sync for Adapter {}
impl Adapter {
pub fn as_raw(&self) -> &Dxgi::IDXGIAdapter3 {
&self.raw
}
}
struct Event(pub Foundation::HANDLE);
impl Event {
pub fn create(manual_reset: bool, initial_state: bool) -> Result<Self, crate::DeviceError> {