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: glGetString problems

  1. #1
    Junior Member Newbie
    Join Date
    Aug 2000
    Location
    Ontario
    Posts
    4

    glGetString problems

    i have an options dialog that starts up before the actual program starts. the option dialog has a details dialog that shows information such as GL_VENDOR, GL_RENDERER, etc. however, when i try to get the requested information, it cannot be found.

    if i have a dummy dialog that performs the exact same thing with the exception that it is invoked after the program starts, it can find the relevant information.

    my question is: do you have to create a working window with opengl already running to get this information, or can you just call glGetString regardless if opengl is set up or not?

  2. #2
    Senior Member OpenGL Pro
    Join Date
    Oct 2000
    Location
    Fargo, ND
    Posts
    1,797

    Re: glGetString problems

    You'll need to actually get OpenGL initialized in order for the glGetString to work. I have a dialog box that I used to display a list of extensions that a card supports, and the way I got around it was to place a small non-visible static control somewhere on the dialog, then used the HDC from that to initialize OpenGL. If I recall, I just had to go through the pixelformat and wgl functions for glGetString to work. There's no need to setup the projection matrix, or any other initialization stuff after enabling OpenGL for the HDC.
    Deiussum
    Software Engineer and OpenGL enthusiast

Posting Permissions

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