• Advertisement
Sign in to follow this  

GLFW failes to inirialize

This topic is 3568 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I downloadead glfw, compiled the source code and made myself a static library. I copied on of the example programs that ship with glfw and run it. Strangely glfwInit fails, i entered in debug mode and found that this line:
    _glfwLibrary.Libs.gdi32 = LoadLibrary( "gdi32.dll" );

returns null. I'm using Microsoft Visual Studio Express( Msdev 2008 or Msdev 9.0). Why is this so? What can i do? I downloaded their the static library from the site but i receive a lot of link errors that say that certain functions cannot be found.

Share this post


Link to post
Share on other sites
Advertisement
You don't need to link to libraries that are loaded via LoadLibrary. Call GetLastError to get the error code.
Do you have the same problem with the dynamic version of glfw?
Are you using a 64 bit os? If yes I don't know whether the 32 bit dll gdi32.dll can be found in the search path or not.
If I remember correctly visual studio express version can only compile 32 bit executables otherwise you should know that 64 bit applications can't load 32 bit dlls and vise versa.

Share this post


Link to post
Share on other sites
Very weird problem. That library should be on any Windows system I would think. Try looking in your C:/WINDOWS/system32 folder and see if that file is not present.

Share this post


Link to post
Share on other sites
Quote:
Original post by Simian Man
Very weird problem. That library should be on any Windows system I would think. Try looking in your C:/WINDOWS/system32 folder and see if that file is not present.


GDI32.dll is present in the Windows directory.

bump

[Edited by - Deliverance on July 14, 2008 4:49:29 AM]

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement