According to section `32.3.3. Required Format Support` of the Vulkan specs, the `VK_FORMAT_D32_SFLOAT` and `VK_FORMAT_D16_UNORM` formats must support the `VK_FORMAT_FEATURE_SAMPLED_IMAGE_BIT` usage. However the driver doesn't report this usage on my Ivy Bridge (Intel Core i5-3210M). More generally the driver doesn't report any depth/stencil format that supports `SAMPLED_IMAGE_BIT`, which makes it a bit limiting for shadowmaps for example.
Patch on the list: https://patchwork.freedesktop.org/patch/170291/
Fixed by the following commit in master: commit 06d3115bb97740a4c8f36c645944a8bd0bde3f68 Author: Jason Ekstrand <jason.ekstrand@intel.com> Date: Thu Aug 3 19:58:24 2017 -0700 anv/formats: Allow sampling on depth-only formats on gen7 We can't sample from depth-stencil formats but on gen7 but we can sample from depth-only formats. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=102024 Reviewed-by: Juan A. Suarez Romero <jasuarez@igalia.com> Cc: mesa-stable@lists.freedesktop.org
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.