Vulkan: Remove image views forced to one mip level
textureSize requires the view to reflect actual mip levels, so
we can't artificially limit the view based on filtering mode.
This CL removes those views.
That unearthed a problem where the VK backend wasn't properly
implementing non-mipmapped filter modes. There is a blurb in
the Vulkan spec about this:
There are no Vulkan filter modes that directly correspond to OpenGL
minification filters of GL_LINEAR or GL_NEAREST, but they can be
emulated using VK_SAMPLER_MIPMAP_MODE_NEAREST, minLod = 0, and
maxLod = 0.25, and using minFilter = VK_FILTER_LINEAR or
minFilter = VK_FILTER_NEAREST, respectively.
So this CL also adds that emulation.
Bug: angleproject:3948
Test: TextureSizeTextureArrayTest.BaseLevelVariesInTextureArray
Test: dEQP-GLES3.functional.shaders.texture_functions.texturesize.*
Change-Id: I81d5c3417e7d9abd0cdd058b935963706024a28f
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/1835937
Reviewed-by: Tim Van Patten <timvp@google.com>
Commit-Queue: Cody Northrop <cnorthrop@google.com>
diff --git a/src/tests/gl_tests/TextureTest.cpp b/src/tests/gl_tests/TextureTest.cpp
index ad68542..6031f04 100644
--- a/src/tests/gl_tests/TextureTest.cpp
+++ b/src/tests/gl_tests/TextureTest.cpp
@@ -5699,7 +5699,7 @@
ES3_OPENGL(),
ES3_OPENGLES(),
ES3_VULKAN());
-ANGLE_INSTANTIATE_TEST(TextureSizeTextureArrayTest, ES3_D3D11(), ES3_OPENGL());
+ANGLE_INSTANTIATE_TEST(TextureSizeTextureArrayTest, ES3_D3D11(), ES3_OPENGL(), ES3_VULKAN());
ANGLE_INSTANTIATE_TEST(SamplerInStructTest,
ES2_D3D11(),
ES2_D3D9(),