diff mbox

[Branch,~glmark2-dev/glmark2/trunk] Rev 34: Get rid of gl functions not available in or relevant to OpenGL ES 2.0.

Message ID 20110721123632.17019.75835.launchpad@loganberry.canonical.com
State Accepted
Headers show

Commit Message

Alexandros Frantzis July 21, 2011, 12:36 p.m. UTC
------------------------------------------------------------
revno: 34
committer: Alexandros Frantzis <alf82@freemail.gr>
timestamp: Fri 2010-07-09 17:14:04 +0300
message:
  Get rid of gl functions not available in or relevant to OpenGL ES 2.0.
modified:
  screen.cpp


--
lp:glmark2
https://code.launchpad.net/~glmark2-dev/glmark2/trunk

You are subscribed to branch lp:glmark2.
To unsubscribe from this branch go to https://code.launchpad.net/~glmark2-dev/glmark2/trunk/+edit-subscription
diff mbox

Patch

=== modified file 'screen.cpp'
--- screen.cpp	2010-07-08 12:54:10 +0000
+++ screen.cpp	2010-07-09 14:14:04 +0000
@@ -39,7 +39,7 @@ 
 
     if(mFullScreen)
     mFlags = SDL_OPENGL | SDL_FULLSCREEN;
-    
+
     mInfo = SDL_GetVideoInfo();
 
     SDL_GL_SetAttribute(SDL_GL_RED_SIZE, 5);
@@ -53,10 +53,9 @@ 
         fprintf(stderr, "[ Fail ] - Video mode set failed: %s\n", SDL_GetError());
         return 0;
     }
-    
+
     SDL_WM_SetCaption("GLMark 08", NULL);
-    
-    glShadeModel(GL_SMOOTH);
+
     glClearColor(0.0f, 0.0f, 0.0f, 0.5f);
     glClearDepth(1.0f);
     glEnable(GL_DEPTH_TEST);
@@ -64,14 +63,8 @@ 
     glEnable(GL_CULL_FACE);
     glCullFace(GL_BACK);
 
-    glHint(GL_PERSPECTIVE_CORRECTION_HINT, GL_NICEST);
     glViewport(0, 0, mWidth, mHeight);
 
-    glMatrixMode(GL_PROJECTION);
-    glLoadIdentity();
-    gluPerspective(60.0, mWidth / (float)mHeight, 1.0, 1024.0);
-    glMatrixMode(GL_MODELVIEW);
-    
     clear();
 
     mProjection.perspective(60.0, mWidth / (float)mHeight, 1.0, 1024.0);
@@ -88,7 +81,6 @@ 
 void Screen::clear()
 {
     glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
-    glLoadIdentity();
 }
 
 void Screen::update()
@@ -102,6 +94,5 @@ 
     printf("    GL_VENDOR:     %s\n", glGetString(GL_VENDOR));
     printf("    GL_RENDERER:   %s\n", glGetString(GL_RENDERER));
     printf("    GL_VERSION:    %s\n", glGetString(GL_VERSION));
-//    printf("GL_EXTENSIONS:	%s\n", glGetString(GL_EXTENSIONS));
 }