Skip to content

Commit

Permalink
WIP: fix: avoid mut_void for D3D12 debug layer init.
Browse files Browse the repository at this point in the history
  • Loading branch information
ErichDonGubler committed Sep 20, 2023
1 parent 5cfeea5 commit e4ce009
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions d3d12/src/debug.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ impl crate::D3D12Lib {
*mut *mut winapi::ctypes::c_void,
) -> crate::HRESULT;

let mut debug = Debug::null();
let mut debug = std::ptr::null_mut();
let hr = unsafe {
let func: libloading::Symbol<Fun> = self.lib.get(b"D3D12GetDebugInterface")?;
func(&d3d12sdklayers::ID3D12Debug::uuidof(), debug.mut_void())
func(&d3d12sdklayers::ID3D12Debug::uuidof(), &mut debug)
};

Ok((debug, hr))
Ok((unsafe { Debug::from_raw(dbg!(debug).cast()) }, hr))
}
}

Expand Down

0 comments on commit e4ce009

Please sign in to comment.