radv: update VK_EXT_sampler_filter_minmax for Vulkan 1.2

Promoted to Vulkan 1.2 with the EXT suffix omitted.

Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
This commit is contained in:
Samuel Pitoiset 2019-10-15 08:58:55 +02:00 committed by Jason Ekstrand
parent 65e215e6f3
commit efdf9d8969
2 changed files with 9 additions and 9 deletions

View File

@ -1437,9 +1437,9 @@ void radv_GetPhysicalDeviceProperties2(
properties->maxMemoryAllocationSize = RADV_MAX_MEMORY_ALLOCATION_SIZE;
break;
}
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SAMPLER_FILTER_MINMAX_PROPERTIES_EXT: {
VkPhysicalDeviceSamplerFilterMinmaxPropertiesEXT *properties =
(VkPhysicalDeviceSamplerFilterMinmaxPropertiesEXT *)ext;
case VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_SAMPLER_FILTER_MINMAX_PROPERTIES: {
VkPhysicalDeviceSamplerFilterMinmaxProperties *properties =
(VkPhysicalDeviceSamplerFilterMinmaxProperties *)ext;
/* GFX6-8 only support single channel min/max filter. */
properties->filterMinmaxImageComponentMapping = pdevice->rad_info.chip_class >= GFX9;
properties->filterMinmaxSingleComponentFormats = true;
@ -6661,7 +6661,7 @@ radv_tex_aniso_filter(unsigned filter)
}
static unsigned
radv_tex_filter_mode(VkSamplerReductionModeEXT mode)
radv_tex_filter_mode(VkSamplerReductionMode mode)
{
switch (mode) {
case VK_SAMPLER_REDUCTION_MODE_WEIGHTED_AVERAGE_EXT:
@ -6702,9 +6702,9 @@ radv_init_sampler(struct radv_device *device,
unsigned filter_mode = V_008F30_SQ_IMG_FILTER_MODE_BLEND;
unsigned depth_compare_func = V_008F30_SQ_TEX_DEPTH_COMPARE_NEVER;
const struct VkSamplerReductionModeCreateInfoEXT *sampler_reduction =
const struct VkSamplerReductionModeCreateInfo *sampler_reduction =
vk_find_struct_const(pCreateInfo->pNext,
SAMPLER_REDUCTION_MODE_CREATE_INFO_EXT);
SAMPLER_REDUCTION_MODE_CREATE_INFO);
if (sampler_reduction)
filter_mode = radv_tex_filter_mode(sampler_reduction->reductionMode);

View File

@ -595,7 +595,7 @@ static bool radv_is_filter_minmax_format_supported(VkFormat format)
/* From the Vulkan spec 1.1.71:
*
* "The following formats must support the
* VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_MINMAX_BIT_EXT feature with
* VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_MINMAX_BIT feature with
* VK_IMAGE_TILING_OPTIMAL, if they support
* VK_FORMAT_FEATURE_SAMPLED_IMAGE_BIT."
*/
@ -694,7 +694,7 @@ radv_physical_device_get_format_properties(struct radv_physical_device *physical
VK_FORMAT_FEATURE_TRANSFER_DST_BIT;
if (radv_is_filter_minmax_format_supported(format))
tiled |= VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_MINMAX_BIT_EXT;
tiled |= VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_MINMAX_BIT;
/* Don't support blitting surfaces with depth/stencil. */
if (vk_format_is_depth(format) && vk_format_is_stencil(format))
@ -712,7 +712,7 @@ radv_physical_device_get_format_properties(struct radv_physical_device *physical
VK_FORMAT_FEATURE_BLIT_SRC_BIT;
if (radv_is_filter_minmax_format_supported(format))
tiled |= VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_MINMAX_BIT_EXT;
tiled |= VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_MINMAX_BIT;
if (linear_sampling) {
linear |= VK_FORMAT_FEATURE_SAMPLED_IMAGE_FILTER_LINEAR_BIT;