From 624d1371304a5ae4b3429ad5e4267aac7cd03dfd Mon Sep 17 00:00:00 2001 From: Berke Güzel Date: Mon, 12 Oct 2026 00:09:38 +0300 Subject: missing impls and hardening --- src/common/backend.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/common/backend.h') diff --git a/src/common/backend.h b/src/common/backend.h index c1d878b..c6691eb 100644 --- a/src/common/backend.h +++ b/src/common/backend.h @@ -7,12 +7,21 @@ struct yasl_backend_ops; struct yasl_display { const struct yasl_backend_ops *ops; + struct yasl_display_cbs callbacks; }; struct yasl_surface { struct yasl_display *display; + struct yasl_surface_cbs callbacks; + uint64_t frame_generation; }; +static inline uint64_t yasl_frame_begin(struct yasl_surface *s) +{ + if (++s->frame_generation == 0) ++s->frame_generation; + return s->frame_generation; +} + struct yasl_backend_ops { enum yasl_backend type; struct yasl_display *(*display_open)(struct yasl_loop *loop, const struct yasl_display_spec *spec); -- cgit v1.2.3