libdonut
2.3.2
Application framework for cross-platform game development in C++20
|
Configuration options for a Texture and its assocated sampler. More...
#include <donut/graphics/Texture.hpp>
Public Attributes | |
bool | repeat = true |
Treat the texture as repeating when sampling it outside of the 0-1 texture coordinate range. More... | |
bool | useLinearFiltering = true |
Use bilinear filtering rather than nearest-neighbor interpolation when sampling the texture at coordinates that do not correspond exactly to one texel. More... | |
bool | useMipmap = true |
Generate a mipmap of different levels of detail for the texture and use it when sampling the texture at a smaller-than-1:1 scale. More... | |
Configuration options for a Texture and its assocated sampler.
bool donut::graphics::TextureOptions::repeat = true |
Treat the texture as repeating when sampling it outside of the 0-1 texture coordinate range.
Disable to clamp to the edge of the texture instead.
bool donut::graphics::TextureOptions::useLinearFiltering = true |
Use bilinear filtering rather than nearest-neighbor interpolation when sampling the texture at coordinates that do not correspond exactly to one texel.
This results in a smoother appearance compared to the regular blocky nearest-neighbor filtering.
bool donut::graphics::TextureOptions::useMipmap = true |
Generate a mipmap of different levels of detail for the texture and use it when sampling the texture at a smaller-than-1:1 scale.
This 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.