Changeset 346 for trunk/src/gfx
- Timestamp:
- 11/18/14 14:56:13 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/gfx/debug_draw.cc
r319 r346 9 9 #include "nv/interface/device.hh" 10 10 11 static const char *nv_debug_draw_vertex_shader = 12 "#version 120\n" 13 "attribute vec3 nv_position;\n" 14 "attribute vec3 nv_color;\n" 15 "varying vec3 v_color;\n" 16 "uniform mat4 nv_m_mvp;\n" 17 "void main(void)\n" 18 "{\n" 19 " gl_Position = nv_m_mvp * vec4 (nv_position, 1.0);\n" 20 " v_color = nv_color;\n" 21 "}\n"; 22 static const char *nv_debug_draw_fragment_shader = 23 "#version 120\n" 24 "varying vec3 v_color;\n" 25 "void main(void)\n" 26 "{\n" 27 " gl_FragColor = vec4( v_color, 1.0 );\n" 28 "}\n"; 11 static const char *nv_debug_draw_vertex_shader = R"( 12 #version 120 13 attribute vec3 nv_position; 14 attribute vec3 nv_color; 15 varying vec3 v_color; 16 uniform mat4 nv_m_mvp; 17 void main(void) 18 { 19 gl_Position = nv_m_mvp * vec4 (nv_position, 1.0); 20 v_color = nv_color; 21 }; 22 )"; 23 static const char *nv_debug_draw_fragment_shader = R"( 24 #version 120 25 varying vec3 v_color; 26 void main(void) 27 { 28 gl_FragColor = vec4( v_color, 1.0 ); 29 } 30 )"; 29 31 30 32 nv::debug_data::debug_data( context* a_context )
Note: See TracChangeset
for help on using the changeset viewer.