Stride

OPEN / CLOSE
  • Features
  • Blog
  • Documentation
  • Community
(icon) Download

  • Discord
  • Facebook
  • Twitter
  • YouTube

LANGUAGE

OPEN / CLOSE
  • English
  • 日本語
    Show / Hide Table of Contents

    GraphicsDeviceExtensions Class

    Namespace: Stride.Graphics
    Assembly: Stride.Graphics.dll

    Extensions for the GraphicsDevice

    System.Object → GraphicsDeviceExtensions
    Derived from GraphicsDeviceExtensions:

    public static class GraphicsDeviceExtensions
    Name Description
    Methods
    DrawQuad(CommandList)

    Draws a full screen quad. An Effect must be applied before calling this method.

    DrawQuad(GraphicsContext, EffectInstance)

    Draws a fullscreen quad with the specified effect and parameters.

    DrawTexture(GraphicsContext, Texture, Color4, Nullable<BlendStateDescription>)

    Draws a fullscreen texture using a LinearClamp sampler and the texture color multiplied by a custom color. See to learn how to use it.

    DrawTexture(GraphicsContext, Texture, SamplerState, Color4, Nullable<BlendStateDescription>)

    Draws a fullscreen texture using the specified sampler and the texture color multiplied by a custom color. See to learn how to use it.

    DrawTexture(GraphicsContext, Texture, SamplerState, Nullable<BlendStateDescription>)

    Draws a fullscreen texture using the specified sampler. See to learn how to use it.

    DrawTexture(GraphicsContext, Texture, Nullable<BlendStateDescription>)

    Draws a fullscreen texture using a LinearClamp sampler. See to learn how to use it.

    GetSharedWhiteTexture(GraphicsDevice)
    | Improve this Doc View Source

    Methods


    DrawQuad(CommandList)

    Draws a full screen quad. An Effect must be applied before calling this method.

    public static void DrawQuad(this CommandList commandList)
    Parameters
    Type Name Description
    CommandList commandList

    DrawQuad(GraphicsContext, EffectInstance)

    Draws a fullscreen quad with the specified effect and parameters.

    public static void DrawQuad(this GraphicsContext graphicsContext, EffectInstance effectInstance)
    Parameters
    Type Name Description
    GraphicsContext graphicsContext
    EffectInstance effectInstance

    The effect instance.

    Exceptions
    Type Condition
    System.ArgumentNullException

    effect


    DrawTexture(GraphicsContext, Texture, Color4, Nullable<BlendStateDescription>)

    Draws a fullscreen texture using a LinearClamp sampler and the texture color multiplied by a custom color. See to learn how to use it.

    public static void DrawTexture(this GraphicsContext graphicsContext, Texture texture, Color4 color, BlendStateDescription? blendState = null)
    Parameters
    Type Name Description
    GraphicsContext graphicsContext
    Texture texture

    The texture. Expecting an instance of Texture.

    Color4 color

    The color.

    System.Nullable<BlendStateDescription> blendState

    DrawTexture(GraphicsContext, Texture, SamplerState, Color4, Nullable<BlendStateDescription>)

    Draws a fullscreen texture using the specified sampler and the texture color multiplied by a custom color. See to learn how to use it.

    public static void DrawTexture(this GraphicsContext graphicsContext, Texture texture, SamplerState sampler, Color4 color, BlendStateDescription? blendState = null)
    Parameters
    Type Name Description
    GraphicsContext graphicsContext
    Texture texture

    The texture. Expecting an instance of Texture.

    SamplerState sampler

    The sampler.

    Color4 color

    The color.

    System.Nullable<BlendStateDescription> blendState

    DrawTexture(GraphicsContext, Texture, SamplerState, Nullable<BlendStateDescription>)

    Draws a fullscreen texture using the specified sampler. See to learn how to use it.

    public static void DrawTexture(this GraphicsContext graphicsContext, Texture texture, SamplerState sampler, BlendStateDescription? blendState = null)
    Parameters
    Type Name Description
    GraphicsContext graphicsContext
    Texture texture

    The texture. Expecting an instance of Texture.

    SamplerState sampler

    The sampler.

    System.Nullable<BlendStateDescription> blendState

    DrawTexture(GraphicsContext, Texture, Nullable<BlendStateDescription>)

    Draws a fullscreen texture using a LinearClamp sampler. See to learn how to use it.

    public static void DrawTexture(this GraphicsContext graphicsContext, Texture texture, BlendStateDescription? blendState = null)
    Parameters
    Type Name Description
    GraphicsContext graphicsContext
    Texture texture

    The texture. Expecting an instance of Texture.

    System.Nullable<BlendStateDescription> blendState

    GetSharedWhiteTexture(GraphicsDevice)

    public static Texture GetSharedWhiteTexture(this GraphicsDevice device)
    Parameters
    Type Name Description
    GraphicsDevice device
    Returns
    Type Description
    Texture

    • Improve this Doc
    • View Source
    In This Article

    Back to top

    Copyright © 2019-2021 .NET Foundation and Contributors
    Supported by the .NET Foundation