aboutsummaryrefslogtreecommitdiff
path: root/src/waffle/glx/glx_platform.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/waffle/glx/glx_platform.h')
-rw-r--r--src/waffle/glx/glx_platform.h32
1 files changed, 19 insertions, 13 deletions
diff --git a/src/waffle/glx/glx_platform.h b/src/waffle/glx/glx_platform.h
index e779975..f61c169 100644
--- a/src/waffle/glx/glx_platform.h
+++ b/src/waffle/glx/glx_platform.h
@@ -23,23 +23,29 @@
// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-/// @defgroup glx_platform glx_platform
-/// @ingroup glx
-/// @{
+#pragma once
-/// @file
+#include <GL/glx.h>
+#include <X11/Xlib.h>
+#include <xcb/xcb.h>
+#undef linux
-#pragma once
+#include <waffle/core/wcore_platform.h>
+#include <waffle/core/wcore_util.h>
-#include <stdbool.h>
+struct linux_platform;
-struct native_dispatch;
-union native_platform;
+struct glx_platform {
+ struct wcore_platform wcore;
+ struct linux_platform *linux;
-union native_platform*
-glx_platform_create(const struct native_dispatch **dispatch);
+ PFNGLXCREATECONTEXTATTRIBSARBPROC glXCreateContextAttribsARB;
+};
-bool
-glx_platform_destroy(union native_platform *self);
+DEFINE_CONTAINER_CAST_FUNC(glx_platform,
+ struct glx_platform,
+ struct wcore_platform,
+ wcore)
-/// @}
+struct wcore_platform*
+glx_platform_create(void);