   Problem when running a GLFW window on VS 2008
  Hi,I'm trying to run a GLFW application using Visual Studio 2008. It compiles fine but during the execution the window can't be opened.Here is the main function of my program :int __stdcall WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance,LPSTR lpCmdLine,int nCmdShow){   int running = GL_TRUE;    GLFWthread thread, thread_2;    //Initialize GLFW    glfwInit();   // Open an OpenGL window    if(!glfwOpenWindow(640, 480, 0, 0, 0, 0, 0, 0, GLFW_WINDOW)) {   glfwTerminate(); // the program exits here   return -1;    }    // glfwSetWindowSize(640,480); for specifying the size of the window    glfwSetWindowTitle(" AHS Simulator v1.0 by Amokrane CHENTIR & Faris DJOHOR ");    initRendering();    while(running) {    display(); // Swap front and back rendering buffers glfwSwapBuffers();  // Called for updating the logic loop of the scene updateScene(); // Called everytime we want to resize the window glfwSetWindowSizeCallback(windowResize);  // Called everytime we want to register an input //  glfwSetCharCallback(inputString); glfwSetKeyCallback(keyboardHandling); // Called everytime we move the cursor glfwSetMousePosCallback(onCursorMove);  // Check if ESC key was pressed or window was closed running = !glfwGetKey(GLFW_KEY_ESC) && glfwGetWindowParam(GLFW_OPENED);  //running = !glfwGetMouseButton(GLFW_MOUSE_BUTTON_LEFT) && glfwGetWindowParam(GLFW_OPENED);  thread = glfwCreateThread(boucleThread, NULL); glfwWaitThread(thread, GLFW_WAIT); thread_2 = glfwCreateThread(boucleThread_2, NULL);    }    glfwTerminate();    return 0;    }The problem is situated here : if(!glfwOpenWindow(640, 480, 0, 0, 0, 0, 0, 0, GLFW_WINDOW)) {   glfwTerminate(); // the program exits here   return -1;    }Can't open the window.. :/How to resolve it ?Thanks ![EDIT] Please can a moderator move my thread to the OpenGl area ? Thanks ![Edited by - Amokrane on May 21, 2009 6:29:52 PM]
  Hello fellow GLFW user :)I'm not sure if this is the problem, but you may want to do:if(!glfwOpenWindow(640, 480, 8, 8, 8, 0, 8, 8, GLFW_WINDOW)) {instead.I'm pretty sure there's not much more different to my code.I have GLFW fully working in my current project, if you wanna have a look at the code, the glfw part is in here:http://oglib.svn.sourceforge.net/viewvc/oglib/Source/ogSystem/VideoSystem/   ;  You're certain glfwInit is succeeding?   ;  highly unlikely.. the only reason glfwInit would fail is when it failed to load gdi32.dll or winmm.dll.I dont see how that would happen except they are broken(but that would cause other apps to fail too).   