Table of Contents

Class MgfxSamplerInfo

Namespace
ShadowDusk.Core
Assembly
ShadowDusk.Core.dll

One entry in a shader's sampler table, as MonoGame's Shader reader expects it. Name must match the sampler uniform's name in the emitted GLSL (e.g. ps_s0) so MonoGame's GL backend can bind it. Parameter indexes the texture parameter in the effect's global parameter table. State carries the baked sampler_state { MinFilter = …; AddressU = …; } members (Phase 43, F9); when null the record is written with hasState = 0 and MonoGame uses GraphicsDevice.SamplerStates instead.

public sealed record MgfxSamplerInfo : IEquatable<MgfxSamplerInfo>
Inheritance
MgfxSamplerInfo
Implements
Inherited Members

Constructors

MgfxSamplerInfo(byte, byte, byte, string, int, MgfxSamplerStateInfo?)

One entry in a shader's sampler table, as MonoGame's Shader reader expects it. Name must match the sampler uniform's name in the emitted GLSL (e.g. ps_s0) so MonoGame's GL backend can bind it. Parameter indexes the texture parameter in the effect's global parameter table. State carries the baked sampler_state { MinFilter = …; AddressU = …; } members (Phase 43, F9); when null the record is written with hasState = 0 and MonoGame uses GraphicsDevice.SamplerStates instead.

public MgfxSamplerInfo(byte Type, byte TextureSlot, byte SamplerSlot, string Name, int Parameter, MgfxSamplerStateInfo? State = null)

Parameters

Type byte
TextureSlot byte
SamplerSlot byte
Name string
Parameter int
State MgfxSamplerStateInfo

Properties

Name

public string Name { get; init; }

Property Value

string

Parameter

public int Parameter { get; init; }

Property Value

int

SamplerSlot

public byte SamplerSlot { get; init; }

Property Value

byte

State

public MgfxSamplerStateInfo? State { get; init; }

Property Value

MgfxSamplerStateInfo

TextureSlot

public byte TextureSlot { get; init; }

Property Value

byte

Type

public byte Type { get; init; }

Property Value

byte