diff options
author | James Magahern <james@magahern.com> | 2019-01-18 11:47:51 -0800 |
---|---|---|
committer | James Magahern <james@magahern.com> | 2019-01-18 11:47:51 -0800 |
commit | 2f17e8f82ab0f7725d3cf2253a3cc81980456c7a (patch) | |
tree | 98198eff006a0c3df9d8e7e33387762c5a26585f /src/x11_support.h | |
parent | Split out to render.c (diff) |
Started to split x11 stuff to separate files
Diffstat (limited to 'src/x11_support.h')
-rw-r--r-- | src/x11_support.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/x11_support.h b/src/x11_support.h new file mode 100644 index 0000000..2c24c98 --- /dev/null +++ b/src/x11_support.h @@ -0,0 +1,20 @@ +/* + * x11_support.h + * + * Relevant helper functions for acquiring a drawing surface on X11 + * Created by buzzert <buzzert@buzzert.net> 2019-01-18 + */ + +#pragma once + +#include <cairo/cairo.h> +#include <cairo-xlib.h> +#include <X11/Xlib.h> +#include <X11/Xutil.h> + +// Sets up a window and returns a cairo_surface to draw onto +cairo_surface_t* x11_helper_acquire_cairo_surface(int width, int height); + +// Cleanup +void x11_helper_destroy_surface(cairo_surface_t *surface); + |