1#version 450 2#extension GL_QCOM_image_processing : require 3 4precision highp float; 5 6// fragment shader inputs and outputs 7layout (location = 0) in vec4 v_texcoord; 8 9layout (location = 0) out vec4 fragColor; 10 11// fragment shader resources 12layout(set = 0, binding = 0) uniform texture2DArray tex2DArray_weights; 13layout(set = 0, binding = 1) uniform texture2D tex2D_src1; 14layout(set = 0, binding = 2) uniform texture2D tex2D_src2; 15layout(set = 0, binding = 3) uniform sampler samp; 16layout(set = 0, binding = 4) uniform sampler2D tex_samp; 17layout(set = 0, binding = 5) uniform sampler2DArray tex_samp_array; 18 19void main() 20{ 21 22 fragColor = textureWeightedQCOM( 23 sampler2D(tex2D_src1, samp), // source texture 24 v_texcoord.xy, // tex coords 25 sampler2DArray(tex2DArray_weights, samp)); // weight texture 26 fragColor = textureWeightedQCOM( 27 tex_samp, // combined source texture 28 v_texcoord.xy, // tex coords 29 tex_samp_array); // combined weight texture 30 31} 32 33