• Home
  • History
  • Annotate
Name
Date
Size
#Lines
LOC

..--

.gitignoreD22-Nov-20239 21

Android.mkD22-Nov-20234 KiB15587

Makefile.amD22-Nov-20233.7 KiB13998

README.txtD22-Nov-20232 KiB7240

SConscriptD22-Nov-20231 KiB5747

egl.defD22-Nov-2023687 3635

egl.pc.inD22-Nov-2023275 1311

eglapi.cD22-Nov-202342.8 KiB1,5801,097

eglapi.hD22-Nov-202310.3 KiB210126

eglarray.cD22-Nov-20234.7 KiB210123

eglarray.hD22-Nov-20232.3 KiB8632

eglcompiler.hD22-Nov-20233.8 KiB12768

eglconfig.cD22-Nov-202325.3 KiB842608

eglconfig.hD22-Nov-20237.2 KiB227136

eglcontext.cD22-Nov-202317.8 KiB613363

eglcontext.hD22-Nov-20234.1 KiB15367

eglcurrent.cD22-Nov-20238 KiB336221

eglcurrent.hD22-Nov-20232.8 KiB11745

egldefines.hD22-Nov-20231.6 KiB466

egldisplay.cD22-Nov-202310.6 KiB457280

egldisplay.hD22-Nov-20236 KiB242124

egldriver.cD22-Nov-202315.2 KiB715465

egldriver.hD22-Nov-20233.6 KiB12642

eglfallbacks.cD22-Nov-20234.4 KiB12475

eglglobals.cD22-Nov-20232.5 KiB8139

eglglobals.hD22-Nov-20231.8 KiB6215

eglimage.cD22-Nov-20233.3 KiB11863

eglimage.hD22-Nov-20233.7 KiB14964

egllog.cD22-Nov-20235 KiB209119

egllog.hD22-Nov-20231.9 KiB5915

eglmisc.cD22-Nov-20234.9 KiB173100

eglmisc.hD22-Nov-20231.6 KiB436

eglmode.cD22-Nov-20239.6 KiB358225

eglmode.hD22-Nov-20232.7 KiB8930

eglmutex.hD22-Nov-20232.3 KiB8139

eglscreen.cD22-Nov-20235.9 KiB236126

eglscreen.hD22-Nov-20233.5 KiB11740

eglstring.cD22-Nov-20231.7 KiB5515

eglstring.hD22-Nov-20231.8 KiB5115

eglsurface.cD22-Nov-202313.8 KiB531425

eglsurface.hD22-Nov-20234.6 KiB17477

eglsync.cD22-Nov-20233.3 KiB11767

eglsync.hD22-Nov-20233.3 KiB13256

egltypedefs.hD22-Nov-20232.2 KiB7222

README.txt

1 
2 
3 Notes about the EGL library:
4 
5 
6 The EGL code here basically consists of two things:
7 
8 1. An EGL API dispatcher.  This directly routes all the eglFooBar() API
9    calls into driver-specific functions.
10 
11 2. Fallbacks for EGL API functions.  A driver _could_ implement all the
12    EGL API calls from scratch.  But in many cases, the fallbacks provided
13    in libEGL (such as eglChooseConfig()) will do the job.
14 
15 
16 
17 Bootstrapping:
18 
19 When the apps calls eglOpenDisplay() a device driver is selected and loaded
20 (look for dlsym() or LoadLibrary() in egldriver.c).
21 
22 The driver's _eglMain() function is then called.  This driver function
23 allocates, initializes and returns a new _EGLDriver object (usually a
24 subclass of that type).
25 
26 As part of initialization, the dispatch table in _EGLDriver->API must be
27 populated with all the EGL entrypoints.  Typically, _eglInitDriverFallbacks()
28 can be used to plug in default/fallback functions.  Some functions like
29 driver->API.Initialize and driver->API.Terminate _must_ be implemented
30 with driver-specific code (no default/fallback function is possible).
31 
32 
33 A bit later, the app will call eglInitialize().  This will get routed
34 to the driver->API.Initialize() function.  Any additional driver
35 initialization that wasn't done in _eglMain() should be done at this
36 point.  Typically, this will involve setting up visual configs, etc.
37 
38 
39 
40 Special Functions:
41 
42 Certain EGL functions _must_ be implemented by the driver.  This includes:
43 
44 eglCreateContext
45 eglCreateWindowSurface
46 eglCreatePixmapSurface
47 eglCreatePBufferSurface
48 eglMakeCurrent
49 eglSwapBuffers
50 
51 Most of the EGLConfig-related functions can be implemented with the
52 defaults/fallbacks.  Same thing for the eglGet/Query functions.
53 
54 
55 
56 
57 Teardown:
58 
59 When eglTerminate() is called, the driver->API.Terminate() function is
60 called.  The driver should clean up after itself.  eglTerminate() will
61 then close/unload the driver (shared library).
62 
63 
64 
65 
66 Subclassing:
67 
68 The internal libEGL data structures such as _EGLDisplay, _EGLContext,
69 _EGLSurface, etc should be considered base classes from which drivers
70 will derive subclasses.
71 
72