Changeset 4f63fa8 in opengl-game for shaders/shader.vert
- Timestamp:
- Aug 2, 2019, 5:17:11 PM (6 years ago)
- Branches:
- feature/imgui-sdl, master, points-test
- Children:
- 2c87504, adcd252
- Parents:
- fba08f2
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
shaders/shader.vert
rfba08f2 r4f63fa8 1 1 #version 450 2 2 #extension GL_ARB_separate_shader_objects : enable 3 4 vec2 positions[3] = vec2[](5 vec2( 0.0, 0.5),6 vec2(-0.5, -0.5),7 vec2( 0.5, -0.5)8 );9 3 10 4 layout (binding = 0) uniform UniformBufferObject { … … 22 16 23 17 void main() { 24 // gl_Position = ubo.proj * ubo.view * ubo.model * vec4(inPosition, 0.0, 1.0); 25 gl_Position = ubo.proj * ubo.view * ubo.model * vec4(positions[gl_VertexIndex], -5.0, 1.0); 18 gl_Position = ubo.proj * ubo.view * ubo.model * vec4(inPosition, 0.0, 1.0); 26 19 fragColor = inColor; 27 20 fragTexCoord = inTexCoord;
Note:
See TracChangeset
for help on using the changeset viewer.