Skip to content

Commit

Permalink
- fixed erroneous texture mipmapping in Vulkan render
Browse files Browse the repository at this point in the history
  • Loading branch information
alexey-lysiuk authored and dpjudas committed May 19, 2019
1 parent 04334aa commit bbb75a4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/rendering/vulkan/textures/vk_samplers.cpp
Expand Up @@ -92,7 +92,7 @@ void VkSamplerManager::Create()
builder.setMinFilter(TexFilter[filter].minFilter);
builder.setAddressMode(TexClamp[i].clamp_u, TexClamp[i].clamp_v, VK_SAMPLER_ADDRESS_MODE_REPEAT);
builder.setMipmapMode(TexFilter[filter].mipfilter);
if (TexFilter[filter].mipmapping)
if (i <= CLAMP_XY && TexFilter[filter].mipmapping)
{
builder.setAnisotropy(gl_texture_filter_anisotropic);
builder.setMaxLod(100.0f); // According to the spec this value is clamped so something high makes it usable for all textures.
Expand Down

0 comments on commit bbb75a4

Please sign in to comment.