mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-20 23:36:38 +00:00
[678/906] window_win32_wgl: implement wglGetProcAddress for extension functions
This commit is contained in:
parent
ed98971953
commit
b9a10f8e15
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