| ; SPIR-V |
| ; Version: 1.3 |
| ; Generator: Google Tint Compiler; 0 |
| ; Bound: 89 |
| ; Schema: 0 |
| OpCapability Shader |
| 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" |
| OpName %ExternalTextureParams "ExternalTextureParams" |
| OpMemberName %ExternalTextureParams 0 "numPlanes" |
| OpMemberName %ExternalTextureParams 1 "yuvToRgbConversionMatrix" |
| OpName %ext_tex_params "ext_tex_params" |
| OpName %arg_0 "arg_0" |
| OpName %textureLoadExternal "textureLoadExternal" |
| OpName %plane0 "plane0" |
| OpName %plane1 "plane1" |
| OpName %coord "coord" |
| OpName %params "params" |
| OpName %color "color" |
| OpName %textureLoad2d "textureLoad2d" |
| OpName %texture "texture" |
| OpName %ext_tex_plane_1_1 "ext_tex_plane_1_1" |
| OpName %ext_tex_params_1 "ext_tex_params_1" |
| OpName %coords "coords" |
| OpName %doTextureLoad "doTextureLoad" |
| 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 1 |
| OpDecorate %ExternalTextureParams Block |
| OpMemberDecorate %ExternalTextureParams 0 Offset 0 |
| OpMemberDecorate %ExternalTextureParams 1 Offset 16 |
| OpMemberDecorate %ExternalTextureParams 1 ColMajor |
| OpMemberDecorate %ExternalTextureParams 1 MatrixStride 16 |
| OpDecorate %ext_tex_params NonWritable |
| OpDecorate %ext_tex_params DescriptorSet 1 |
| OpDecorate %ext_tex_params Binding 2 |
| OpDecorate %arg_0 DescriptorSet 1 |
| OpDecorate %arg_0 Binding 0 |
| %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 |
| %ExternalTextureParams = OpTypeStruct %uint %mat3v4float |
| %_ptr_Uniform_ExternalTextureParams = OpTypePointer Uniform %ExternalTextureParams |
| %ext_tex_params = OpVariable %_ptr_Uniform_ExternalTextureParams Uniform |
| %arg_0 = OpVariable %_ptr_UniformConstant_11 UniformConstant |
| %int = OpTypeInt 32 1 |
| %v2int = OpTypeVector %int 2 |
| %18 = OpTypeFunction %v4float %11 %11 %v2int %ExternalTextureParams |
| %v3float = OpTypeVector %float 3 |
| %_ptr_Function_v3float = OpTypePointer Function %v3float |
| %30 = OpConstantNull %v3float |
| %uint_1 = OpConstant %uint 1 |
| %bool = OpTypeBool |
| %int_0 = OpConstant %int 0 |
| %v2float = OpTypeVector %float 2 |
| %float_1 = OpConstant %float 1 |
| %57 = OpTypeFunction %v4float %11 %11 %ExternalTextureParams %v2int |
| %void = OpTypeVoid |
| %65 = OpTypeFunction %void |
| %73 = OpConstantNull %v2int |
| %_ptr_Function_v4float = OpTypePointer Function %v4float |
| %76 = OpTypeFunction %v4float |
| %textureLoadExternal = OpFunction %v4float None %18 |
| %plane0 = OpFunctionParameter %11 |
| %plane1 = OpFunctionParameter %11 |
| %coord = OpFunctionParameter %v2int |
| %params = OpFunctionParameter %ExternalTextureParams |
| %26 = OpLabel |
| %color = OpVariable %_ptr_Function_v3float Function %30 |
| %31 = OpCompositeExtract %uint %params 0 |
| %33 = OpIEqual %bool %31 %uint_1 |
| OpSelectionMerge %35 None |
| OpBranchConditional %33 %36 %37 |
| %36 = OpLabel |
| %38 = OpImageFetch %v4float %plane0 %coord Lod %int_0 |
| %40 = OpVectorShuffle %v3float %38 %38 0 1 2 |
| OpStore %color %40 |
| OpBranch %35 |
| %37 = OpLabel |
| %41 = OpImageFetch %v4float %plane0 %coord Lod %int_0 |
| %42 = OpCompositeExtract %float %41 0 |
| %43 = OpImageFetch %v4float %plane1 %coord Lod %int_0 |
| %45 = OpVectorShuffle %v2float %43 %43 0 1 |
| %46 = OpCompositeExtract %float %45 0 |
| %47 = OpCompositeExtract %float %45 1 |
| %49 = OpCompositeConstruct %v4float %42 %46 %47 %float_1 |
| %50 = OpCompositeExtract %mat3v4float %params 1 |
| %51 = OpVectorTimesMatrix %v3float %49 %50 |
| OpStore %color %51 |
| OpBranch %35 |
| %35 = OpLabel |
| %52 = OpLoad %v3float %color |
| %53 = OpCompositeExtract %float %52 0 |
| %54 = OpCompositeExtract %float %52 1 |
| %55 = OpCompositeExtract %float %52 2 |
| %56 = OpCompositeConstruct %v4float %53 %54 %55 %float_1 |
| OpReturnValue %56 |
| OpFunctionEnd |
| %textureLoad2d = OpFunction %v4float None %57 |
| %texture = OpFunctionParameter %11 |
| %ext_tex_plane_1_1 = OpFunctionParameter %11 |
| %ext_tex_params_1 = OpFunctionParameter %ExternalTextureParams |
| %coords = OpFunctionParameter %v2int |
| %63 = OpLabel |
| %64 = OpFunctionCall %v4float %textureLoadExternal %texture %ext_tex_plane_1_1 %coords %ext_tex_params_1 |
| OpReturnValue %64 |
| OpFunctionEnd |
| %doTextureLoad = OpFunction %void None %65 |
| %68 = OpLabel |
| %res = OpVariable %_ptr_Function_v4float Function %5 |
| %70 = OpLoad %11 %arg_0 |
| %71 = OpLoad %11 %ext_tex_plane_1 |
| %72 = OpLoad %ExternalTextureParams %ext_tex_params |
| %69 = OpFunctionCall %v4float %textureLoad2d %70 %71 %72 %73 |
| OpStore %res %69 |
| OpReturn |
| OpFunctionEnd |
| %vertex_main_inner = OpFunction %v4float None %76 |
| %78 = OpLabel |
| %79 = OpFunctionCall %void %doTextureLoad |
| OpReturnValue %5 |
| OpFunctionEnd |
| %vertex_main = OpFunction %void None %65 |
| %81 = OpLabel |
| %82 = OpFunctionCall %v4float %vertex_main_inner |
| OpStore %value %82 |
| OpStore %vertex_point_size %float_1 |
| OpReturn |
| OpFunctionEnd |
| %fragment_main = OpFunction %void None %65 |
| %84 = OpLabel |
| %85 = OpFunctionCall %void %doTextureLoad |
| OpReturn |
| OpFunctionEnd |
| %compute_main = OpFunction %void None %65 |
| %87 = OpLabel |
| %88 = OpFunctionCall %void %doTextureLoad |
| OpReturn |
| OpFunctionEnd |