Skip to content

Commit

Permalink
Fixed maxLod calculation bug
Browse files Browse the repository at this point in the history
  • Loading branch information
corporateshark committed Oct 22, 2024
1 parent fe57f92 commit 4dbaa86
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lvk/vulkan/VulkanUtils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,7 @@ VkSamplerCreateInfo lvk::samplerStateDescToVkSamplerCreateInfo(const lvk::Sample
.compareEnable = desc.depthCompareEnabled ? VK_TRUE : VK_FALSE,
.compareOp = desc.depthCompareEnabled ? lvk::compareOpToVkCompareOp(desc.depthCompareOp) : VK_COMPARE_OP_ALWAYS,
.minLod = float(desc.mipLodMin),
.maxLod = desc.mipMap == lvk::SamplerMip_Disabled ? 0.0f : float(desc.mipLodMax),
.maxLod = desc.mipMap == lvk::SamplerMip_Disabled ? float(desc.mipLodMin) : float(desc.mipLodMax),
.borderColor = VK_BORDER_COLOR_INT_OPAQUE_BLACK,
.unnormalizedCoordinates = VK_FALSE,
};
Expand Down

0 comments on commit 4dbaa86

Please sign in to comment.