|
GREM 3.12.0
Game/Rendering Engine Modules for C++
|
Configuration options for the sampler of a Texture. More...
#include <GREM/graphics/Texture.hpp>
Public Member Functions | |
| constexpr bool | operator== (const TextureSamplerOptions &other) const =default |
| Compare this configuration to another for equality. | |
Public Attributes | |
| TextureFilter | minificationFilter = TextureFilter::LINEAR |
| Filtering mode to use when the texture is rendered smaller than its original size. | |
| TextureFilter | magnificationFilter = TextureFilter::LINEAR |
| Filtering mode to use when the texture is rendered larger than its original size. | |
| TextureMipmapMode | mipmapMode = TextureMipmapMode::LINEAR |
| Mipmap mode to use when determining which mip detail level to sample depending on the texture's size on screen. | |
| TextureWrappingMode | horizontalWrappingMode = TextureWrappingMode::REPEAT |
| How to address the texture when the horizontal component of the texture coordinates is outside the 0-1 range. | |
| TextureWrappingMode | verticalWrappingMode = TextureWrappingMode::REPEAT |
| How to address the texture when the vertical component of the texture coordinates is outside the 0-1 range. | |
| float | maxAnisotropy = 16.0f |
| Maximum level of anisotropic filtering to use. | |
| Optional< TextureDepthComparisonMode > | depthComparisonMode {} |
| Depth comparison mode to use when sampling the texture. | |
Static Public Attributes | |
| static const TextureSamplerOptions | UNFILTERED |
| A texture sampler configuration that ensures that the texture is sampled as directly as possible, without filtering. | |
Configuration options for the sampler of a Texture.
|
nodiscardconstexprdefault |
Compare this configuration to another for equality.
| other | the configuration to compare this one to. |
|
inlinestaticconstexpr |
A texture sampler configuration that ensures that the texture is sampled as directly as possible, without filtering.
| TextureFilter grem::graphics::TextureSamplerOptions::minificationFilter = TextureFilter::LINEAR |
Filtering mode to use when the texture is rendered smaller than its original size.
| TextureFilter grem::graphics::TextureSamplerOptions::magnificationFilter = TextureFilter::LINEAR |
Filtering mode to use when the texture is rendered larger than its original size.
| TextureMipmapMode grem::graphics::TextureSamplerOptions::mipmapMode = TextureMipmapMode::LINEAR |
Mipmap mode to use when determining which mip detail level to sample depending on the texture's size on screen.
Mipmapping results in fewer aliasing artifacts when rendering downscaled textures, such as those on distant 3D objects. It can also improve rendering performance slightly in those cases, at the cost of some extra texture memory.
Note that the texture must have mipmaps generated or uploaded to it in order for this option to have an effect.
| TextureWrappingMode grem::graphics::TextureSamplerOptions::horizontalWrappingMode = TextureWrappingMode::REPEAT |
How to address the texture when the horizontal component of the texture coordinates is outside the 0-1 range.
| TextureWrappingMode grem::graphics::TextureSamplerOptions::verticalWrappingMode = TextureWrappingMode::REPEAT |
How to address the texture when the vertical component of the texture coordinates is outside the 0-1 range.
| float grem::graphics::TextureSamplerOptions::maxAnisotropy = 16.0f |
Maximum level of anisotropic filtering to use.
Set to 1 or lower to disable anisotropic filtering.
| Optional<TextureDepthComparisonMode> grem::graphics::TextureSamplerOptions::depthComparisonMode {} |
Depth comparison mode to use when sampling the texture.
If set, the texture must have a depth component.