tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

uniformBlockShader.vert (517B)


      1 #version 300 es
      2 
      3 /*
      4 Copyright (c) 2019 The Khronos Group Inc.
      5 Use of this source code is governed by an MIT-style license that can be
      6 found in the LICENSE.txt file.
      7 */
      8 
      9 in vec4 a_vertex;
     10 in vec3 a_normal;
     11 
     12 uniform Transform {
     13    mat4 u_modelViewMatrix;
     14    mat4 u_projectionMatrix;
     15    mat3 u_normalMatrix;
     16 };
     17 
     18 out vec3 normal;
     19 out vec4 ecPosition;
     20 
     21 void main()
     22 {
     23    normal = normalize(u_normalMatrix * a_normal);
     24    ecPosition = u_modelViewMatrix * a_vertex;
     25    gl_Position =  u_projectionMatrix * ecPosition;
     26 }