I’m a beginner.I write a program:
#include <windows.h>
#include <GL\gl.h>
#include <GL\glaux.h>
int main(void)
{
auxInitDisplayMode(AUX_SINGLE|AUX_RGBA);
auxInitPosition(0,0,500,500);
auxInitWindow(“simple”);
glClearColor(0.0,0.0,0.0,0.0);
glClear(GL_COLOR_BUFFER_BIT);
glColor3f(1.0,0.0,0.0);
glRectf(-0.5,-0.5,0.5,0.5);
glFlush();
return 1;
}
When I compiler the program,passed!!But,when I run the program,error occured:
--------------------Configuration: simple - Win32 Debug--------------------
Linking…
LIBCD.lib(wincrt0.obj) : error LNK2001: unresolved external symbol _WinMain@16
Debug/simple.exe : fatal error LNK1120: 1 unresolved externals
Error executing link.exe.
simple.exe - 2 error(s), 0 warning(s)
What I can do???