Show / Hide Table of Contents

Class SurfaceRenderStep

Draws a IScreenSurface object.

Inheritance
object
SurfaceRenderStep
Implements
IRenderStep
IDisposable
IRenderStepTexture
Inherited Members
object.GetType()
object.MemberwiseClone()
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
Namespace: SadConsole.Renderers
Assembly: SadConsole.Host.MonoGame.dll
Syntax
public class SurfaceRenderStep : IRenderStep, IDisposable, IRenderStepTexture

Constructors

SurfaceRenderStep()

Declaration
public SurfaceRenderStep()

Properties

BackingTexture

The cached texture of the drawn surface.

Declaration
public RenderTarget2D? BackingTexture { get; }
Property Value
Type Description
RenderTarget2D

CachedTexture

The texture created by the render step.

Declaration
public ITexture? CachedTexture { get; }
Property Value
Type Description
ITexture

ComposeTint

The color applied when the sprite batch draws this surface on the renderer.

Declaration
public Color ComposeTint { get; set; }
Property Value
Type Description
Color

Name

The name of the render step.

Declaration
public string Name { get; }
Property Value
Type Description
string

SortOrder

Indicates priority related to other steps. Lowest runs first.

Declaration
public uint SortOrder { get; set; }
Property Value
Type Description
uint

Methods

Composing(IRenderer, IScreenSurface)

Called when the renderer needs to redraw the Output texture.

Declaration
public void Composing(IRenderer renderer, IScreenSurface screenObject)
Parameters
Type Name Description
IRenderer renderer

The renderer the render step is using.

IScreenSurface screenObject

The surface associated with the renderer. This may be null.

Dispose()

Declaration
public void Dispose()

Dispose(bool)

Disposes the object.

Declaration
protected void Dispose(bool disposing)
Parameters
Type Name Description
bool disposing

true to indicate this method was called from Dispose().

~SurfaceRenderStep()

Finalizes the object for collection.

Declaration
protected ~SurfaceRenderStep()

Refresh(IRenderer, IScreenSurface, bool, bool)

Called to redraw the render step if needed.

Declaration
public bool Refresh(IRenderer renderer, IScreenSurface screenObject, bool backingTextureChanged, bool isForced)
Parameters
Type Name Description
IRenderer renderer

The renderer the render step is using.

IScreenSurface screenObject

The surface associated with the renderer. This may be null.

bool backingTextureChanged

true to indicate the Output changed; otherwise false.

bool isForced

true when refresh is being forced; otherwise false.

Returns
Type Description
bool

true when the step is going to draw something new and is requesting a Composing(IRenderer, IScreenSurface) step; otherwise false.

Render(IRenderer, IScreenSurface)

Called when building draw calls for the render pipeline.

Declaration
public void Render(IRenderer renderer, IScreenSurface screenObject)
Parameters
Type Name Description
IRenderer renderer

The renderer the render step is using.

IScreenSurface screenObject

The surface associated with the renderer. This may be null.

Reset()

Called when the step should reset any state or texture information.

Declaration
public void Reset()

SetData(object)

Sets an alternative IScreenSurface to render. If null, the surface associated with the parent renderer is drawn.

Declaration
public void SetData(object data)
Parameters
Type Name Description
object data

Implements

IRenderStep
IDisposable
IRenderStepTexture

Extension Methods

ExtensionsSystem.GetDebuggerDisplayValue(object)
In this article

Back to top

Back to top Generated by DocFX