diff --git a/client/include/interface/displayserver.h b/client/include/interface/displayserver.h index 49590e2b..8af237c1 100644 --- a/client/include/interface/displayserver.h +++ b/client/include/interface/displayserver.h @@ -101,6 +101,8 @@ typedef void (* LG_ClipboardReplyFn)(void * opaque, const LG_ClipboardData type, typedef struct LG_DSGLContext * LG_DSGLContext; +typedef struct LGEvent LGEvent; + struct LG_DisplayServerOps { /* called before options are parsed, useful for registering options */ @@ -147,6 +149,12 @@ struct LG_DisplayServerOps void (*glSwapBuffers)(void); #endif + /* Signals event when the next frame should be rendered in time for the next vblank. + * This must be invoked on the render thread before swapping buffers. + * If used, the render thread MUST wait for event before rendering the next frame. + * This is optional and a display server may choose to not implement it. */ + void (*signalNextFrame)(LGEvent * event); + /* dm specific cursor implementations */ void (*guestPointerUpdated)(double x, double y, double localX, double localY); void (*setPointer)(LG_DSPointer pointer);