Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 2 of 2

Thread: OpenGL ES 2.0 / GLEW / GLFW confusion

  1. #1
    Newbie Newbie
    Join Date
    Oct 2012
    Posts
    1

    OpenGL ES 2.0 / GLEW / GLFW confusion

    How do I force my API to be OpenGL ES 2.0 instead of some other random version? When I query for GLSL, I currently get 1.3. Why? I'm on Intel Ivy Bridge Mesa 8.0.4, I should be able to get OpenGL ES 2.0 just fine. Am I forced to use the EGL API ? Right now I'm using GLFW because it has easy to use input routines (I think using the raw Xorg input stuff in EGL would be hard and dangerous because it could lock the desktop up, no? Also Windows can't use xorg input)

    Also for some reason I get a segfault at "glCreateShader()" if I don't use/initialize GLEW. The second I comment it in again, no segfaults.

    On this webpage it says http://www.opengl.org/wiki/GLAPI/glCreateShader glCreateShader is in "core" since version 2.0, shouldn't that mean that I can use it without having to use GLEW?
    How would I use OpenGL if I didn't have something like GLEW, is OpenGL supposed to need another library to load in essential function pointers?!

  2. #2
    Super Moderator OpenGL Guru
    Join Date
    Feb 2000
    Location
    Montreal, Canada
    Posts
    4,264
    Quote Originally Posted by Maxxi12 View Post
    How would I use OpenGL if I didn't have something like GLEW, is OpenGL supposed to need another library to load in essential function pointers?!
    http://www.opengl.org/wiki/Load_OpenGL_Functions
    ------------------------------
    Sig: http://glhlib.sourceforge.net
    an open source GLU replacement library. Much more modern than GLU.
    float matrix[16], inverse_matrix[16];
    glhLoadIdentityf2(matrix);
    glhTranslatef2(matrix, 0.0, 0.0, 5.0);
    glhRotateAboutXf2(matrix, angleInRadians);
    glhScalef2(matrix, 1.0, 1.0, -1.0);
    glhQuickInvertMatrixf2(matrix, inverse_matrix);
    glUniformMatrix4fv(uniformLocation1, 1, FALSE, matrix);
    glUniformMatrix4fv(uniformLocation2, 1, FALSE, inverse_matrix);

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •