pathfinder/shaders/demo_ground.vs.glsl

26 lines
688 B
Plaintext
Raw Normal View History

#version 330
// pathfinder/resources/shaders/demo_ground.vs.glsl
//
// Copyright © 2019 The Pathfinder Project Developers.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
precision highp float;
uniform mat4 uTransform;
2019-05-02 16:13:43 -04:00
uniform int uGridlineCount;
in vec2 aPosition;
2019-05-02 16:13:43 -04:00
out vec2 vTexCoord;
void main() {
2019-05-02 16:13:43 -04:00
vTexCoord = aPosition * float(uGridlineCount);
gl_Position = uTransform * vec4(aPosition.x, 0.0, aPosition.y, 1.0);
}