From ee992ec531e0f0e674530e26845124de88d1a61d Mon Sep 17 00:00:00 2001 From: Matthew Waters Date: Thu, 6 Dec 2012 17:40:47 +1100 Subject: [PATCH] [623/906] move GL includes into a single file --- gst-libs/gst/gl/cocoa/gstglwindow_cocoa.h | 1 + gst-libs/gst/gl/gstglapi.h | 28 +++++++++++-------- .../gst/gl/wayland/gstglwindow_wayland_egl.h | 1 + gst-libs/gst/gl/win32/gstglwindow_win32.h | 1 + gst-libs/gst/gl/win32/gstglwindow_win32_egl.h | 3 +- gst-libs/gst/gl/win32/gstglwindow_win32_wgl.h | 5 +--- gst-libs/gst/gl/x11/gstglwindow_x11.h | 1 + gst-libs/gst/gl/x11/gstglwindow_x11_egl.h | 3 +- gst-libs/gst/gl/x11/gstglwindow_x11_glx.h | 1 + 9 files changed, 25 insertions(+), 19 deletions(-) diff --git a/gst-libs/gst/gl/cocoa/gstglwindow_cocoa.h b/gst-libs/gst/gl/cocoa/gstglwindow_cocoa.h index 37b06b24ea..21b8b650a0 100644 --- a/gst-libs/gst/gl/cocoa/gstglwindow_cocoa.h +++ b/gst-libs/gst/gl/cocoa/gstglwindow_cocoa.h @@ -23,6 +23,7 @@ #include +#include "gstglapi.h" #include "gstglwindow.h" G_BEGIN_DECLS diff --git a/gst-libs/gst/gl/gstglapi.h b/gst-libs/gst/gl/gstglapi.h index 76b9e7a623..da3166a6d4 100644 --- a/gst-libs/gst/gl/gstglapi.h +++ b/gst-libs/gst/gl/gstglapi.h @@ -18,18 +18,19 @@ * Boston, MA 02110-1301, USA. */ -#ifndef __GST_GL_RENDERER_H__ -#define __GST_GL_RENDERER_H__ +#ifndef __GST_GL_API_H__ +#define __GST_GL_API_H__ /* OpenGL 2.0 for Embedded Systems */ -#ifdef HAVE_GLES2 +#if HAVE_GLES2 # include +# include # if !HAVE_OPENGL # include "gstgles2.h" # endif #endif -/* OpenGL for usual systems */ +/* OpenGL for desktop systems */ #if HAVE_OPENGL # if __APPLE__ # include @@ -51,6 +52,12 @@ # define UNICODE #endif +#if HAVE_WGL +# undef UNICODE +# include +# define UNICODE +#endif + #include G_BEGIN_DECLS @@ -69,15 +76,14 @@ typedef enum { typedef enum { GST_GL_PLATFORM_UNKNOWN = 0, - GST_GL_PLATFORM_EGL, - GST_GL_PLATFORM_GLX, - GST_GL_PLATFORM_WGL, - GST_GL_PLATFORM_CGL, + GST_GL_PLATFORM_EGL = (1 << 0), + GST_GL_PLATFORM_GLX = (1 << 1), + GST_GL_PLATFORM_WGL = (1 << 2), + GST_GL_PLATFORM_CGL = (1 << 3), - GST_GL_PLATFORM_ANY = 254, - GST_GL_PLATFORM_LAST = 255 + GST_GL_PLATFORM_ANY = G_MAXUINT32 } GstGLPlatform; G_END_DECLS -#endif /* __GST_GL_WINDOW_H__ */ +#endif /* __GST_GL_API_H__ */ diff --git a/gst-libs/gst/gl/wayland/gstglwindow_wayland_egl.h b/gst-libs/gst/gl/wayland/gstglwindow_wayland_egl.h index e36ec70e11..042ff03e73 100644 --- a/gst-libs/gst/gl/wayland/gstglwindow_wayland_egl.h +++ b/gst-libs/gst/gl/wayland/gstglwindow_wayland_egl.h @@ -25,6 +25,7 @@ #include #include +#include "gstglapi.h" #include "gstglwindow.h" G_BEGIN_DECLS diff --git a/gst-libs/gst/gl/win32/gstglwindow_win32.h b/gst-libs/gst/gl/win32/gstglwindow_win32.h index 7142ddbf80..cd62b8b26c 100644 --- a/gst-libs/gst/gl/win32/gstglwindow_win32.h +++ b/gst-libs/gst/gl/win32/gstglwindow_win32.h @@ -21,6 +21,7 @@ #ifndef __GST_GL_WINDOW_WIN32_H__ #define __GST_GL_WINDOW_WIN32_H__ +#include "gstglapi.h" #include "gstglwindow.h" #undef UNICODE diff --git a/gst-libs/gst/gl/win32/gstglwindow_win32_egl.h b/gst-libs/gst/gl/win32/gstglwindow_win32_egl.h index 93474c7b0f..5e17813d2f 100644 --- a/gst-libs/gst/gl/win32/gstglwindow_win32_egl.h +++ b/gst-libs/gst/gl/win32/gstglwindow_win32_egl.h @@ -21,10 +21,9 @@ #ifndef __GST_GL_WINDOW_WIN32_EGL_H__ #define __GST_GL_WINDOW_WIN32_EGL_H__ -#include - #include +#include "gstglapi.h" #include "gstglwindow_win32.h" G_BEGIN_DECLS diff --git a/gst-libs/gst/gl/win32/gstglwindow_win32_wgl.h b/gst-libs/gst/gl/win32/gstglwindow_win32_wgl.h index df9d9e599a..9a6506e346 100644 --- a/gst-libs/gst/gl/win32/gstglwindow_win32_wgl.h +++ b/gst-libs/gst/gl/win32/gstglwindow_win32_wgl.h @@ -21,12 +21,9 @@ #ifndef __GST_GL_WINDOW_WIN32_WGL_H__ #define __GST_GL_WINDOW_WIN32_WGL_H__ +#include "gstglapi.h" #include "gstglwindow_win32.h" -#undef UNICODE -#include -#define UNICODE - G_BEGIN_DECLS #define GST_GL_TYPE_WINDOW_WIN32_WGL (gst_gl_window_win32_wgl_get_type()) diff --git a/gst-libs/gst/gl/x11/gstglwindow_x11.h b/gst-libs/gst/gl/x11/gstglwindow_x11.h index 0fd99d506f..df3f9d5ed7 100644 --- a/gst-libs/gst/gl/x11/gstglwindow_x11.h +++ b/gst-libs/gst/gl/x11/gstglwindow_x11.h @@ -24,6 +24,7 @@ #include #include +#include "gstglapi.h" #include "gstglwindow.h" G_BEGIN_DECLS diff --git a/gst-libs/gst/gl/x11/gstglwindow_x11_egl.h b/gst-libs/gst/gl/x11/gstglwindow_x11_egl.h index a39641da45..d78cc89b54 100644 --- a/gst-libs/gst/gl/x11/gstglwindow_x11_egl.h +++ b/gst-libs/gst/gl/x11/gstglwindow_x11_egl.h @@ -21,8 +21,7 @@ #ifndef __GST_GL_WINDOW_X11_EGL_H__ #define __GST_GL_WINDOW_X11_EGL_H__ -#include - +#include "gstglapi.h" #include "gstglwindow_x11.h" G_BEGIN_DECLS diff --git a/gst-libs/gst/gl/x11/gstglwindow_x11_glx.h b/gst-libs/gst/gl/x11/gstglwindow_x11_glx.h index 53de719f7e..b9aca83cb8 100644 --- a/gst-libs/gst/gl/x11/gstglwindow_x11_glx.h +++ b/gst-libs/gst/gl/x11/gstglwindow_x11_glx.h @@ -21,6 +21,7 @@ #ifndef __GST_GL_WINDOW_X11_GLX_H__ #define __GST_GL_WINDOW_X11_GLX_H__ +#include "gstglapi.h" #include "gstglwindow_x11.h" G_BEGIN_DECLS