Chia-I Wu
8a6bdf3979
egl: Minor changes to the _EGLConfig interface.
...
Mainly to rename _eglAddConfig to _eglLinkConfig, along with a few clean
ups.
2010-10-23 11:20:40 +08:00
Chia-I Wu
4ce33ec606
egl: Drop dpy argument from the link functions.
...
All display resources are already initialized with a display. Linking
simply links a resource to its display.
2010-10-23 11:20:40 +08:00
Chia-I Wu
25328509c9
egl: Move fallback routines to eglfallbacks.c.
...
We do not want them to be all over the places.
2010-10-22 18:38:30 +08:00
Chia-I Wu
5664a98386
egl: Parse image attributes with _eglParseImageAttribList.
...
Avoid code duplications.
2010-10-22 18:35:09 +08:00
Chia-I Wu
713c8734f4
egl: Move attributes in _EGLImage to _EGLImageAttribs.
...
The opaque nature of EGLImage implies that extensions almost always
define their own attributes. Move attributes in _EGLImage to
_EGLImageAttribs and add a helper function to parse attribute lists.
2010-10-22 17:15:45 +08:00
Chia-I Wu
ecca5571b6
egl_glx: Fix borken driver.
...
The driver was broken since 6eda3f311b .
All configs fail to pass _eglValidateConfig.
2010-10-22 16:26:25 +08:00
Chia-I Wu
0ed96efc1b
egl_glx: Drop the use of [SG]ET_CONFIG_ATTRIB.
...
_EGLConfig can be directly dereferenced now. Since egl_glx is the last
user of the macros, drop the macros too.
2010-10-22 16:26:25 +08:00
Chia-I Wu
b67f7295b7
egl_dri2: Drop the use of _egl[SG]etConfigKey.
...
_EGLConfig can be directly dereferenced now.
2010-10-22 16:26:25 +08:00
Chia-I Wu
3fa21881b1
egl: Access config attributes directly.
...
Replace SET_CONFIG_ATTRIB/GET_CONFIG_ATTRIB by direct dereferences.
2010-10-14 17:16:14 +08:00
Chia-I Wu
282e514240
egl: Use attribute names as the _EGLConfig member names.
...
This makes _EGLConfig more accessible and scales better when new
attributes are added.
2010-10-14 17:14:44 +08:00
Nicolas Kaiser
3b7b1db661
egl: remove duplicated include
...
Remove duplicated include.
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-09-30 09:36:21 -06:00
Chia-I Wu
6b2f1561ad
egl: Check extensions.
...
Do not call into the driver if the extension for the called function is
not enabled.
2010-09-30 16:55:07 +08:00
Ian Romanick
e4bd50c232
egl: Fix several 'comparison between signed and unsigned integer' warnings
...
I hate GCC for requiring the (int) cast on sizeof.
2010-09-24 10:55:38 -07:00
Ian Romanick
66c9ac76ad
egl_glx: Silence piles of 'unused variable' warnings
2010-09-24 10:55:38 -07:00
Ian Romanick
137fce247f
EGL DRI2: Silence 'missing initializer' warnings
2010-09-24 09:40:06 -07:00
Ian Romanick
eade946cbf
EGL DRI2: Silence piles of 'unused variable' warnings
2010-09-24 09:40:06 -07:00
Kristian Høgsberg
17eace581d
dri: Pass the __DRIscreen and the __DRIscreen private back to image lookup
...
We will typically have a current context when we need to lookup the image,
but the lookup implementation don't need it so drop it.
2010-09-22 22:02:05 -04:00
Kristian Høgsberg
9ec0b2a45e
dri2: Make createImageFromName() take a __DRIscreen instead of __DRIcontext
...
We can't expect to have a context when this is called, and we don't need one
so just require a __DRIscreen instead.
Reported by Yu Dai <yu.dai@intel.com>
2010-09-22 15:08:22 -04:00
Chia-I Wu
e7424d7240
st/egl: Rename kms backend to drm.
...
The main use of the backend is to support EGL_MESA_drm_display. drm
should be a better name.
2010-09-19 17:19:03 +08:00
Jesse Barnes
e7eff0cfce
EGL DRI2: 0xa011 is Pineview not Ironlake
...
Point about needing a better way to do this validated.
2010-09-13 10:55:56 -07:00
Jesse Barnes
c121608b6e
EGL DRI2: add PCI ID for Ironlake mobile
...
Allows KMS EGL driver to load. We need a better way of doing this.
2010-09-13 10:36:46 -07:00
Chia-I Wu
ea9e5dbbc2
egl: Simplify _eglBindContext.
...
Remove the hard-to-get-right _eglBindContextToSurfaces. As well as fix
an assertion failure from b90a3e7d8b when
such call sequence is hit
eglMakeCurrent(dpy, surf1, surf1, ctx1);
eglMakeCurrent(dpy, surf2, surf2, ctx2);
eglMakeCurrent(dpy, surf1, surf1, ctx1);
2010-09-10 18:41:14 +08:00
Kristian Høgsberg
6eda3f311b
eglglx: Convert glx visuals/fbconfigs straight to EGL configs
...
In other words, skip the __GLcontextModes middle man.
2010-09-09 15:00:18 -04:00
Kristian Høgsberg
01a7eebc4c
egl: Remove old egldri driver
...
This driver doesn't work with any of the DRI drivers in the source tree.
2010-09-09 14:05:30 -04:00
Chia-I Wu
916c8ed2c8
egl: Use _EGL_CHECK_DISPLAY in eglCreateContext.
...
_EGL_CHECK_DISPLAY checks the display and returns from eglCreateContext
on error.
2010-09-10 00:18:23 +08:00
Chia-I Wu
08a482e7a9
egl: Display may be NULL in _eglLookup*.
...
This fixes several NULL dereferences.
2010-09-10 00:18:14 +08:00
Chia-I Wu
8cdeff8444
egl: Mark EGL_MESA_screen_surface as obsolete.
...
EGL_MESA_drm_{display,image} can achieve the same functionality.
2010-08-31 15:25:22 +08:00
Kristian Høgsberg
5aaa53e66c
egl_dri2: Add support for MESA_image_drm
2010-08-25 09:17:48 -04:00
Kristian Høgsberg
b7a8893a24
egl: Add EGL_MESA_drm_image extension
...
Create EGLImages from DRM buffer handles.
2010-08-25 09:17:47 -04:00
Chia-I Wu
5eb33596a0
egl: Fix context API check and be verbose.
...
The API of the context was not checked against EGL_RENDERABLE_TYPE when there
was no attribute list. Move the check to _eglInitContext, and be verbose about
common mistakes (EGL_RENDERABLE_TYPE not set, EGL_CONTEXT_CLIENT_VERSION not
set, or eglBindAPI not called).
2010-08-20 19:22:51 +08:00
Chia-I Wu
ce2cae4130
egl: Add egl.def for win32 build.
...
Without the .def file, function names are decorated and cannot be
queried by GetProcAddress easily.
2010-08-20 19:22:50 +08:00
Chia-I Wu
f508c0c097
egl: Allow core functions to be queried.
...
When _EGL_GET_CORE_ADDRESSES is defined, eglGetProcAddress can be used to query
core functions. This is non-standard, but some apps expect it.
2010-08-20 19:22:35 +08:00
Chia-I Wu
ce29e86458
st/egl: Fix win32 build.
...
Add new source files to SConscripts.
2010-08-19 14:07:29 +08:00
Chia-I Wu
2b2c5c4f5c
egl: Add support for EGL_KHR_fence_sync.
...
Individual drivers still need to support and enable the extension.
2010-08-17 00:06:19 +08:00
Chia-I Wu
4eebea74a8
egl: Add support for EGL_KHR_reusable_sync.
...
Individual drivers still need to support and enable the extension.
2010-08-17 00:06:19 +08:00
Vinson Lee
db71bdc31c
egl: Fix '_eglAddAtExitCall' implicit declaration warning.
2010-07-31 13:28:32 -07:00
Chia-I Wu
6c7e0b95a4
egl: Add checks for EGL_MESA_screen_surface.
...
This allows Mesa EGL to be compiled with eglext.h that does not define
EGL_MESA_screen_surface.
2010-07-31 17:49:32 +08:00
Kristian Høgsberg
e8a72460b7
egl_dri2: Set API version for DRM display
2010-07-29 15:08:00 -04:00
Kristian Høgsberg
2c343af098
egl: Fix deref before NULL-check
2010-07-28 23:54:16 -04:00
Kristian Høgsberg
efd4a8cffd
egl_dri2: Implement EGL_KHR_surfaceless_* extensions
2010-07-28 23:07:09 -04:00
Kristian Høgsberg
b90a3e7d8b
egl: EGL_KHR_surfaceless_* extensions
...
These extensions allow an application to make a context current by
passing EGL_NO_SURFACE for the write and read surface in the call to
eglMakeCurrent. The motivation is that applications that only want to
render to client API targets (such as OpenGL framebuffer objects)
should not need to create a throw-away EGL surface just to get a
current context.
2010-07-28 23:07:00 -04:00
Chia-I Wu
d7284b45e2
egl: Return the correct array size in _eglFlattenArray.
...
The function is used by _eglGetConfigs and _eglGetScreens. The array
size should not be limited by the buffer size when the buffer is NULL.
This fixes fdo bug #29052 .
2010-07-15 10:05:46 +08:00
Kristian Høgsberg
2168b87b51
egl_dri2: Support _EGL_PLATFORM_DRM
...
This lets the egl_dri2 driver initialize on just a DRM fd.
2010-07-08 20:10:37 -04:00
Vinson Lee
ff318c45ec
egl: Remove unnecessary headers.
2010-07-06 16:02:49 -07:00
Chia-I Wu
f2aa361f3b
egl: Rework driver loading.
...
Driver loading is now splitted into two stages. In the first stage, an
_EGLModule is created for each driver: user driver, default drivers, and
all files in the search directories that start with "egl_". Modules are
not loaded at this stage.
In the second stage, each module is loaded to initialize a display. The
process stops at the first module that can initialize the display.
If eglGetProcAddress is called before eglInitialize, the same code path
will be taken to find the first module that supports
EGL_DEFAULT_DISPLAY. Because we do not want to initialize the display,
drv->Probe is used instead in this case.
2010-07-06 16:16:39 +08:00
nobled
c43ab4fe1f
egl: Always use EGLAPIENTRY in api function prototypes
...
Fixes the build on Windows.
2010-07-03 16:36:43 +08:00
Chia-I Wu
a8815b754d
egl: Update MaxSize when a dynamic array is grown.
2010-06-30 18:52:00 +08:00
Chia-I Wu
98ebc8165c
egl: Make _eglUnloadDrivers no-op on Windows.
...
Windows unloads DLLs before atexit. Make _eglUnloadDrivers no-op on
Windows for now.
2010-06-30 18:32:48 +08:00
Chia-I Wu
8b0c6c4a8d
egl: Store screens in a dynamic array.
2010-06-30 18:32:48 +08:00
Chia-I Wu
6717a313f2
egl: Store configs in a dynamic array.
2010-06-30 18:32:48 +08:00