filename | src/pvr2/glrender.c |
changeset | 1130:5f56fc931112 |
prev | 1066:ddffe9d2b332 |
next | 1132:1e074a98317c |
author | nkeynes |
date | Fri Sep 17 20:08:50 2010 +1000 (13 years ago) |
permissions | -rw-r--r-- |
last change | Refactor shader management to support multiple programs, which are all defined in the shaders.glsl, rather than split up into one file per fragment. |
file | annotate | diff | log | raw |
1.1 --- a/src/pvr2/glrender.c Sun Jul 05 13:53:48 2009 +10001.2 +++ b/src/pvr2/glrender.c Fri Sep 17 20:08:50 2010 +10001.3 @@ -95,7 +95,7 @@1.4 {1.6 if( glsl_is_supported() ) {1.7 - if( !glsl_load_shaders( glsl_vertex_shader_src, NULL ) ) {1.8 + if( !glsl_load_shaders( ) ) {1.9 WARN( "Unable to load GL shaders" );1.10 }1.11 }1.12 @@ -526,7 +526,7 @@1.13 glFogf(GL_FOG_START, 0.0);1.14 glFogf(GL_FOG_END, 1.0);1.15 /* Turn on the shaders (if available) */1.16 - glsl_enable_shaders(TRUE);1.17 + glsl_set_shader(DEFAULT_PROGRAM);1.19 /* Render the background */1.20 gl_render_bkgnd( pvr2_scene.bkgnd_poly );1.21 @@ -580,7 +580,7 @@1.22 } while( !IS_LAST_SEGMENT(segment++) );1.23 glDisable( GL_SCISSOR_TEST );1.25 - glsl_enable_shaders(FALSE);1.26 + glsl_clear_shader();1.28 gettimeofday( &end_tv, NULL );1.29 ms = (end_tv.tv_sec - tex_tv.tv_sec) * 1000 +
.