00001 #include "main.h"
00002
00007 #include <glutm/master.h>
00008
00009 #if defined(GLUTM_WIN32) && !defined(GLUTM_SAVER)
00010
00011 #include <windows.h>
00012
00013 int WINAPI WinMain(HINSTANCE hInstance,
00014 HINSTANCE hPrevInstance,
00015 LPSTR lpCmdLine,
00016 int nCmdShow)
00017 {
00018 GlutMaster::init();
00019
00020 std::vector<std::string> arg;
00021
00022 if (GlutMain(arg))
00023 GlutMaster::mainLoop();
00024
00025
00026 return EXIT_SUCCESS;
00027 }
00028
00029 #endif
00030
00031 int main(int argc,char** argv)
00032 {
00033 GlutMaster::init(argc,argv);
00034
00035 bool ok;
00036
00037 {
00038
00039
00040
00041
00042 std::vector<std::string> arg(argc);
00043 for (int i=0; i<argc; i++)
00044 arg[i] = argv[i];
00045
00046 ok = GlutMain(arg);
00047 }
00048
00049 if (ok)
00050 GlutMaster::mainLoop();
00051
00052
00053 return EXIT_SUCCESS;
00054 }
00055
00056
00057