summaryrefslogtreecommitdiffstats
path: root/src/egl/main/egldisplay.h
Commit message (Collapse)AuthorAgeFilesLines
* egl: remove _EGL_PLATFORM_WINDOWS enumEmil Velikov2015-07-221-1/+0
| | | | | Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* egl: remove final references of platform_nullEmil Velikov2015-07-221-1/+0
| | | | | Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* egl: sort extension lists alphabeticallyMarek Olšák2015-07-031-25/+23
| | | | and add the missing KHR_gl_colorspace case.
* egl/dri2: implement platform_surfacelessHaixia Shi2015-06-161-0/+1
| | | | | | | | | | | | | | | | | | The surfaceless platform is for off-screen rendering only. Render node support is required. Only consider the render nodes. Do not use normal nodes as they require auth hooks. v3: change platform_null to platform_surfaceless v4: make libdrm required for surfaceless v5: remove modified include guards with defined(HAVE_SURFACELESS_PLATFORM) v6: use O_CLOEXEC for drm fd Signed-off-by: Haixia Shi <[email protected]> Signed-off-by: Zach Reizner <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: expose EGL 1.5 if all requirements are metMarek Olšák2015-06-051-0/+1
| | | | | | | | There's no driver support yet, because EGL_KHR_gl_colorspace isn't implemented. Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: combine VersionMajor and VersionMinor into one variableMarek Olšák2015-06-051-2/+1
| | | | | Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: remove remaining EGL_MESA_copy_context skeletonEmil Velikov2015-05-141-1/+0
| | | | | | | | | | With earlier commit (7a58262e58d egl: Remove skeleton implementation of EGL_MESA_screen_surface) we've removed the skeleton implementation of eglCopyContextMESA(). Just like EGL_MESA_screen_surface this extension was never implemented in mesa. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Adam Jackson <[email protected]>
* egl: Add needed extern "C" for C++ accessAlexander von Gluck IV2015-05-141-0/+9
| | | | | | * Haiku's egl driver is C++ due to the interface natively being C++ Reviewed-⁠by: Brian Paul <[email protected]>
* egl: Remove skeleton implementation of EGL_MESA_screen_surfaceAdam Jackson2015-05-111-1/+0
| | | | | | | | No backend wires this up to anything, and the extension spec has been marked obsolete for 4+ years. Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Adam Jackson <[email protected]>
* egl/dri2: implement EGL_KHR_cl_event2 (v2)Marek Olšák2015-04-301-0/+1
| | | | v2: fix the SYNC_CONDITION query
* egl/dri2: implement EGL_KHR_wait_syncMarek Olšák2015-04-301-0/+1
|
* egl: add initial EGL_MESA_image_dma_buf_export v2.4Dave Airlie2015-04-011-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | At the moment to get an EGL image to a dma-buf file descriptor, you have to use EGL_MESA_drm_image, and then use libdrm to convert this to a file descriptor. This extension just provides an API modelled on EGL_MESA_drm_image, to return a dma-buf file descriptor. v2: update spec for new API proposal add internal queries to get the fourcc back from intel driver. v2.1: add gallium pieces. v2.2: add offsets to spec and API, rename fd->fds, stride->strides in API. rewrite spec a bit more, add some q/a v2.3: add modifiers to query interface and 64-bit type for that (Daniel Stone) specifiy what happens to num fds vs num planes differences. (Chad Versace) v2.4: fix grammar (Daniel Stone) Signed-off-by: Dave Airlie <[email protected]>
* egl: cut down static storage size for {Version,ClientAPI}StringEmil Velikov2015-03-211-2/+2
| | | | | | | | | | | Both seems to be excessively long, namely: ClientAPIString can get up-to 47 based on current code, while the name of the driver can dictate the length of the VersionString, currently it is around 11. Let's pad each to 100, rather than the current 1000. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* egl/main: drop platform fbdev specific codeEmil Velikov2015-03-211-1/+0
| | | | | | | st/egl was the only one which had support for this platform. Signed-off-by: Emil Velikov <[email protected]> Acked-by: Matt Turner <[email protected]>
* egl/main: use c11/threads' mutex directlyEmil Velikov2015-03-111-2/+2
| | | | | | | Remove the inline wrappers/abstraction layer. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* Revert "egl/main: use c11/threads' mutex directly"Emil Velikov2015-03-061-2/+2
| | | | | | This reverts commit 6cee785c69a5c8d2d32b6807f9c502117f5a74b0. Not meant to go in yet. Lacking review.
* egl/main: use c11/threads' mutex directlyEmil Velikov2015-03-061-2/+2
| | | | | | Remove the inline wrappers/abstraction layer. Signed-off-by: Emil Velikov <[email protected]>
* egl/main: no longer export internal functionEmil Velikov2015-03-051-5/+5
| | | | | | | | | | | | With the split of the gallium egl module we had previously it required access to some of the internal functions. As the only build (automake) that did this no longer builds it we can now appropriately hide those functions. Cc: 10.5 <[email protected]> Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Matt Turner <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* egl/main: replace INLINE with inlineEmil Velikov2015-03-051-3/+4
| | | | | | | | | | Drop the custom keyword in favour of the C99 one. All the places using it now directly include c99_compat.h which should handle things on platforms which lack it. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Matt Turner <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* egl: Add Haiku code and supportAlexander von Gluck IV2014-12-231-0/+1
| | | | | | | * This is the cleaned up work of the Haiku GCI student Adrián Arroyo Calle [email protected] * Several patches were consolidated to prevent unnecessary touching of non-related code
* egl: Expose EGL_KHR_get_all_proc_addresses and its client extensionChad Versace2014-12-071-0/+1
| | | | | | | | | Mesa already implements the behavior of EGL_KHR_get_all_proc_addresses and EGL_KHR_client_get_all_proc_addresses. This patch just exposes the extension strings. See: https://www.khronos.org/registry/egl/extensions/KHR/EGL_KHR_get_all_proc_addresses.txt Signed-off-by: Chad Versace <[email protected]>
* egl: Add EGL_CHROMIUM_sync_control extension.Sarah Sharp2014-05-201-0/+2
| | | | | | | | | | | | | | | | | | | | | Chromium defined a new GL extension (that isn't registered with Khronos). We need to add an EGL extension for it, so we can migrate ChromeOS on Intel systems to use EGL instead of GLX. http://git.chromium.org/gitweb/?p=chromium/src/third_party/khronos.git;a=commitdiff;h=27cbfdab35c601f70aa150581ad1448d0401f447 The EGL_CHROMIUM_sync_control extension is similar to the GLX extension OML_sync_control, but only defines one function, eglGetSyncValuesCHROMIUM, which is equivalent to glXGetSyncValuesOML. http://www.opengl.org/registry/specs/OML/glx_sync_control.txt Signed-off-by: Sarah Sharp <[email protected]> Reviewed-by: Chad Versace <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Cc: Jamey Sharp <[email protected]> Cc: Ian Romanick <[email protected]> Cc: Stéphane Marchesin <[email protected]>
* egl/main: Enable Linux platform extensionsChad Versace2014-03-171-0/+20
| | | | | | | | | | | | | | | | Enable EGL_EXT_platform_base and the Linux platform extensions layered atop it: EGL_EXT_platform_x11, EGL_EXT_platform_wayland, and EGL_MESA_platform_gbm. Tested with Piglit's EGL_EXT_platform_base tests under an X11 session. To enable running the Wayland and GBM tests, windowed Weston was running and the kernel had render nodes enabled. I regression tested my EGL_EXT_platform_base patch set with Piglit on Ivybridge under X11/EGL, standalone Weston, and GBM with rendernodes. No regressions found. Signed-off-by: Chad Versace <[email protected]>
* egl/main: Stop using EGLNative types internallyChad Versace2014-03-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Internally, much of the EGL code uses EGLNativeDisplayType, EGLNativeWindowType, and EGLPixmapType. However, the EGLNative type often does not match the variable's actual type. The concept of EGLNative types are a bad match for Linux, as explained below. And the EGL platform extensions don't use EGLNative types at all. Those extensions attempt to solve cross-platform issues by moving the EGL API away from the EGLNative types. The core of the problem is that eglplatform.h can define each EGLNative type once only, but Linux supports multiple EGL platforms. To work around the problem, Mesa's eglplatform.h contains multiple definitions of each EGLNative type, selected by feature macros. Mesa expects EGL clients to set the feature macro approrpiately. But the feature macros don't work when a single codebase must be built with support for multiple EGL platforms, *such as Mesa itself*. When building libEGL, autotools chooses the EGLNative typedefs based on the first element of '--with-egl-platforms'. For example, '--with-egl-platforms=x11,drm,wayland' defines the following: typedef Display* EGLNativeDisplayType; typedef Window EGLNativeWindowType; typedef Pixmap EGLNativePixmapType; Clearly, this doesn't work well for Wayland and GBM. Mesa works around the problem by casting the EGLNative types to different things in different files. For sanity's sake, and to prepare for the EGL platform extensions, this patch removes from egl/main and egl/dri2 all internal use of the EGLNative types. It replaces them with 'void*' and checks each explicit cast with a static assertion. Also, the patch touches egl_gallium the minimal amount to keep it compatible with eglapi.h. Signed-off-by: Chad Versace <[email protected]>
* Add the EGL_MESA_configless_context extensionNeil Roberts2014-03-121-0/+1
| | | | | | | | | | | | | | | | | | | | This extension provides a way for an application to render to multiple surfaces with different buffer formats without having to use multiple contexts. An EGLContext can be created without an EGLConfig by passing EGL_NO_CONFIG_MESA. In that case there are no restrictions on the surfaces that can be used with the context apart from that they must be using the same EGLDisplay. _mesa_initialze_context can now take a NULL gl_config which will mark the context as ‘configless’. It will memset the visual to zero in that case. Previously the i965 and i915 drivers were explicitly creating a zeroed visual whenever 0 is passed for the EGLConfig. Mesa needs to be aware that the context is configless because it affects the initial value to use for glDrawBuffer. The first time the context is bound it will set the initial value for configless contexts depending on whether the framebuffer used is double-buffered. Reviewed-by: Kristian Høgsberg <[email protected]>
* s/Tungsten Graphics/VMware/José Fonseca2014-01-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tungsten Graphics Inc. was acquired by VMware Inc. in 2008. Leaving the old copyright name is creating unnecessary confusion, hence this change. This was the sed script I used: $ cat tg2vmw.sed # Run as: # # git reset --hard HEAD && find include scons src -type f -not -name 'sed*' -print0 | xargs -0 sed -i -f tg2vmw.sed # # Rename copyrights s/Tungsten Gra\(ph\|hp\)ics,\? [iI]nc\.\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./g /Copyright/s/Tungsten Graphics\(,\? [iI]nc\.\)\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./ s/TUNGSTEN GRAPHICS/VMWARE/g # Rename emails s/[email protected]/[email protected]/ s/[email protected]/[email protected]/g s/jrfonseca-at-tungstengraphics-dot-com/jfonseca-at-vmware-dot-com/ s/jrfonseca\[email protected]/[email protected]/g s/keithw\[email protected]/[email protected]/g s/[email protected]/[email protected]/g s/thomas-at-tungstengraphics-dot-com/thellstom-at-vmware-dot-com/ s/[email protected]/[email protected]/ # Remove dead links s@Tungsten Graphics (http://www.tungstengraphics.com)@Tungsten Graphics@g # C string src/gallium/state_trackers/vega/api_misc.c s/"Tungsten Graphics, Inc"/"VMware, Inc"/ Reviewed-by: Brian Paul <[email protected]>
* wayland: Add an extension to create wl_buffers from EGLImagesNeil Roberts2013-12-041-0/+1
| | | | | | | | | | | | | | | | | | This adds an extension called EGL_WL_create_wayland_buffer_from_image which adds the following single function: struct wl_buffer * eglCreateWaylandBufferFromImageWL(EGLDisplay dpy, EGLImageKHR image); The function creates a wl_buffer which shares its contents with the given EGLImage. The expected use case for this is in a nested Wayland compositor which is using subsurfaces to present buffers from its clients. Using this extension it can attach the client buffers directly to the subsurface without having to blit the contents into an intermediate buffer. The compositing can then be done in the parent compositor. The extension is only implemented in the Wayland EGL platform because of course it wouldn't make sense anywhere else.
* egl: definitions for EXT_image_dma_buf_importTopi Pohjolainen2013-08-021-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As specified in: http://www.khronos.org/registry/egl/extensions/EXT/EGL_EXT_image_dma_buf_import.txt Checking for the valid fourcc values is left for drivers avoiding dependency to drm header files here. v2: enforce EGL_NO_CONTEXT v3: declare the extension as EGL (not GLES) v4: do not update eglext.h manually but rely on update from Khronos instead v5: (Eric) report invalid context as EGL_BAD_PARAMETER instead of as EGL_BAD_CONTEXT v6: (Chad) fix the checking for valid hints. Before all values were rejected. v7: (Chad) comment style change from /** * Multi- * line into /* Multi- * line Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: Add extension infrastructure for EGL_EXT_swap_buffers_with_damageRobert Bragg2013-05-071-0/+1
| | | | | Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Kristian Høgsberg <[email protected]>
* egl: Add extension infrastructure for EGL_EXT_buffer_ageKristian Høgsberg2013-01-041-0/+1
|
* egl: Implement front-end support for EGL_EXT_create_context_robustnessIan Romanick2012-08-141-0/+2
| | | | | Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* egl: Implement front-end support for EGL_KHR_create_contextIan Romanick2012-08-141-0/+1
| | | | | Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* egl: Replace KHR_surfaceless_* extensions with KHR_surfaceless_contextIan Romanick2012-08-061-3/+1
| | | | | | | | | | | | KHR extension name is reserved for Khronos ratified extensions, and there is no such thing as EGL_KHR_surfaceless_{gles1,gles2,opengl}. Replace these three extensions with EGL_KHR_surfaceless_context since that extension actually exists. Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Kristian Høgsberg <[email protected]> Reviewed-by: Matt Turner <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: add EGL_NV_post_sub_bufferFredrik Höglund2011-12-201-0/+2
| | | | | | | | | v2: Handle EGL_POST_SUB_BUFFER_SUPPORTED_NV in _eglParseSurfaceAttribList() Signed-off-by: Fredrik Höglund <[email protected]> [olv: remove #ifdef checks]
* egl: remove EGL_ANDROID_swap_rectangleChia-I Wu2011-12-201-1/+0
| | | | | We never support this unofficial extension, and it has been removed from Android recently. There is no point in keeping it.
* egl: add null platformChia-I Wu2011-09-201-0/+1
| | | | | | | The null platform has no window or pixmap surface (but pbuffer surface). And the only valid display is EGL_DEFAULT_DISPLAY. It is useful for offscreen rendering. It works everywhere becase no window system is required.
* egl: add Android-specific extensionsChia-I Wu2011-08-211-0/+3
| | | | | | | | Add EGL_ANDROID_image_native_buffer and EGL_ANDROID_swap_rectangle. There is no spec for them though. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: add _EGL_PLATFORM_ANDROIDChia-I Wu2011-08-211-0/+1
| | | | | | | This is Android Gingerbread platform. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: Native Display autodetectionBenjamin Franzke2011-08-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | EGL doesnt define howto manage different native platforms. So mesa has a builtime configurable default platform, whith non-standard envvar (EGL_PLATFORM) overwrites. This caused unneeded bugreports, when EGL_PLATFORM was forgotten. Detection is grouped into basic types of NativeDisplays (which itself needs to be detected). The final decision is based on characteristcs of these basic types: File Desciptor based platforms (fbdev): - fstat(2) to check for being a fd that belongs to a character device - check kernel subsystem (todo) Pointer to structuctures (x11, wayland, drm/gbm): - mincore(2) to check whether its valid pointer to some memory. - magic elements (e.g. pointers to exported symbols): o wayland display stores interface type pointer (first elm.) o gbm stores pointer to its constructor (first elm.) o x11 as a fallback (FIXME?) Reviewed-by: Kristian Høgsberg <[email protected]>
* egl: add copyright noticesChia-I Wu2011-07-021-0/+30
| | | | | The list of copyright holders could be incomplete. Please update directly or notify me if your name is missing.
* egl: Add EGL_WL_bind_wayland_displayBenjamin Franzke2011-03-011-0/+2
|
* egl: Add wayland platformBenjamin Franzke2011-02-071-0/+1
|
* egl: Improve driver selection.Chia-I Wu2011-01-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | | The idea is to be able to match a driver using the following order try egl_gallium with hw renderer try egl_dri2 try egl_gallium with sw renderer try egl_glx given the module list egl_gallium egl_dri2 egl_glx For that, UseFallback initialization option is added. The module list is matched twice: with the option unset and with the option set. In the first pass, egl_gallium skips its sw renderer and egl_glx rejects to initialize since UseFallback is not set. In the second pass, egl_gallium skips its hw renderer and egl_dri2 rejects to initialize since UseFallback is set. The process stops at the first driver that initializes the display.
* egl: Simplify driver matching.Chia-I Wu2011-01-131-0/+5
| | | | | | Add initialization options that drv->API.Initialize should support. Replace drv->Probe by TestOnly initialization option and simplify _eglMatchDriver.
* egl: Cleanup _EGLDisplay initialization.Chia-I Wu2011-01-131-14/+14
| | | | | Reorder/rename and document the fields that should be set by the driver during initialization. Drop the major/minor arguments from drv->API.Initialize.
* egl: Add reference count for resources.Chia-I Wu2010-10-231-0/+13
| | | | | This is a really simple mechanism. There is no atomicity and the caller is expected to hold the display lock.
* egl: Drop dpy argument from the link functions.Chia-I Wu2010-10-231-1/+1
| | | | | All display resources are already initialized with a display. Linking simply links a resource to its display.
* egl: Add EGL_MESA_drm_image extensionKristian Høgsberg2010-08-251-0/+1
| | | | Create EGLImages from DRM buffer handles.
* egl: Add support for EGL_KHR_fence_sync.Chia-I Wu2010-08-171-0/+1
| | | | Individual drivers still need to support and enable the extension.
* egl: Add support for EGL_KHR_reusable_sync.Chia-I Wu2010-08-171-0/+6
| | | | Individual drivers still need to support and enable the extension.