From 74adfe0cbca300e73774c6e0aa9b3c53a5e5b57b Mon Sep 17 00:00:00 2001 From: Phil Jones Date: Sun, 31 Oct 2021 16:47:03 +0000 Subject: Add HiDPI support and lots of cleanup. --- src/surface.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'src/surface.c') diff --git a/src/surface.c b/src/surface.c index 6253801..76abec9 100644 --- a/src/surface.c +++ b/src/surface.c @@ -5,14 +5,24 @@ #undef MAX #define MAX(a, b) ((a) > (b) ? (a) : (b)) -void surface_initialise(struct surface *surface, struct wl_display *wl_display, struct image *texture) +void surface_initialise( + struct surface *surface, + struct wl_display *wl_display, + struct image *texture) { - egl_create_window(&surface->egl, surface->wl_surface, surface->width, surface->height); + egl_create_window( + &surface->egl, + surface->wl_surface, + surface->width, + surface->height); egl_create_context(&surface->egl, wl_display); gl_initialise(&surface->gl, texture); } -void surface_draw(struct surface *surface, struct color *color, struct image *texture) +void surface_draw( + struct surface *surface, + struct color *color, + struct image *texture) { egl_make_current(&surface->egl); gl_clear(&surface->gl, color); -- cgit v1.2.3