source: opengl-game/game-gui-sdl.hpp@ 7bf5433

feature/imgui-sdl points-test
Last change on this file since 7bf5433 was 27c40ce, checked in by Dmitry Portnoy <dmp1488@…>, 5 years ago

Update vulkangame to correctly display a window in Windows and add some commented-out code for a generic system for processing UI events

  • Property mode set to 100644
File size: 984 bytes
RevLine 
[0e6ecf3]1#ifndef _GAME_GUI_SDL_H
2#define _GAME_GUI_SDL_H
3
[98f3232]4#include "game-gui.hpp"
[f898c5f]5
[0e6ecf3]6#include <SDL2/SDL.h>
[5f3dba8]7#include <SDL2/SDL_image.h>
8#include <SDL2/SDL_ttf.h>
[0e6ecf3]9#include <SDL2/SDL_vulkan.h>
10
[98f3232]11class GameGui_SDL : public GameGui {
[f898c5f]12 public:
[7fc5e27]13 string& getError();
[d5f2b42]14
[7fc5e27]15 bool init();
16 void shutdown();
[0e6ecf3]17
[7fc5e27]18 void* createWindow(const string& title, int width, int height, bool fullscreen);
19 void destroyWindow();
[0e6ecf3]20
[27c40ce]21 // temporary
22 //int pollEvent(SDL_Event* event);
23
24 /*
25 void processEvents();
26
27 unsigned char getKeyEvent(unsigned int key);
28 bool isKeyPressed(unsigned int key);
29
30 int pollMouseEvent(MouseEvent* event);
31 */
32
[4eb4d0a]33#ifdef GAMEGUI_INCLUDE_VULKAN
[7fc5e27]34 bool createVulkanSurface(VkInstance instance, VkSurfaceKHR* surface);
[4eb4d0a]35#endif
36
[7fc5e27]37 vector<const char*> getRequiredExtensions();
38 void getWindowSize(int* width, int* height);
[0e6ecf3]39
40 private:
41 SDL_Window* window;
[d5f2b42]42
43 static string s_errorMessage;
[0e6ecf3]44};
45
46#endif // _GAME_GUI_SDL_H
Note: See TracBrowser for help on using the repository browser.