This is my script i have no idea to solve this error Please help me Thank you so much
float angle = 15;
float x, y, z; // for polygon rotate
voi
As workaround you can add WinMain
function from which call main
:
#ifdef _WIN32
int APIENTRY WinMain(HINSTANCE hInstance,
HINSTANCE hPrevInstance,
LPSTR lpCmdLine, int nCmdShow)
{
return main(__argc, __argv);
}
#endif
For me following this helped.
Go to properties->Linker -> System -> Sub-system
and choose "not set" or "Windows"
I had to make the application as executable project with output type .exe Key change was changing Linker -> System -> Sub-system to Console
You've set the project to build as a Windows application, not a command line application. Change int main()
to:
int CALLBACK WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR pCmdLine, int nCmdShow)
https://msdn.microsoft.com/en-us/library/windows/desktop/ms633559%28v=vs.85%29.aspx
Or, change your project properties to be a command line application.