I created a openGL project thats a command line program but now I am changing my basecode from GLFW to windows.h. So naturally I need to use WinMain() instead of main(). How do I change this in Visual C++ 6.0?
How is this related to GL? I’m doing this for a GL project
To use Win32 as your basecode you just create a Win 32 Application under the projects tab in MSVC++. It’s not really related to OpenGL, but to see how to setup your basecode to use OpenGL, look to Nehe lesson #1.
Open the project settings and look for the “Project Settings” box under the C++ tab. There may (should?) be a /subsystem option displayed in this box. If there is, change it to /subsystem:Windows or /subsystem:window. You’ll have to experiment as I can’t remember offhand what the real value should be. Failing that search Google for subsystem and visual studio and see what comes back.
You’ll need to add in your Windows specific code and change the main to WinMain.