Struct lambda::render::RenderContext
source · pub struct RenderContext { /* private fields */ }
Expand description
Generic Rendering API setup to use the current platforms primary Rendering Backend
Implementations§
source§impl RenderContext
impl RenderContext
sourcepub fn attach_pipeline(&mut self, pipeline: RenderPipeline) -> ResourceId
pub fn attach_pipeline(&mut self, pipeline: RenderPipeline) -> ResourceId
Permanently transfer a render pipeline to the render context in exchange for a resource ID that you can use in render commands.
sourcepub fn attach_render_pass(&mut self, render_pass: RenderPass) -> ResourceId
pub fn attach_render_pass(&mut self, render_pass: RenderPass) -> ResourceId
Permanently transfer a render pipeline to the render context in exchange for a resource ID that you can use in render commands.
pub fn allocate_and_get_frame_buffer(
&mut self,
render_pass: &RenderPass<Backend>
) -> Rc<Framebuffer<Backend>>
sourcepub fn render(&mut self, commands: Vec<RenderCommand>)
pub fn render(&mut self, commands: Vec<RenderCommand>)
Allocates a command buffer and records commands to the GPU. This is the primary entry point for submitting commands to the GPU and where rendering will occur.