Struct SamplerStateDescription
Describes a sampler state.
[DataContract]
public struct SamplerStateDescription : IEquatable<SamplerStateDescription>
- Implements
- Inherited Members
Constructors
SamplerStateDescription(TextureFilter, TextureAddressMode)
Initializes a new instance of the SamplerStateDescription class.
public SamplerStateDescription(TextureFilter filter, TextureAddressMode addressMode)
Parameters
filter
TextureFilterThe filter.
addressMode
TextureAddressModeThe address mode.
Fields
AddressU
Gets or sets method to use for resolving a u texture coordinate that is outside the 0 to 1 range (see TextureAddressMode).
public TextureAddressMode AddressU
Field Value
AddressV
Gets or sets method to use for resolving a v texture coordinate that is outside the 0 to 1 range.
public TextureAddressMode AddressV
Field Value
AddressW
Gets or sets method to use for resolving a w texture coordinate that is outside the 0 to 1 range.
public TextureAddressMode AddressW
Field Value
BorderColor
Gets or sets border color to use if Border is specified for AddressU, AddressV, or AddressW. Range must be between 0.0 and 1.0 inclusive.
public Color4 BorderColor
Field Value
CompareFunction
Gets or sets a function that compares sampled data against existing sampled data. The function options are listed in CompareFunction.
public CompareFunction CompareFunction
Field Value
Filter
Gets or sets filtering method to use when sampling a texture (see TextureFilter).
public TextureFilter Filter
Field Value
MaxAnisotropy
Gets or sets clamping value used if Anisotropy or ComparisonAnisotropy is specified in Filter. Valid values are between 1 and 16.
public int MaxAnisotropy
Field Value
MaxMipLevel
Gets or sets upper end of the mipmap range to clamp access to, where 0 is the largest and most detailed mipmap level and any level higher than that is less detailed. This value must be greater than or equal to MinLOD. To have no upper limit on LOD set this to a large value such as D3D11_FLOAT32_MAX.
public float MaxMipLevel
Field Value
MinMipLevel
Gets or sets lower end of the mipmap range to clamp access to, where 0 is the largest and most detailed mipmap level and any level higher than that is less detailed.
public float MinMipLevel
Field Value
MipMapLevelOfDetailBias
Gets or sets offset from the calculated mipmap level. For example, if Direct3D calculates that a texture should be sampled at mipmap level 3 and MipLODBias is 2, then the texture will be sampled at mipmap level 5.
public float MipMapLevelOfDetailBias
Field Value
Properties
Default
Gets default values for this instance.
public static SamplerStateDescription Default { get; }
Property Value
Methods
Equals(SamplerStateDescription)
Indicates whether the current object is equal to another object of the same type.
public bool Equals(SamplerStateDescription other)
Parameters
other
SamplerStateDescriptionAn object to compare with this object.
Returns
Equals(object)
Indicates whether this instance and a specified object are equal.
public override bool Equals(object obj)
Parameters
obj
objectThe object to compare with the current instance.
Returns
- bool
true if
obj
and this instance are the same type and represent the same value; otherwise, false.
GetHashCode()
Returns the hash code for this instance.
public override int GetHashCode()
Returns
- int
A 32-bit signed integer that is the hash code for this instance.