| 1 |
; SPIR-V |
| 2 |
; Version: 1.0 |
| 3 |
; Generator: Khronos Glslang Reference Front End; 2 |
| 4 |
; Bound: 26 |
| 5 |
; Schema: 0 |
| 6 |
OpCapability Shader |
| 7 |
%1 = OpExtInstImport "GLSL.std.450" |
| 8 |
OpMemoryModel Logical GLSL450 |
| 9 |
OpEntryPoint Vertex %main "main" %_ %gl_VertexID %gl_InstanceID |
| 10 |
OpSource GLSL 450 |
| 11 |
OpName %main "main" |
| 12 |
OpName %gl_PerVertex "gl_PerVertex" |
| 13 |
OpMemberName %gl_PerVertex 0 "gl_Position" |
| 14 |
OpMemberName %gl_PerVertex 1 "gl_PointSize" |
| 15 |
OpMemberName %gl_PerVertex 2 "gl_ClipDistance" |
| 16 |
OpMemberName %gl_PerVertex 3 "gl_CullDistance" |
| 17 |
OpName %_ "" |
| 18 |
OpName %gl_VertexID "gl_VertexID" |
| 19 |
OpName %gl_InstanceID "gl_InstanceID" |
| 20 |
OpMemberDecorate %gl_PerVertex 0 BuiltIn Position |
| 21 |
OpMemberDecorate %gl_PerVertex 1 BuiltIn PointSize |
| 22 |
OpMemberDecorate %gl_PerVertex 2 BuiltIn ClipDistance |
| 23 |
OpMemberDecorate %gl_PerVertex 3 BuiltIn CullDistance |
| 24 |
OpDecorate %gl_PerVertex Block |
| 25 |
OpDecorate %gl_VertexID BuiltIn VertexIndex |
| 26 |
OpDecorate %gl_InstanceID BuiltIn InstanceIndex |
| 27 |
%void = OpTypeVoid |
| 28 |
%3 = OpTypeFunction %void |
| 29 |
%float = OpTypeFloat 32 |
| 30 |
%v4float = OpTypeVector %float 4 |
| 31 |
%uint = OpTypeInt 32 0 |
| 32 |
%uint_1 = OpConstant %uint 1 |
| 33 |
%_arr_float_uint_1 = OpTypeArray %float %uint_1 |
| 34 |
%gl_PerVertex = OpTypeStruct %v4float %float %_arr_float_uint_1 %_arr_float_uint_1 |
| 35 |
%_ptr_Output_gl_PerVertex = OpTypePointer Output %gl_PerVertex |
| 36 |
%_ = OpVariable %_ptr_Output_gl_PerVertex Output |
| 37 |
%int = OpTypeInt 32 1 |
| 38 |
%int_0 = OpConstant %int 0 |
| 39 |
%_ptr_Input_int = OpTypePointer Input %int |
| 40 |
%gl_VertexID = OpVariable %_ptr_Input_int Input |
| 41 |
%gl_InstanceID = OpVariable %_ptr_Input_int Input |
| 42 |
%_ptr_Output_v4float = OpTypePointer Output %v4float |
| 43 |
%main = OpFunction %void None %3 |
| 44 |
%5 = OpLabel |
| 45 |
%18 = OpLoad %int %gl_VertexID |
| 46 |
%20 = OpLoad %int %gl_InstanceID |
| 47 |
%21 = OpIAdd %int %18 %20 |
| 48 |
%22 = OpConvertSToF %float %21 |
| 49 |
%23 = OpCompositeConstruct %v4float %22 %22 %22 %22 |
| 50 |
%25 = OpAccessChain %_ptr_Output_v4float %_ %int_0 |
| 51 |
OpStore %25 %23 |
| 52 |
OpReturn |
| 53 |
OpFunctionEnd |