Commit graph

17 commits

Author SHA1 Message Date
Matthew Waters
1a6fe3db40 glcontext/wgl: implement gl3 core profile context selection 2015-08-10 15:46:13 +02:00
Matthew Waters
83995c0935 context/glx: only use glXCreateContextAttribs for OpenGL 3 contexts
mesa for example when creating a GL 3.1 compatibility context
overrides our context profile selection to create a core context.
2015-08-08 15:32:17 +02:00
Matthew Waters
dbcae77e02 glcontext: pass display to implentation's _new()
This allows the context to fail creation based on incompatible
display type's. e.g. glx context with an wayland display handle.

https://bugzilla.gnome.org/show_bug.cgi?id=752743
2015-07-27 18:23:17 +10:00
Matthew Waters
74711c214d glcontext: consolidate get_proc_address function definition
Pass the GstGLAPI directly.
2015-07-18 17:10:04 +10:00
Matthew Waters
e96431e9b1 glcontext/glx: try creating a context with the highest version
nvidia drivers return the exact version in glGstString (GL_VERSION)
we request on creation so start with the highest known version and
work our way down.
2015-07-18 16:31:43 +10:00
Julien Isorce
48751c8d8a glcontext_glx: rename variable from window to context 2015-05-27 17:10:19 +01:00
Matthew Waters
2c24b97cf0 glx: ask for a GL3 core context 2014-11-28 09:14:25 +11:00
Matthew Waters
567185a277 glcontext: add more functionality to wrapped contexts
Implements get_current_context() and get_proc_address() for wrapped
contexts.
2014-10-30 18:58:50 +11:00
Matthew Waters
81ceca1aea glcontext: add api for retreiving the current context and api
that is current in the calling thread.
2014-10-28 17:33:20 +11:00
Matthew Waters
95a4585d4c glcontext: implement the debug callback
For both GL_KHR_debug and ARB_debug_output.  This allows us to
receive errors and other hints from the GL instead of querying after
every GL operation.
2014-08-20 23:26:26 +10:00
Sebastian Dröge
cad1bb32c8 gl: Try harder to load symbols from the correct place
This commit makes the loading of the GModules threadsafe, and
always first tries to load the symbol for the GL library that
is selected for the current context. Only then it falls back
to looking into the current module (NULL), and only as a last
resort the context specific function (e.g. eglGetProcAddress())
is called.

Also add configure parameters to select the names of the library
modules instead of using the defaults, and let the defaults be
independent of the G_MODULE_SUFFIX.

https://bugzilla.gnome.org/show_bug.cgi?id=728753
2014-05-01 14:36:54 +02:00
Matthew Waters
7d2d3b3b80 gl/glx: use the context's display rather than asking for the window's 2014-04-02 22:53:10 +11:00
Matthew Waters
c3146c0d48 [901/906] glx: use the display handle from the global display
Intel drivers require the display handles be the same for context
sharing to occur.  Also solves some cases of use after free of the
display when integrating with gstreamer-vaapi.

See https://bugs.freedesktop.org/show_bug.cgi?id=41736 for the intel bug.
2014-03-15 18:37:07 +01:00
Matthew Waters
3ad466945e [891/906] context: add support for wrapping external contexts 2014-03-15 18:37:07 +01:00
Matthew Waters
311592f8b1 [807/906] context: Move some window error enums to context 2014-03-15 18:37:02 +01:00
Matthew Waters
b24021b1ac [801/906] context: Reimplement GL context sharing
https://bugzilla.gnome.org/show_bug.cgi?id=704806
2014-03-15 18:37:01 +01:00
Matthew Waters
95c08c2ee2 [794/906] context: add subclasses for the different platforms (egl, glx, wgl, etc)
- most code taken from the Window subclasses
- tested combinations: xEGL, GLX, Wayland+EGL, Cocoa (under GNUStep), WGL (Wine)
2014-03-15 18:37:01 +01:00