source: trunk/monsterz/monsterz.cpp @ 758

Last change on this file since 758 was 758, checked in by sam, 10 years ago

ps3: start a minimal PS3 port using PSGL, but not CG yet.

  • Property svn:keywords set to Id
File size: 1.4 KB
Line 
1//
2// Monsterz
3//
4// Copyright: (c) 2005-2011 Sam Hocevar <sam@hocevar.net>
5//   This program is free software; you can redistribute it and/or
6//   modify it under the terms of the Do What The Fuck You Want To
7//   Public License, Version 2, as published by Sam Hocevar. See
8//   http://sam.zoy.org/projects/COPYING.WTFPL for more details.
9//
10
11#if defined HAVE_CONFIG_H
12#   include "config.h"
13#endif
14
15#if defined _WIN32
16#   include <direct.h>
17#endif
18
19#include "core.h"
20#include "lolgl.h"
21#include "loldebug.h"
22
23using namespace std;
24using namespace lol;
25
26#if defined __CELLOS_LV2__
27#   include "ps3app.h"
28#elif defined HAVE_GLES_2X
29#   include "eglapp.h"
30#else
31#   include "sdlapp.h"
32#   include "sdlinput.h"
33#endif
34#include "interface.h"
35
36#if defined _WIN32
37#   undef main /* FIXME: still needed? */
38#endif
39
40int main(int argc, char **argv)
41{
42#if defined __CELLOS_LV2__
43    Ps3App app("Monsterz", vec2i(640, 480), 60.0f);
44#elif defined HAVE_GLES_2X
45    EglApp app("Monsterz", vec2i(640, 480), 60.0f);
46#else
47    SdlApp app("Monsterz", vec2i(640, 480), 60.0f);
48#endif
49
50#if defined _WIN32
51    _chdir(".."); /* Temporary Win32 hack */
52#endif
53
54    /* Register an input driver and some debug stuff */
55#if !defined HAVE_GLES_2X
56    new SdlInput();
57#endif
58    new Interface();
59    new DebugFps(20, 20);
60    //new DebugRecord("monsterz.ogm", FPS);
61
62    app.Run();
63
64    return EXIT_SUCCESS;
65}
66
Note: See TracBrowser for help on using the repository browser.