19 #ifndef MIR_EXAMPLES_CLIENT_HELPERS_H_ 20 #define MIR_EXAMPLES_CLIENT_HELPERS_H_ 24 #include <GLES2/gl2.h> 35 Connection(
char const* socket_file,
const char* name);
51 bool prefer_alpha =
false,
52 bool hardware =
true);
63 std::unique_ptr<MirBufferStream, decltype(&mir_buffer_stream_release_sync)>
const stream;
76 MirSurface* create_surface(
MirConnection* connection,
unsigned int width,
unsigned int height,
bool prefers_alpha,
bool hardware);
77 std::function<void(MirSurface*)>
const surface_deleter{
80 std::unique_ptr<MirSurface, decltype(surface_deleter)> surface;
90 void release_current();
95 EGLConfig chooseconfig(EGLDisplay disp);
96 EGLNativeDisplayType native_display;
100 Display(EGLNativeDisplayType native);
114 EglContext(EGLDisplay disp, EGLConfig config);
116 EGLint context_attribs[3] = { EGL_CONTEXT_CLIENT_VERSION, 2, EGL_NONE };
124 Shader(GLchar
const*
const* src, GLuint type);
All things Mir.
Definition: atomic_callback.h:25
bool make_current(mrg::RenderTarget *render_target)
Definition: server_example_adorning_compositor.cpp:39
Definition: mir_surface.h:147
Definition: client_helpers.h:129
~Connection()
Definition: client_helpers.cpp:44
Definition: client_helpers.h:69
GLuint shader
Definition: client_helpers.h:126
Connection & operator=(Connection const &)=delete
Connection(char const *socket_file)
Definition: client_helpers.cpp:39
unsigned int width
Definition: touchspot_image.c:4
Definition: client_helpers.h:122
Definition: client_helpers.h:44
GLuint program
Definition: client_helpers.h:133
unsigned int height
Definition: touchspot_image.c:5
Definition: mir_connection.h:96
Definition: client_helpers.h:85
#define EGLNativeWindowType
Definition: client_buffer_stream.h:55
Definition: client_helpers.h:31