Package org.lwjgl.vulkan
Class QCOMImageProcessing
java.lang.Object
org.lwjgl.vulkan.QCOMImageProcessing
GPUs are commonly used to process images for various applications from 3D graphics to UI and from composition to compute applications. Simple scaling and filtering can be done with bilinear filtering, which comes for free during texture sampling. However, as screen sizes get larger and more use cases rely on GPU such as camera and video post-processing needs, there is increasing demand for GPU to support higher order filtering and other advanced image processing.
This extension introduces a new set of SPIR-V built-in functions for image processing. It exposes the following new imaging operations
- The
OpImageSampleWeightedQCOMinstruction takes 3 operands: sampled image, weight image, and texture coordinates. The instruction computes a weighted average of an MxN region of texels in the sampled image, using a set of MxN weights in the weight image. - The
OpImageBoxFilterQCOMinstruction takes 3 operands: sampled image, box size, and texture coordinates. Note that box size specifies a floating-point width and height in texels. The instruction computes a weighted average of all texels in the sampled image that are covered (either partially or fully) by a box with the specified size and centered at the specified texture coordinates. - The
OpImageBlockMatchSADQCOMandOpImageBlockMatchSSDQCOMinstructions each takes 5 operands: target image, target coordinates, reference image, reference coordinates, and block size. Each instruction computes an error metric, that describes whether a block of texels in the target image matches a corresponding block of texels in the reference image. The error metric is computed per-component.OpImageBlockMatchSADQCOMcomputes "Sum Of Absolute Difference" andOpImageBlockMatchSSDQCOMcomputes "Sum of Squared Difference".
Each of the image processing instructions operate only on 2D images. The instructions do not-support sampling of mipmap, multi-plane, multi-layer, multi-sampled, or depth/stencil images. The instructions can be used in any shader stage.
Implementations of this extension should support these operations natively at the HW instruction level, offering potential performance gains as well as ease of development.
- Name String
VK_QCOM_image_processing- Extension Type
- Device extension
- Registered Extension Number
- 441
- Revision
- 1
- Extension and Version Dependencies
VK_KHR_format_feature_flags2or Version 1.3- API Interactions
- Interacts with VK_VERSION_1_3
- Interacts with VK_KHR_format_feature_flags2
- SPIR-V Dependencies
- Contact
- Matthew Netsch mnetsch
- Extension Proposal
- VK_QCOM_image_processing
Other Extension Metadata
- Last Modified Date
- 2022-07-08
- Interactions and External Dependencies
- This extension provides API support for
GL_QCOM_image_processing
- This extension provides API support for
- Contributors
- Jeff Leger, Qualcomm Technologies, Inc.
- Ruihao Zhang, Qualcomm Technologies, Inc.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intExtendsVkDescriptorType.static final intExtendsVkDescriptorType.static final longExtendsVkFormatFeatureFlagBits2.static final longExtendsVkFormatFeatureFlagBits2.static final longExtendsVkFormatFeatureFlagBits2.static final longExtendsVkFormatFeatureFlagBits2.static final intExtendsVkImageUsageFlagBits.static final intExtendsVkImageUsageFlagBits.static final StringThe extension name.static final intThe extension specification version.static final intExtendsVkSamplerCreateFlagBits.static final intExtendsVkStructureType.static final intExtendsVkStructureType.static final intExtendsVkStructureType. -
Method Summary
-
Field Details
-
VK_QCOM_IMAGE_PROCESSING_SPEC_VERSION
public static final int VK_QCOM_IMAGE_PROCESSING_SPEC_VERSIONThe extension specification version.- See Also:
-
VK_QCOM_IMAGE_PROCESSING_EXTENSION_NAME
The extension name.- See Also:
-
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGE_PROCESSING_FEATURES_QCOM
public static final int VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGE_PROCESSING_FEATURES_QCOMExtendsVkStructureType.Enum values:
- See Also:
-
VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGE_PROCESSING_PROPERTIES_QCOM
public static final int VK_STRUCTURE_TYPE_PHYSICAL_DEVICE_IMAGE_PROCESSING_PROPERTIES_QCOMExtendsVkStructureType.Enum values:
- See Also:
-
VK_STRUCTURE_TYPE_IMAGE_VIEW_SAMPLE_WEIGHT_CREATE_INFO_QCOM
public static final int VK_STRUCTURE_TYPE_IMAGE_VIEW_SAMPLE_WEIGHT_CREATE_INFO_QCOMExtendsVkStructureType.Enum values:
- See Also:
-
VK_SAMPLER_CREATE_IMAGE_PROCESSING_BIT_QCOM
public static final int VK_SAMPLER_CREATE_IMAGE_PROCESSING_BIT_QCOMExtendsVkSamplerCreateFlagBits.- See Also:
-
VK_IMAGE_USAGE_SAMPLE_WEIGHT_BIT_QCOM
public static final int VK_IMAGE_USAGE_SAMPLE_WEIGHT_BIT_QCOMExtendsVkImageUsageFlagBits.Enum values:
- See Also:
-
VK_IMAGE_USAGE_SAMPLE_BLOCK_MATCH_BIT_QCOM
public static final int VK_IMAGE_USAGE_SAMPLE_BLOCK_MATCH_BIT_QCOMExtendsVkImageUsageFlagBits.Enum values:
- See Also:
-
VK_DESCRIPTOR_TYPE_SAMPLE_WEIGHT_IMAGE_QCOM
public static final int VK_DESCRIPTOR_TYPE_SAMPLE_WEIGHT_IMAGE_QCOMExtendsVkDescriptorType.Enum values:
- See Also:
-
VK_DESCRIPTOR_TYPE_BLOCK_MATCH_IMAGE_QCOM
public static final int VK_DESCRIPTOR_TYPE_BLOCK_MATCH_IMAGE_QCOMExtendsVkDescriptorType.Enum values:
- See Also:
-
VK_FORMAT_FEATURE_2_WEIGHT_IMAGE_BIT_QCOM
public static final long VK_FORMAT_FEATURE_2_WEIGHT_IMAGE_BIT_QCOMExtendsVkFormatFeatureFlagBits2.Enum values:
- See Also:
-
VK_FORMAT_FEATURE_2_WEIGHT_SAMPLED_IMAGE_BIT_QCOM
public static final long VK_FORMAT_FEATURE_2_WEIGHT_SAMPLED_IMAGE_BIT_QCOMExtendsVkFormatFeatureFlagBits2.Enum values:
- See Also:
-
VK_FORMAT_FEATURE_2_BLOCK_MATCHING_BIT_QCOM
public static final long VK_FORMAT_FEATURE_2_BLOCK_MATCHING_BIT_QCOMExtendsVkFormatFeatureFlagBits2.Enum values:
- See Also:
-
VK_FORMAT_FEATURE_2_BOX_FILTER_SAMPLED_BIT_QCOM
public static final long VK_FORMAT_FEATURE_2_BOX_FILTER_SAMPLED_BIT_QCOMExtendsVkFormatFeatureFlagBits2.Enum values:
- See Also:
-