diff options
| author | Ryan Houdek <Sonicadvance1@gmail.com> | 2016-01-30 11:15:07 -0500 |
|---|---|---|
| committer | Ryan Houdek <Sonicadvance1@gmail.com> | 2016-01-30 11:15:07 -0500 |
| commit | 31523b7e80846256a3eeb34be69ba1a0ffc8ef19 (patch) | |
| tree | 90e7ffcde198a9d38107ff44103cd44b562d70bd /Source/Core/DolphinWX/MainNoGUI.cpp | |
| parent | 8e8e6f3234ef6bf4b0ecedd304e47ca73b702ea8 (diff) | |
| parent | 628e9bad92673c27a974649ee18c48483003347a (diff) | |
Merge pull request #3572 from Sonicadvance1/egl_support_headless
Egl support headless
Diffstat (limited to 'Source/Core/DolphinWX/MainNoGUI.cpp')
| -rw-r--r-- | Source/Core/DolphinWX/MainNoGUI.cpp | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/Source/Core/DolphinWX/MainNoGUI.cpp b/Source/Core/DolphinWX/MainNoGUI.cpp index 70f099deb7..180af3ffe2 100644 --- a/Source/Core/DolphinWX/MainNoGUI.cpp +++ b/Source/Core/DolphinWX/MainNoGUI.cpp @@ -35,11 +35,11 @@ static bool running = true; class Platform { public: - virtual void Init() = 0; - virtual void SetTitle(const std::string &title) = 0; - virtual void MainLoop() = 0; - virtual void Shutdown() = 0; - virtual ~Platform() {}; + virtual void Init() {} + virtual void SetTitle(const std::string &title) {} + virtual void MainLoop() { while(running) {} } + virtual void Shutdown() {} + virtual ~Platform() {} }; static Platform* platform; @@ -54,7 +54,7 @@ void Host_Message(int Id) running = false; } -static void* s_window_handle; +static void* s_window_handle = nullptr; void* Host_GetRenderHandle() { return s_window_handle; @@ -291,7 +291,9 @@ class PlatformX11 : public Platform static Platform* GetPlatform() { -#if HAVE_X11 +#if defined(USE_EGL) && defined(USE_HEADLESS) + return new Platform(); +#elif HAVE_X11 return new PlatformX11(); #endif return nullptr; |
