2022-09-22 22:59:16 +00:00
|
|
|
builtins/gen/var/textureSampleLevel/979816.wgsl:29:24 warning: use of deprecated builtin
|
|
|
|
var res: vec4<f32> = textureSampleLevel(arg_0, arg_1, arg_2);
|
|
|
|
^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2022-06-02 14:36:10 +00:00
|
|
|
; SPIR-V
|
|
|
|
; Version: 1.3
|
|
|
|
; Generator: Google Tint Compiler; 0
|
2022-11-04 17:06:03 +00:00
|
|
|
; Bound: 148
|
2022-06-02 14:36:10 +00:00
|
|
|
; Schema: 0
|
|
|
|
OpCapability Shader
|
2022-09-02 19:19:10 +00:00
|
|
|
%31 = OpExtInstImport "GLSL.std.450"
|
2022-06-02 14:36:10 +00:00
|
|
|
OpMemoryModel Logical GLSL450
|
|
|
|
OpEntryPoint Vertex %vertex_main "vertex_main" %value %vertex_point_size
|
|
|
|
OpEntryPoint Fragment %fragment_main "fragment_main"
|
|
|
|
OpEntryPoint GLCompute %compute_main "compute_main"
|
|
|
|
OpExecutionMode %fragment_main OriginUpperLeft
|
|
|
|
OpExecutionMode %compute_main LocalSize 1 1 1
|
|
|
|
OpName %value "value"
|
|
|
|
OpName %vertex_point_size "vertex_point_size"
|
|
|
|
OpName %ext_tex_plane_1 "ext_tex_plane_1"
|
2022-09-02 19:19:10 +00:00
|
|
|
OpName %ext_tex_params_block "ext_tex_params_block"
|
|
|
|
OpMemberName %ext_tex_params_block 0 "inner"
|
2022-06-02 14:36:10 +00:00
|
|
|
OpName %ExternalTextureParams "ExternalTextureParams"
|
|
|
|
OpMemberName %ExternalTextureParams 0 "numPlanes"
|
2022-06-22 03:14:26 +00:00
|
|
|
OpMemberName %ExternalTextureParams 1 "doYuvToRgbConversionOnly"
|
|
|
|
OpMemberName %ExternalTextureParams 2 "yuvToRgbConversionMatrix"
|
|
|
|
OpMemberName %ExternalTextureParams 3 "gammaDecodeParams"
|
2022-06-02 14:36:10 +00:00
|
|
|
OpName %GammaTransferParams "GammaTransferParams"
|
|
|
|
OpMemberName %GammaTransferParams 0 "G"
|
|
|
|
OpMemberName %GammaTransferParams 1 "A"
|
|
|
|
OpMemberName %GammaTransferParams 2 "B"
|
|
|
|
OpMemberName %GammaTransferParams 3 "C"
|
|
|
|
OpMemberName %GammaTransferParams 4 "D"
|
|
|
|
OpMemberName %GammaTransferParams 5 "E"
|
|
|
|
OpMemberName %GammaTransferParams 6 "F"
|
|
|
|
OpMemberName %GammaTransferParams 7 "padding"
|
2022-06-22 03:14:26 +00:00
|
|
|
OpMemberName %ExternalTextureParams 4 "gammaEncodeParams"
|
|
|
|
OpMemberName %ExternalTextureParams 5 "gamutConversionMatrix"
|
2022-06-02 14:36:10 +00:00
|
|
|
OpName %ext_tex_params "ext_tex_params"
|
|
|
|
OpName %arg_0 "arg_0"
|
|
|
|
OpName %arg_1 "arg_1"
|
|
|
|
OpName %gammaCorrection "gammaCorrection"
|
|
|
|
OpName %v "v"
|
|
|
|
OpName %params "params"
|
|
|
|
OpName %textureSampleExternal "textureSampleExternal"
|
|
|
|
OpName %plane0 "plane0"
|
|
|
|
OpName %plane1 "plane1"
|
|
|
|
OpName %smp "smp"
|
|
|
|
OpName %coord "coord"
|
|
|
|
OpName %params_0 "params"
|
|
|
|
OpName %color "color"
|
|
|
|
OpName %textureSampleLevel_979816 "textureSampleLevel_979816"
|
|
|
|
OpName %arg_2 "arg_2"
|
|
|
|
OpName %res "res"
|
|
|
|
OpName %vertex_main_inner "vertex_main_inner"
|
|
|
|
OpName %vertex_main "vertex_main"
|
|
|
|
OpName %fragment_main "fragment_main"
|
|
|
|
OpName %compute_main "compute_main"
|
|
|
|
OpDecorate %value BuiltIn Position
|
|
|
|
OpDecorate %vertex_point_size BuiltIn PointSize
|
|
|
|
OpDecorate %ext_tex_plane_1 DescriptorSet 1
|
|
|
|
OpDecorate %ext_tex_plane_1 Binding 2
|
2022-09-02 19:19:10 +00:00
|
|
|
OpDecorate %ext_tex_params_block Block
|
|
|
|
OpMemberDecorate %ext_tex_params_block 0 Offset 0
|
2022-06-02 14:36:10 +00:00
|
|
|
OpMemberDecorate %ExternalTextureParams 0 Offset 0
|
2022-06-22 03:14:26 +00:00
|
|
|
OpMemberDecorate %ExternalTextureParams 1 Offset 4
|
|
|
|
OpMemberDecorate %ExternalTextureParams 2 Offset 16
|
|
|
|
OpMemberDecorate %ExternalTextureParams 2 ColMajor
|
|
|
|
OpMemberDecorate %ExternalTextureParams 2 MatrixStride 16
|
|
|
|
OpMemberDecorate %ExternalTextureParams 3 Offset 64
|
2022-06-02 14:36:10 +00:00
|
|
|
OpMemberDecorate %GammaTransferParams 0 Offset 0
|
|
|
|
OpMemberDecorate %GammaTransferParams 1 Offset 4
|
|
|
|
OpMemberDecorate %GammaTransferParams 2 Offset 8
|
|
|
|
OpMemberDecorate %GammaTransferParams 3 Offset 12
|
|
|
|
OpMemberDecorate %GammaTransferParams 4 Offset 16
|
|
|
|
OpMemberDecorate %GammaTransferParams 5 Offset 20
|
|
|
|
OpMemberDecorate %GammaTransferParams 6 Offset 24
|
|
|
|
OpMemberDecorate %GammaTransferParams 7 Offset 28
|
2022-06-22 03:14:26 +00:00
|
|
|
OpMemberDecorate %ExternalTextureParams 4 Offset 96
|
|
|
|
OpMemberDecorate %ExternalTextureParams 5 Offset 128
|
|
|
|
OpMemberDecorate %ExternalTextureParams 5 ColMajor
|
|
|
|
OpMemberDecorate %ExternalTextureParams 5 MatrixStride 16
|
2022-06-02 14:36:10 +00:00
|
|
|
OpDecorate %ext_tex_params NonWritable
|
|
|
|
OpDecorate %ext_tex_params DescriptorSet 1
|
|
|
|
OpDecorate %ext_tex_params Binding 3
|
|
|
|
OpDecorate %arg_0 DescriptorSet 1
|
|
|
|
OpDecorate %arg_0 Binding 0
|
|
|
|
OpDecorate %arg_1 DescriptorSet 1
|
|
|
|
OpDecorate %arg_1 Binding 1
|
|
|
|
%float = OpTypeFloat 32
|
|
|
|
%v4float = OpTypeVector %float 4
|
|
|
|
%_ptr_Output_v4float = OpTypePointer Output %v4float
|
|
|
|
%5 = OpConstantNull %v4float
|
|
|
|
%value = OpVariable %_ptr_Output_v4float Output %5
|
|
|
|
%_ptr_Output_float = OpTypePointer Output %float
|
|
|
|
%8 = OpConstantNull %float
|
|
|
|
%vertex_point_size = OpVariable %_ptr_Output_float Output %8
|
|
|
|
%11 = OpTypeImage %float 2D 0 0 0 1 Unknown
|
|
|
|
%_ptr_UniformConstant_11 = OpTypePointer UniformConstant %11
|
|
|
|
%ext_tex_plane_1 = OpVariable %_ptr_UniformConstant_11 UniformConstant
|
|
|
|
%uint = OpTypeInt 32 0
|
|
|
|
%mat3v4float = OpTypeMatrix %v4float 3
|
|
|
|
%GammaTransferParams = OpTypeStruct %float %float %float %float %float %float %float %uint
|
|
|
|
%v3float = OpTypeVector %float 3
|
|
|
|
%mat3v3float = OpTypeMatrix %v3float 3
|
2022-06-22 03:14:26 +00:00
|
|
|
%ExternalTextureParams = OpTypeStruct %uint %uint %mat3v4float %GammaTransferParams %GammaTransferParams %mat3v3float
|
2022-09-02 19:19:10 +00:00
|
|
|
%ext_tex_params_block = OpTypeStruct %ExternalTextureParams
|
|
|
|
%_ptr_Uniform_ext_tex_params_block = OpTypePointer Uniform %ext_tex_params_block
|
|
|
|
%ext_tex_params = OpVariable %_ptr_Uniform_ext_tex_params_block Uniform
|
2022-06-02 14:36:10 +00:00
|
|
|
%arg_0 = OpVariable %_ptr_UniformConstant_11 UniformConstant
|
2022-09-02 19:19:10 +00:00
|
|
|
%24 = OpTypeSampler
|
|
|
|
%_ptr_UniformConstant_24 = OpTypePointer UniformConstant %24
|
|
|
|
%arg_1 = OpVariable %_ptr_UniformConstant_24 UniformConstant
|
|
|
|
%25 = OpTypeFunction %v3float %v3float %GammaTransferParams
|
2022-06-02 14:36:10 +00:00
|
|
|
%bool = OpTypeBool
|
|
|
|
%v3bool = OpTypeVector %bool 3
|
|
|
|
%_ptr_Function_v3float = OpTypePointer Function %v3float
|
2022-09-02 19:19:10 +00:00
|
|
|
%45 = OpConstantNull %v3float
|
2022-06-02 14:36:10 +00:00
|
|
|
%v2float = OpTypeVector %float 2
|
2022-09-02 19:19:10 +00:00
|
|
|
%65 = OpTypeFunction %v4float %11 %11 %24 %v2float %ExternalTextureParams
|
2022-06-02 14:36:10 +00:00
|
|
|
%uint_1 = OpConstant %uint 1
|
2022-09-02 19:19:10 +00:00
|
|
|
%82 = OpTypeSampledImage %11
|
2022-06-02 14:36:10 +00:00
|
|
|
%float_1 = OpConstant %float 1
|
2022-09-02 19:19:10 +00:00
|
|
|
%98 = OpConstantNull %uint
|
2022-06-02 14:36:10 +00:00
|
|
|
%void = OpTypeVoid
|
2022-09-02 19:19:10 +00:00
|
|
|
%116 = OpTypeFunction %void
|
2022-11-04 17:06:03 +00:00
|
|
|
%120 = OpConstantComposite %v2float %float_1 %float_1
|
2022-06-02 14:36:10 +00:00
|
|
|
%_ptr_Function_v2float = OpTypePointer Function %v2float
|
2022-11-04 17:06:03 +00:00
|
|
|
%123 = OpConstantNull %v2float
|
2022-09-02 19:19:10 +00:00
|
|
|
%uint_0 = OpConstant %uint 0
|
|
|
|
%_ptr_Uniform_ExternalTextureParams = OpTypePointer Uniform %ExternalTextureParams
|
2022-06-02 14:36:10 +00:00
|
|
|
%_ptr_Function_v4float = OpTypePointer Function %v4float
|
2022-11-04 17:06:03 +00:00
|
|
|
%135 = OpTypeFunction %v4float
|
2022-09-02 19:19:10 +00:00
|
|
|
%gammaCorrection = OpFunction %v3float None %25
|
2022-06-02 14:36:10 +00:00
|
|
|
%v = OpFunctionParameter %v3float
|
|
|
|
%params = OpFunctionParameter %GammaTransferParams
|
2022-09-02 19:19:10 +00:00
|
|
|
%29 = OpLabel
|
|
|
|
%43 = OpVariable %_ptr_Function_v3float Function %45
|
|
|
|
%55 = OpVariable %_ptr_Function_v3float Function %45
|
|
|
|
%61 = OpVariable %_ptr_Function_v3float Function %45
|
|
|
|
%30 = OpExtInst %v3float %31 FAbs %v
|
|
|
|
%32 = OpCompositeExtract %float %params 4
|
|
|
|
%33 = OpCompositeConstruct %v3float %32 %32 %32
|
|
|
|
%34 = OpFOrdLessThan %v3bool %30 %33
|
|
|
|
%37 = OpExtInst %v3float %31 FSign %v
|
|
|
|
%38 = OpCompositeExtract %float %params 3
|
|
|
|
%39 = OpExtInst %v3float %31 FAbs %v
|
|
|
|
%40 = OpVectorTimesScalar %v3float %39 %38
|
|
|
|
%41 = OpCompositeExtract %float %params 6
|
|
|
|
%46 = OpCompositeConstruct %v3float %41 %41 %41
|
|
|
|
%42 = OpFAdd %v3float %40 %46
|
|
|
|
%47 = OpFMul %v3float %37 %42
|
|
|
|
%48 = OpExtInst %v3float %31 FSign %v
|
|
|
|
%50 = OpCompositeExtract %float %params 1
|
|
|
|
%51 = OpExtInst %v3float %31 FAbs %v
|
|
|
|
%52 = OpVectorTimesScalar %v3float %51 %50
|
|
|
|
%53 = OpCompositeExtract %float %params 2
|
|
|
|
%56 = OpCompositeConstruct %v3float %53 %53 %53
|
|
|
|
%54 = OpFAdd %v3float %52 %56
|
|
|
|
%57 = OpCompositeExtract %float %params 0
|
|
|
|
%58 = OpCompositeConstruct %v3float %57 %57 %57
|
|
|
|
%49 = OpExtInst %v3float %31 Pow %54 %58
|
|
|
|
%59 = OpCompositeExtract %float %params 5
|
|
|
|
%62 = OpCompositeConstruct %v3float %59 %59 %59
|
|
|
|
%60 = OpFAdd %v3float %49 %62
|
|
|
|
%63 = OpFMul %v3float %48 %60
|
|
|
|
%64 = OpSelect %v3float %34 %47 %63
|
|
|
|
OpReturnValue %64
|
2022-06-02 14:36:10 +00:00
|
|
|
OpFunctionEnd
|
2022-09-02 19:19:10 +00:00
|
|
|
%textureSampleExternal = OpFunction %v4float None %65
|
2022-06-02 14:36:10 +00:00
|
|
|
%plane0 = OpFunctionParameter %11
|
|
|
|
%plane1 = OpFunctionParameter %11
|
2022-09-02 19:19:10 +00:00
|
|
|
%smp = OpFunctionParameter %24
|
2022-06-02 14:36:10 +00:00
|
|
|
%coord = OpFunctionParameter %v2float
|
|
|
|
%params_0 = OpFunctionParameter %ExternalTextureParams
|
2022-09-02 19:19:10 +00:00
|
|
|
%73 = OpLabel
|
|
|
|
%color = OpVariable %_ptr_Function_v3float Function %45
|
|
|
|
%75 = OpCompositeExtract %uint %params_0 0
|
|
|
|
%77 = OpIEqual %bool %75 %uint_1
|
|
|
|
OpSelectionMerge %78 None
|
|
|
|
OpBranchConditional %77 %79 %80
|
2022-06-02 14:36:10 +00:00
|
|
|
%79 = OpLabel
|
2022-09-02 19:19:10 +00:00
|
|
|
%83 = OpSampledImage %82 %plane0 %smp
|
|
|
|
%81 = OpImageSampleExplicitLod %v4float %83 %coord Lod %8
|
|
|
|
%84 = OpVectorShuffle %v3float %81 %81 0 1 2
|
|
|
|
OpStore %color %84
|
|
|
|
OpBranch %78
|
|
|
|
%80 = OpLabel
|
|
|
|
%86 = OpSampledImage %82 %plane0 %smp
|
|
|
|
%85 = OpImageSampleExplicitLod %v4float %86 %coord Lod %8
|
|
|
|
%87 = OpCompositeExtract %float %85 0
|
|
|
|
%89 = OpSampledImage %82 %plane1 %smp
|
|
|
|
%88 = OpImageSampleExplicitLod %v4float %89 %coord Lod %8
|
|
|
|
%90 = OpVectorShuffle %v2float %88 %88 0 1
|
|
|
|
%91 = OpCompositeExtract %float %90 0
|
|
|
|
%92 = OpCompositeExtract %float %90 1
|
|
|
|
%94 = OpCompositeConstruct %v4float %87 %91 %92 %float_1
|
|
|
|
%95 = OpCompositeExtract %mat3v4float %params_0 2
|
|
|
|
%96 = OpVectorTimesMatrix %v3float %94 %95
|
|
|
|
OpStore %color %96
|
|
|
|
OpBranch %78
|
|
|
|
%78 = OpLabel
|
|
|
|
%97 = OpCompositeExtract %uint %params_0 1
|
|
|
|
%99 = OpIEqual %bool %97 %98
|
|
|
|
OpSelectionMerge %100 None
|
|
|
|
OpBranchConditional %99 %101 %100
|
|
|
|
%101 = OpLabel
|
|
|
|
%103 = OpLoad %v3float %color
|
|
|
|
%104 = OpCompositeExtract %GammaTransferParams %params_0 3
|
|
|
|
%102 = OpFunctionCall %v3float %gammaCorrection %103 %104
|
|
|
|
OpStore %color %102
|
|
|
|
%105 = OpCompositeExtract %mat3v3float %params_0 5
|
|
|
|
%106 = OpLoad %v3float %color
|
|
|
|
%107 = OpMatrixTimesVector %v3float %105 %106
|
2022-06-22 03:14:26 +00:00
|
|
|
OpStore %color %107
|
2022-09-02 19:19:10 +00:00
|
|
|
%109 = OpLoad %v3float %color
|
|
|
|
%110 = OpCompositeExtract %GammaTransferParams %params_0 4
|
|
|
|
%108 = OpFunctionCall %v3float %gammaCorrection %109 %110
|
|
|
|
OpStore %color %108
|
|
|
|
OpBranch %100
|
|
|
|
%100 = OpLabel
|
|
|
|
%111 = OpLoad %v3float %color
|
|
|
|
%112 = OpCompositeExtract %float %111 0
|
|
|
|
%113 = OpCompositeExtract %float %111 1
|
|
|
|
%114 = OpCompositeExtract %float %111 2
|
|
|
|
%115 = OpCompositeConstruct %v4float %112 %113 %114 %float_1
|
|
|
|
OpReturnValue %115
|
2022-06-02 14:36:10 +00:00
|
|
|
OpFunctionEnd
|
2022-09-02 19:19:10 +00:00
|
|
|
%textureSampleLevel_979816 = OpFunction %void None %116
|
|
|
|
%119 = OpLabel
|
2022-11-04 17:06:03 +00:00
|
|
|
%arg_2 = OpVariable %_ptr_Function_v2float Function %123
|
2022-06-02 14:36:10 +00:00
|
|
|
%res = OpVariable %_ptr_Function_v4float Function %5
|
2022-09-02 19:19:10 +00:00
|
|
|
OpStore %arg_2 %120
|
2022-11-04 17:06:03 +00:00
|
|
|
%125 = OpLoad %11 %arg_0
|
|
|
|
%126 = OpLoad %11 %ext_tex_plane_1
|
|
|
|
%127 = OpLoad %24 %arg_1
|
|
|
|
%128 = OpLoad %v2float %arg_2
|
|
|
|
%131 = OpAccessChain %_ptr_Uniform_ExternalTextureParams %ext_tex_params %uint_0
|
|
|
|
%132 = OpLoad %ExternalTextureParams %131
|
|
|
|
%124 = OpFunctionCall %v4float %textureSampleExternal %125 %126 %127 %128 %132
|
|
|
|
OpStore %res %124
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2022-11-04 17:06:03 +00:00
|
|
|
%vertex_main_inner = OpFunction %v4float None %135
|
|
|
|
%137 = OpLabel
|
|
|
|
%138 = OpFunctionCall %void %textureSampleLevel_979816
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturnValue %5
|
|
|
|
OpFunctionEnd
|
2022-09-02 19:19:10 +00:00
|
|
|
%vertex_main = OpFunction %void None %116
|
2022-11-04 17:06:03 +00:00
|
|
|
%140 = OpLabel
|
|
|
|
%141 = OpFunctionCall %v4float %vertex_main_inner
|
|
|
|
OpStore %value %141
|
2022-06-02 14:36:10 +00:00
|
|
|
OpStore %vertex_point_size %float_1
|
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2022-09-02 19:19:10 +00:00
|
|
|
%fragment_main = OpFunction %void None %116
|
2022-11-04 17:06:03 +00:00
|
|
|
%143 = OpLabel
|
|
|
|
%144 = OpFunctionCall %void %textureSampleLevel_979816
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2022-09-02 19:19:10 +00:00
|
|
|
%compute_main = OpFunction %void None %116
|
2022-11-04 17:06:03 +00:00
|
|
|
%146 = OpLabel
|
|
|
|
%147 = OpFunctionCall %void %textureSampleLevel_979816
|
2022-06-02 14:36:10 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|