shared/platform.h: introduce weston_platform_destroy_egl_surface()
Introduce the weston_platform_destroy_egl_surface() wrapper to complement the weston_platform_create_egl_surface() one. We'll use the former with the next patches trhoughout weston to consistently destroy the surface as needed. Signed-off-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Daniel Stone <daniels@collabora.com>
This commit is contained in:
committed by
Daniel Stone
parent
43cea54c90
commit
3612be2302
@@ -128,6 +128,13 @@ weston_platform_create_egl_surface(EGLDisplay dpy, EGLConfig config,
|
|||||||
attrib_list);
|
attrib_list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline EGLBoolean
|
||||||
|
weston_platform_destroy_egl_surface(EGLDisplay display,
|
||||||
|
EGLSurface surface)
|
||||||
|
{
|
||||||
|
return eglDestroySurface(display, surface);
|
||||||
|
}
|
||||||
|
|
||||||
#else /* ENABLE_EGL */
|
#else /* ENABLE_EGL */
|
||||||
|
|
||||||
static inline void *
|
static inline void *
|
||||||
@@ -144,6 +151,13 @@ weston_platform_create_egl_surface(void *dpy, void *config,
|
|||||||
{
|
{
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline unsigned int
|
||||||
|
weston_platform_destroy_egl_surface(void *display,
|
||||||
|
void *surface)
|
||||||
|
{
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
#endif /* ENABLE_EGL */
|
#endif /* ENABLE_EGL */
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
|||||||
Reference in New Issue
Block a user