diff --git a/librashader-runtime-d3d11/src/filter_pass.rs b/librashader-runtime-d3d11/src/filter_pass.rs index ad19757..92fe036 100644 --- a/librashader-runtime-d3d11/src/filter_pass.rs +++ b/librashader-runtime-d3d11/src/filter_pass.rs @@ -240,15 +240,8 @@ impl FilterPass { } unsafe { - // SAFETY: Niche optimization for Option> - // Assumes that IUnknown is defined as IUnknown(std::ptr::NonNull) - const _: () = assert!( - std::mem::size_of::>() - == std::mem::size_of::() - ); - - ctx.PSSetShaderResources(0, Some(std::mem::transmute(textures.as_ref()))); - ctx.PSSetSamplers(0, Some(std::mem::transmute(samplers.as_ref()))); + ctx.PSSetShaderResources(0, Some(&textures)); + ctx.PSSetSamplers(0, Some(&samplers)); ctx.OMSetRenderTargets(Some(&[Some(output.output.clone())]), None); ctx.RSSetViewports(Some(&[D3D11_VIEWPORT {