diff options
| author | Brian Paul <brianp@vmware.com> | 2009-07-17 22:00:47 -0600 |
|---|---|---|
| committer | Brian Paul <brianp@vmware.com> | 2009-07-17 22:00:47 -0600 |
| commit | b96ae1b2c463d6d99ee0418083ef68f4027b7cd7 (patch) | |
| tree | f34f89c267b940eb7408475bd0c2ff57c7fbe992 /progs/glsl/points.c | |
| parent | f81f57e25db18b1c69f2f8076380603340fa2cda (diff) | |
| parent | cd10996d4f517c69e306eaf6dfb0654432651b3a (diff) | |
Merge branch 'mesa_7_5_branch'
Conflicts:
Makefile
progs/glsl/multitex.c
src/mesa/main/enums.c
src/mesa/main/state.c
src/mesa/main/texenvprogram.c
src/mesa/main/version.h
Diffstat (limited to 'progs/glsl/points.c')
| -rw-r--r-- | progs/glsl/points.c | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/progs/glsl/points.c b/progs/glsl/points.c index 1b346228aa..e5ee38c449 100644 --- a/progs/glsl/points.c +++ b/progs/glsl/points.c @@ -11,10 +11,7 @@ #include <stdlib.h> #include <math.h> #include <GL/glew.h> -#include <GL/gl.h> #include <GL/glut.h> -#include <GL/glext.h> -#include "extfuncs.h" #include "shaderutil.h" @@ -100,7 +97,7 @@ Redisplay(void) */ glPushMatrix(); glTranslatef(0, 1.2, 0); - glUseProgram_func(0); + glUseProgram(0); DrawPoints(GL_FALSE); glPopMatrix(); @@ -109,9 +106,9 @@ Redisplay(void) */ glPushMatrix(); glTranslatef(0, -1.2, 0); - glUseProgram_func(Program); + glUseProgram(Program); if (uViewportInv != -1) { - glUniform2f_func(uViewportInv, 1.0 / WinWidth, 1.0 / WinHeight); + glUniform2f(uViewportInv, 1.0 / WinWidth, 1.0 / WinHeight); } DrawPoints(GL_TRUE); glPopMatrix(); @@ -151,9 +148,9 @@ Key(unsigned char key, int x, int y) Smooth = !Smooth; break; case 27: - glDeleteShader_func(FragShader); - glDeleteShader_func(VertShader); - glDeleteProgram_func(Program); + glDeleteShader(FragShader); + glDeleteShader(VertShader); + glDeleteProgram(Program); glutDestroyWindow(Win); exit(0); } @@ -226,17 +223,15 @@ Init(void) if (!ShadersSupported()) exit(1); - GetExtensionFuncs(); - VertShader = CompileShaderText(GL_VERTEX_SHADER, vertShaderText); FragShader = CompileShaderText(GL_FRAGMENT_SHADER, fragShaderText); Program = LinkShaders(VertShader, FragShader); - glUseProgram_func(Program); + glUseProgram(Program); - uViewportInv = glGetUniformLocation_func(Program, "viewportInv"); + uViewportInv = glGetUniformLocation(Program, "viewportInv"); - glUseProgram_func(0); + glUseProgram(0); glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); } |
