Revert "wayland/egl: use redraw callback"

Because of this commit there were problems displaying the frmase in their right
order.

This reverts commit 96e75d234a.

Conflicts:
	video/out/gl_wayland.c
	video/out/wayland_common.h
This commit is contained in:
Alexander Preisinger 2014-01-04 21:04:11 +01:00 committed by wm4
parent 59f970d492
commit 6f5dfb5102
2 changed files with 1 additions and 28 deletions

View File

@ -196,35 +196,10 @@ static void releaseGlContext_wayland(MPGLContext *ctx)
wl->egl_context.egl.ctx = NULL;
}
static const struct wl_callback_listener frame_listener;
static void frame_handle_redraw(void *data,
struct wl_callback *callback,
uint32_t time)
{
MPGLContext *ctx = data;
struct vo_wayland_state *wl = ctx->vo->wayland;
if (callback)
wl_callback_destroy(callback);
wl->egl_context.redraw_callback = wl_surface_frame(wl->window.surface);
wl_callback_add_listener(wl->egl_context.redraw_callback, &frame_listener, ctx);
eglSwapBuffers(wl->egl_context.egl.dpy, wl->egl_context.egl_surface);
}
static const struct wl_callback_listener frame_listener = {
frame_handle_redraw
};
static void swapGlBuffers_wayland(MPGLContext *ctx)
{
struct vo_wayland_state *wl = ctx->vo->wayland;
if (!wl->egl_context.redraw_callback)
frame_handle_redraw(ctx, NULL, 0);
eglSwapBuffers(wl->egl_context.egl.dpy, wl->egl_context.egl_surface);
}
static int control(struct vo *vo, int *events, int request, void *data)

View File

@ -60,8 +60,6 @@ struct vo_wayland_state {
EGLContext ctx;
EGLConfig conf;
} egl;
struct wl_callback * redraw_callback;
} egl_context;
#endif