source:
opengl-game/main-vulkan.cpp@
ca188cc
Last change on this file since ca188cc was aa7707d, checked in by , 4 years ago | |
---|---|
|
|
File size: 703 bytes |
Rev | Line | |
---|---|---|
[e8ebc76] | 1 | #include <iostream> |
2 | ||
[5edbd58] | 3 | #include "consts.hpp" |
[76d19a8] | 4 | #include "crash-logger.hpp" |
5 | ||
[aa7707d] | 6 | #include "vulkan-game.hpp" |
7 | ||
[e8ebc76] | 8 | using namespace std; |
9 | ||
[76d19a8] | 10 | int __main(int argc, char* argv[]); |
11 | ||
[e8ebc76] | 12 | int main(int argc, char* argv[]) { |
[4994692] | 13 | // TODO: Add date & time to the crash log |
[76d19a8] | 14 | CrashLogger logger(__main, argc, argv); |
15 | ||
16 | exit(0); | |
17 | } | |
18 | ||
19 | int __main(int argc, char* argv[]) { | |
[34bdf3a] | 20 | const int MAX_FRAMES_IN_FLIGHT = 2; |
21 | ||
[99d44b2] | 22 | cout << "Starting Vulkan Game..." << endl; |
[e8ebc76] | 23 | |
[34bdf3a] | 24 | VulkanGame game(MAX_FRAMES_IN_FLIGHT); |
[e8ebc76] | 25 | |
26 | try { | |
[5edbd58] | 27 | game.run(800, 600, GUI_FLAGS_WINDOW_FULLSCREEN); |
[e8ebc76] | 28 | } catch (const exception& e) { |
29 | cerr << e.what() << endl; | |
30 | return EXIT_FAILURE; | |
31 | } | |
32 | ||
33 | cout << "Finished running the game" << endl; | |
34 | ||
35 | return EXIT_SUCCESS; | |
[4994692] | 36 | } |
Note:
See TracBrowser
for help on using the repository browser.