Xui.GPU.Shaders

Assembly: Xui.Core · C# declarations · Assembly overview

Types

struct FragmentOutput

Standard fragment shader output structure.

public struct FragmentOutput
{
    public Color4 Color;
}

Color4 FragmentOutput.Color

public Color4 Color;

The output color value.

interface IFragmentShader<TInput, TOutput, TBindings>

Fragment shader interface that computes pixel colors.

  • TInput — The fragment input/varyings structure type.

  • TOutput — The fragment output structure type.

  • TBindings — The shader resource bindings type.

public interface IFragmentShader<TInput, TOutput, TBindings> : IShaderStage where TInput : unmanaged where TOutput : unmanaged where TBindings : struct
{
    TOutput Execute(TInput input, in TBindings bindings);
}

TOutput IFragmentShader<TInput, TOutput, TBindings>.Execute(TInput input, in TBindings bindings)

TOutput Execute(TInput input, in TBindings bindings);

Executes the fragment shader for a single fragment.

  • input — The interpolated fragment input data.

  • bindings — The shader resource bindings.

Returns: The computed fragment output.

interface IShaderStage

Base interface for all shader stages. Shader stages are the execution points in the rendering pipeline.

public interface IShaderStage
{
}

interface IVertexShader<TInput, TOutput, TBindings>

Vertex shader interface that transforms vertex input data.

  • TInput — The vertex input structure type.

  • TOutput — The vertex output/varyings structure type.

  • TBindings — The shader resource bindings type.

public interface IVertexShader<TInput, TOutput, TBindings> : IShaderStage where TInput : unmanaged where TOutput : unmanaged where TBindings : struct
{
    TOutput Execute(TInput input, in TBindings bindings);
}

TOutput IVertexShader<TInput, TOutput, TBindings>.Execute(TInput input, in TBindings bindings)

TOutput Execute(TInput input, in TBindings bindings);

Executes the vertex shader for a single vertex.

  • input — The vertex input data.

  • bindings — The shader resource bindings.

Returns: The transformed vertex output.