IRenderPipeline¶
-
interface
IRenderPipeline
The interface for the rendering pipeline.
-
void
Render
(IGameContext gameContext, IRenderContext renderContext) Renders the game using the render pipeline.
Parameters: - gameContext (Protogame.IGameContext) – The current game context.
- renderContext (Protogame.IRenderContext) – The current render context.
-
IRenderPass
AddFixedRenderPass
(IRenderPass renderPass) Adds the specified render pass to the render pipeline permanently. This render pass will take effect after the start of the next frame.
Parameters: - renderPass (Protogame.IRenderPass) – The render pass to add.
Returns: The render pass that was given to this function. This return value is for convenience only, so that you may construct and add a render pass in a single statement, while obtaining a reference to it if you need to modify it’s values or call M:Protogame.IRenderPipeline.RemoveFixedRenderPass(Protogame.IRenderPass) later. The render pass is not modified by this function.
-
void
RemoveFixedRenderPass
(IRenderPass renderPass) Removes the specified render pass from the render pipeline.
Parameters: - renderPass (Protogame.IRenderPass) – The render pass to remove.
-
IRenderPass
AppendTransientRenderPass
(IRenderPass renderPass) Append the specified render pass to the render pipeline for this frame only. This is method that allows you to temporarily add additional render passes to a frame.
If all standard (non-post-processing) render passes have finished post-processing has begun and this method is given a standard render pass, it will have no effect.
Render passes that were appended can not be removed with M:Protogame.IRenderPipeline.RemoveFixedRenderPass(Protogame.IRenderPass).
Parameters: - renderPass (Protogame.IRenderPass) – The render pass to add.
Returns: The render pass that was given to this function. This return value is for convenience only, so that you may construct and add a render pass in a single statement, while obtaining a reference to it if you need to modify it’s value. The render pass is not modified by this function.
-
IRenderPass
GetCurrentRenderPass
() Returns the current render pass. Returns null if the code is not currently executing from within M:Protogame.IRenderPipeline.Render(Protogame.IGameContext,Protogame.IRenderContext).
Returns: The current render pass, or null if the render pipeline isn’t rendering.
-
bool
IsFirstRenderPass
() Returns if the current render pass is the first one in the pipeline.
Returns: Whether the current render pass is the first one in the pipeline.
-
void