Mir
weak_egl.h
Go to the documentation of this file.
1 /*
2  * EGL without any linkage requirements!
3  * ~~~
4  * Copyright © 2015 Canonical Ltd.
5  *
6  * This program is free software: you can redistribute it and/or modify it
7  * under the terms of the GNU Lesser General Public License version 3,
8  * as published by the Free Software Foundation.
9  *
10  * This program is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public License
16  * along with this program. If not, see <http://www.gnu.org/licenses/>.
17  *
18  * Authored by: Daniel van Vugt <daniel.van.vugt@canonical.com>
19  */
20 
21 #ifndef MIR_CLIENT_WEAK_EGL_H_
22 #define MIR_CLIENT_WEAK_EGL_H_
23 
24 #include <EGL/egl.h>
25 #include <dlfcn.h>
26 
27 namespace mir { namespace client {
28 
29 class WeakEGL
30 {
31 public:
32  WeakEGL();
33  ~WeakEGL();
34  EGLBoolean eglGetConfigAttrib(EGLDisplay dpy, EGLConfig config,
35  EGLint attribute, EGLint* value);
36 
37 private:
38  bool find(char const* name, void** func);
39 
40  void* egl1;
41  EGLBoolean (*pGetConfigAttrib)(EGLDisplay dpy, EGLConfig config,
42  EGLint attribute, EGLint* value);
43 };
44 
45 }} // namespace mir::client
46 
47 #endif // MIR_CLIENT_WEAK_EGL_H_
All things Mir.
Definition: atomic_callback.h:25
Definition: weak_egl.h:29
WeakEGL()
Definition: weak_egl.cpp:26
EGLBoolean eglGetConfigAttrib(EGLDisplay dpy, EGLConfig config, EGLint attribute, EGLint *value)
Definition: weak_egl.cpp:38
~WeakEGL()
Definition: weak_egl.cpp:32

Copyright © 2012-2015 Canonical Ltd.
Generated on Wed Mar 30 00:29:56 UTC 2016