2021-07-23 13:10:12 +00:00
|
|
|
; SPIR-V
|
|
|
|
; Version: 1.3
|
|
|
|
; Generator: Google Tint Compiler; 0
|
|
|
|
; Bound: 53
|
|
|
|
; Schema: 0
|
|
|
|
OpCapability Shader
|
|
|
|
%28 = OpExtInstImport "GLSL.std.450"
|
|
|
|
OpMemoryModel Logical GLSL450
|
2021-08-05 17:34:19 +00:00
|
|
|
OpEntryPoint Fragment %main "main" %gl_FragCoord_param_1 %x_GLF_color_1_1
|
2021-07-23 13:10:12 +00:00
|
|
|
OpExecutionMode %main OriginUpperLeft
|
2021-08-05 17:34:19 +00:00
|
|
|
OpName %gl_FragCoord_param_1 "gl_FragCoord_param_1"
|
|
|
|
OpName %x_GLF_color_1_1 "x_GLF_color_1_1"
|
2021-07-23 13:10:12 +00:00
|
|
|
OpName %gl_FragCoord "gl_FragCoord"
|
|
|
|
OpName %buf0 "buf0"
|
|
|
|
OpMemberName %buf0 0 "one"
|
|
|
|
OpName %x_6 "x_6"
|
|
|
|
OpName %x_GLF_color "x_GLF_color"
|
|
|
|
OpName %main_1 "main_1"
|
|
|
|
OpName %main_out "main_out"
|
|
|
|
OpMemberName %main_out 0 "x_GLF_color_1"
|
2021-08-05 17:34:19 +00:00
|
|
|
OpName %main_inner "main_inner"
|
|
|
|
OpName %gl_FragCoord_param "gl_FragCoord_param"
|
2021-07-23 13:10:12 +00:00
|
|
|
OpName %main "main"
|
2021-08-05 17:34:19 +00:00
|
|
|
OpDecorate %gl_FragCoord_param_1 BuiltIn FragCoord
|
|
|
|
OpDecorate %x_GLF_color_1_1 Location 0
|
2021-07-23 13:10:12 +00:00
|
|
|
OpDecorate %buf0 Block
|
|
|
|
OpMemberDecorate %buf0 0 Offset 0
|
|
|
|
OpDecorate %x_6 NonWritable
|
|
|
|
OpDecorate %x_6 DescriptorSet 0
|
|
|
|
OpDecorate %x_6 Binding 0
|
|
|
|
OpMemberDecorate %main_out 0 Offset 0
|
|
|
|
%float = OpTypeFloat 32
|
|
|
|
%v4float = OpTypeVector %float 4
|
2021-08-05 17:34:19 +00:00
|
|
|
%_ptr_Input_v4float = OpTypePointer Input %v4float
|
|
|
|
%gl_FragCoord_param_1 = OpVariable %_ptr_Input_v4float Input
|
|
|
|
%_ptr_Output_v4float = OpTypePointer Output %v4float
|
|
|
|
%7 = OpConstantNull %v4float
|
|
|
|
%x_GLF_color_1_1 = OpVariable %_ptr_Output_v4float Output %7
|
2021-07-23 13:10:12 +00:00
|
|
|
%_ptr_Private_v4float = OpTypePointer Private %v4float
|
2021-08-05 17:34:19 +00:00
|
|
|
%gl_FragCoord = OpVariable %_ptr_Private_v4float Private %7
|
2021-07-23 13:10:12 +00:00
|
|
|
%buf0 = OpTypeStruct %float
|
|
|
|
%_ptr_Uniform_buf0 = OpTypePointer Uniform %buf0
|
|
|
|
%x_6 = OpVariable %_ptr_Uniform_buf0 Uniform
|
2021-08-05 17:34:19 +00:00
|
|
|
%x_GLF_color = OpVariable %_ptr_Private_v4float Private %7
|
2021-07-23 13:10:12 +00:00
|
|
|
%void = OpTypeVoid
|
|
|
|
%14 = OpTypeFunction %void
|
|
|
|
%uint = OpTypeInt 32 0
|
|
|
|
%uint_0 = OpConstant %uint 0
|
|
|
|
%_ptr_Private_float = OpTypePointer Private %float
|
|
|
|
%_ptr_Uniform_float = OpTypePointer Uniform %float
|
|
|
|
%float_3 = OpConstant %float 3
|
|
|
|
%float_1 = OpConstant %float 1
|
|
|
|
%float_2 = OpConstant %float 2
|
|
|
|
%bool = OpTypeBool
|
|
|
|
%float_0 = OpConstant %float 0
|
|
|
|
%38 = OpConstantComposite %v4float %float_1 %float_0 %float_0 %float_1
|
|
|
|
%39 = OpConstantComposite %v4float %float_0 %float_0 %float_0 %float_0
|
|
|
|
%main_out = OpTypeStruct %v4float
|
2021-08-05 17:34:19 +00:00
|
|
|
%40 = OpTypeFunction %main_out %v4float
|
2021-07-23 13:10:12 +00:00
|
|
|
%main_1 = OpFunction %void None %14
|
|
|
|
%17 = OpLabel
|
|
|
|
%21 = OpAccessChain %_ptr_Private_float %gl_FragCoord %uint_0
|
|
|
|
%22 = OpLoad %float %21
|
|
|
|
%24 = OpAccessChain %_ptr_Uniform_float %x_6 %uint_0
|
|
|
|
%25 = OpLoad %float %24
|
|
|
|
%31 = OpFAdd %float %float_2 %25
|
|
|
|
%27 = OpExtInst %float %28 NClamp %22 %float_1 %31
|
|
|
|
%32 = OpFOrdGreaterThanEqual %bool %float_3 %27
|
|
|
|
OpSelectionMerge %34 None
|
|
|
|
OpBranchConditional %32 %35 %36
|
|
|
|
%35 = OpLabel
|
|
|
|
OpStore %x_GLF_color %38
|
|
|
|
OpBranch %34
|
|
|
|
%36 = OpLabel
|
|
|
|
OpStore %x_GLF_color %39
|
|
|
|
OpBranch %34
|
|
|
|
%34 = OpLabel
|
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|
2021-08-05 17:34:19 +00:00
|
|
|
%main_inner = OpFunction %main_out None %40
|
|
|
|
%gl_FragCoord_param = OpFunctionParameter %v4float
|
2021-07-23 13:10:12 +00:00
|
|
|
%44 = OpLabel
|
2021-08-05 17:34:19 +00:00
|
|
|
OpStore %gl_FragCoord %gl_FragCoord_param
|
|
|
|
%45 = OpFunctionCall %void %main_1
|
|
|
|
%46 = OpLoad %v4float %x_GLF_color
|
|
|
|
%47 = OpCompositeConstruct %main_out %46
|
|
|
|
OpReturnValue %47
|
2021-07-23 13:10:12 +00:00
|
|
|
OpFunctionEnd
|
|
|
|
%main = OpFunction %void None %14
|
2021-08-05 17:34:19 +00:00
|
|
|
%49 = OpLabel
|
|
|
|
%51 = OpLoad %v4float %gl_FragCoord_param_1
|
|
|
|
%50 = OpFunctionCall %main_out %main_inner %51
|
|
|
|
%52 = OpCompositeExtract %v4float %50 0
|
|
|
|
OpStore %x_GLF_color_1_1 %52
|
2021-07-23 13:10:12 +00:00
|
|
|
OpReturn
|
|
|
|
OpFunctionEnd
|