From dcb9f65b25e59edb21c9c3cac7b32d70ca19eb72 Mon Sep 17 00:00:00 2001 From: omniscient <17525998+omnisci3nce@users.noreply.github.com> Date: Sat, 10 Aug 2024 02:59:59 +1000 Subject: wip --- bindgen/rust/src/ral.rs | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'bindgen/rust/src/ral.rs') diff --git a/bindgen/rust/src/ral.rs b/bindgen/rust/src/ral.rs index 4943f9e..078121b 100644 --- a/bindgen/rust/src/ral.rs +++ b/bindgen/rust/src/ral.rs @@ -5,10 +5,11 @@ use std::ffi::c_void; use celeritas_sys::{ BufferHandle, GPU_CmdEncoder, GPU_CmdEncoder_BeginRender, GPU_CmdEncoder_EndRender, GPU_EncodeBindShaderData, GPU_GetDefaultEncoder, GPU_GetDefaultRenderpass, - GPU_GraphicsPipeline_Create, GraphicsPipelineDesc, ShaderBindingKind_BINDING_BYTES, - ShaderBinding__bindgen_ty_1, ShaderBinding__bindgen_ty_1__bindgen_ty_1, - ShaderVisibility_VISIBILITY_COMPUTE, ShaderVisibility_VISIBILITY_FRAGMENT, - ShaderVisibility_VISIBILITY_VERTEX, TextureHandle, MAX_SHADER_DATA_LAYOUTS, + GPU_GraphicsPipeline_Create, GPU_Pipeline, GraphicsPipelineDesc, + ShaderBindingKind_BINDING_BYTES, ShaderBinding__bindgen_ty_1, + ShaderBinding__bindgen_ty_1__bindgen_ty_1, ShaderVisibility_VISIBILITY_COMPUTE, + ShaderVisibility_VISIBILITY_FRAGMENT, ShaderVisibility_VISIBILITY_VERTEX, TextureHandle, + MAX_SHADER_DATA_LAYOUTS, }; use thiserror::Error; @@ -106,6 +107,12 @@ impl PipelineBuilder { } } +impl Pipeline { + pub fn raw_ptr(&self) -> *mut GPU_Pipeline { + self.0 + } +} + /// pub trait ShaderData { /// -- cgit v1.2.3-70-g09d2