File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
filament/backend/src/vulkan Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -143,6 +143,13 @@ void VulkanExternalImageManager::bindExternallySampledTexture(
143143 // https://registry.khronos.org/vulkan/specs/latest/man/html/VkSamplerCreateInfo.html#VUID-VkSamplerCreateInfo-minFilter-01645
144144 samplerParams.filterMag = SamplerMagFilter::NEAREST;
145145 samplerParams.filterMin = SamplerMinFilter::NEAREST;
146+ // If the sampler has a ycbcrConversion then anisotropic must be disabled and addressModeU,
147+ // addressModeV and addressModeW must be VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE.
148+ // https://docs.vulkan.org/spec/latest/chapters/samplers.html#VUID-VkSamplerCreateInfo-addressModeU-01646
149+ samplerParams.wrapS = SamplerWrapMode::CLAMP_TO_EDGE;
150+ samplerParams.wrapT = SamplerWrapMode::CLAMP_TO_EDGE;
151+ samplerParams.wrapR = SamplerWrapMode::CLAMP_TO_EDGE;
152+ samplerParams.anisotropyLog2 = 0 ;
146153
147154 VkSampler const sampler = mSamplerCache ->getSampler ({
148155 .sampler = samplerParams,
You can’t perform that action at this time.
0 commit comments