Ignore:
Timestamp:
07/15/13 02:48:06 (12 years ago)
Author:
epyon
Message:
  • unified naming of attributes in nv
  • predefined attribute bindings based on unified names
  • unified naming of attributes in all tests
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/objload_test/obj.vert

    r139 r161  
    11#version 120
    22
    3 attribute vec3 position;
    4 attribute vec2 texcoord;
    5 attribute vec3 normal;
     3attribute vec3 nv_position;
     4attribute vec2 nv_texcoord;
     5attribute vec3 nv_normal;
    66
    77varying vec3 v_normal;
     
    1717
    1818void main(void) {
    19         vec4 vertex     = vec4( position, 1.0 );
     19        vec4 vertex     = vec4( nv_position, 1.0 );
    2020        vec3 eye_pos    = vec3( nv_m_modelview * vertex );
    21         v_normal        = normalize( nv_m_normal * normal );
     21        v_normal        = normalize( nv_m_normal * nv_normal );
    2222        v_light_vector  = vec3( normalize( light_position - eye_pos ) );
    2323        v_view_vector   = vec3( normalize( -eye_pos ) );
    2424
    25         v_texcoord      = texcoord;
     25        v_texcoord      = nv_texcoord;
    2626        gl_Position     = matrix_mvp * vertex;
    2727}
Note: See TracChangeset for help on using the changeset viewer.