summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinWX/GLInterface/GLInterface.cpp
diff options
context:
space:
mode:
authorPierre Bourdon <delroth@gmail.com>2014-08-01 23:21:03 -0700
committerPierre Bourdon <delroth@gmail.com>2014-08-02 09:34:39 -0700
commit226a9c239220c5ba99508a6b96ce28903a35be80 (patch)
treebd010cc5aed750806eba69994e004057599af035 /Source/Core/DolphinWX/GLInterface/GLInterface.cpp
parent7e83a0ea9be49abee3a4c8a2e953ca0905271434 (diff)
Move GLInterface around to remove VideoBackends dependency on DolphinWX
Diffstat (limited to 'Source/Core/DolphinWX/GLInterface/GLInterface.cpp')
-rw-r--r--Source/Core/DolphinWX/GLInterface/GLInterface.cpp23
1 files changed, 23 insertions, 0 deletions
diff --git a/Source/Core/DolphinWX/GLInterface/GLInterface.cpp b/Source/Core/DolphinWX/GLInterface/GLInterface.cpp
new file mode 100644
index 0000000000..bb9ce669e2
--- /dev/null
+++ b/Source/Core/DolphinWX/GLInterface/GLInterface.cpp
@@ -0,0 +1,23 @@
+// Copyright 2014 Dolphin Emulator Project
+// Licensed under GPLv2
+// Refer to the license.txt file included.
+
+#include "DolphinWX/GLInterface/GLInterface.h"
+#include "VideoBackends/OGL/GLInterfaceBase.h"
+
+GLWindow GLWin;
+
+cInterfaceBase* HostGL_CreateGLInterface()
+{
+ #if defined(USE_EGL) && USE_EGL
+ return new cInterfaceEGL;
+ #elif defined(__APPLE__)
+ return new cInterfaceAGL;
+ #elif defined(_WIN32)
+ return new cInterfaceWGL;
+ #elif defined(HAVE_X11) && HAVE_X11
+ return new cInterfaceGLX;
+ #else
+ return nullptr;
+ #endif
+}