mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
[678/906] window_win32_wgl: implement wglGetProcAddress for extension functions
This commit is contained in:
parent
74209b9e9e
commit
d4fabed3e4
1 changed files with 17 additions and 0 deletions
|
@ -49,6 +49,8 @@ static gboolean gst_gl_window_win32_wgl_create_context (GstGLWindowWin32 *
|
|||
static void gst_gl_window_win32_wgl_destroy_context (GstGLWindowWin32 *
|
||||
window_win32);
|
||||
GstGLAPI gst_gl_window_win32_wgl_get_gl_api (GstGLWindow * window);
|
||||
static gpointer gst_gl_window_win32_wgl_get_proc_address (GstGLWindow * window,
|
||||
const gchar * name);
|
||||
|
||||
static void
|
||||
gst_gl_window_win32_wgl_class_init (GstGLWindowWin32WGLClass * klass)
|
||||
|
@ -69,6 +71,8 @@ gst_gl_window_win32_wgl_class_init (GstGLWindowWin32WGLClass * klass)
|
|||
window_win32_class->swap_buffers =
|
||||
GST_DEBUG_FUNCPTR (gst_gl_window_win32_wgl_swap_buffers);
|
||||
|
||||
window_class->get_proc_address =
|
||||
GST_DEBUG_FUNCPTR (gst_gl_window_win32_wgl_get_proc_address);
|
||||
window_class->get_gl_api =
|
||||
GST_DEBUG_FUNCPTR (gst_gl_window_win32_wgl_get_gl_api);
|
||||
}
|
||||
|
@ -206,3 +210,16 @@ gst_gl_window_win32_wgl_get_gl_api (GstGLWindow * window)
|
|||
{
|
||||
return GST_GL_API_OPENGL;
|
||||
}
|
||||
|
||||
static gpointer
|
||||
gst_gl_window_win32_wgl_get_proc_address (GstGLWindow * window,
|
||||
const gchar * name)
|
||||
{
|
||||
gpointer result;
|
||||
|
||||
if (!(result = wglGetProcAddress ((LPCSTR) name))) {
|
||||
result = gst_gl_window_default_get_proc_address (window, name);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue