From 85ef9930f56bf15181f9a0b238f03d55303cf411 Mon Sep 17 00:00:00 2001
From: marha
- $ ./configure --with-state-trackers=egl,es,vega --enable-gallium-{swrast,intel} + $ ./configure --enable-gles-overlay --with-state-trackers=egl,vega --enable-gallium-intel-
The main library will be enabled by default. The egl
state
+
The main library and OpenGL is enabled by default. The first option enables
+OpenGL ES 1.x and 2.x. The egl
state
tracker is needed by a number of EGL drivers. EGL drivers will be covered
-later. The es state tracker provides OpenGL ES 1.x
-and 2.x and the vega state tracker provides OpenVG
+later. The vega state tracker provides OpenVG
1.x.
In the given example, it will build and install libEGL
,
-libGLESv1_CM
, libGLESv2
, libOpenVG
, and
-one or more EGL drivers.
libGL
, libGLESv1_CM
, libGLESv2
,
+libOpenVG
, and one or more EGL drivers.
${libdir}/egl
.
---with-egl-displays
+--with-egl-platforms
-List the window system(s) to support. It is by default x11
,
-which supports the X Window System. Its argument is a comma separated string
-like, for example, --with-egl-displays=x11,kms
. Because an EGL
-driver decides which window system to support, this example will enable two
-(sets of) EGL drivers. One supports the X window system and the other supports
-bare KMS (kernel modesetting).
List the platforms (window systems) to support. Its argument is a comma
+seprated string such as --with-egl-platforms=x11,drm
. It decides
+the platforms a driver may support. The first listed platform is also used by
+the main library to decide the native platform: the platform the EGL native
+types such as EGLNativeDisplayType
or
+EGLNativeWindowType
defined for.
The available platforms are x11
, drm
,
+fbdev
, and gdi
. The gdi
platform can
+only be built with SCons.
--with-state-trackers
The argument is a comma separated string. It is usually used to specify the
-rendering APIs, like OpenGL ES or OpenVG, to build. But it should be noted
-that a number of EGL drivers depend on the egl
state tracker.
-They will not be built without the egl
state tracker.
egl
state tracker that egl_gallium
depends on.
--enable-gallium-swrast
+--enable-gles-overlay
-This option is not specific to EGL. But if there is no driver for your -hardware, or you are experiencing problems with the hardware driver, you can -enable the swrast DRM driver. It is a dummy driver and EGL will fallback to -software rendering automatically.
+OpenGL and OpenGL ES are not controlled by
+--with-state-trackers
. OpenGL is always built. To build OpenGL
+ES, this option must be explicitly given.
--enable-gles1
and --enable-gles2
+
+Unlike --enable-gles-overlay
, which builds one library for each
+rendering API, these options enable OpenGL ES support in OpenGL. The result is
+one big library that supports multiple APIs.
The OpenGL state tracker is not built in the above example. It should be
-noted that the classic libGL
is not a state tracker and cannot be
-used with EGL (unless the EGL driver in use is egl_glx
). To build
-the OpenGL state tracker, one may append glx
to
---with-state-trackers
and manually build
-src/gallium/winsys/xlib/
.
The demos for OpenGL ES and OpenVG can be found in progs/es1/
,
-progs/es2/
and progs/openvg/
. You can use them to
-test your build. For example,
- $ cd progs/es1/xegl - $ make - $ ./torus -+
There are demos for the client APIs supported by EGL. They can be found in +mesa/demos repository.
egl_gallium
dynamically loads hardware drivers and client API
+modules found in EGL_DRIVERS_PATH
. Thus, specifying this variable
+alone is not sufficient for egl_gallium
for uninstalled build.
EGL_DISPLAY
+EGL_PLATFORM
-When EGL_DRIVER
is not set, the main library loads all
-EGL drivers that support a certain window system. EGL_DISPLAY
can
-be used to specify the window system and the valid values are, for example,
-x11
or kms
. When the variable is not set, the main
-library defaults the value to the first window system listed in
---with-egl-displays
at configuration time.
+
This variable specifies the native platform. The valid values are the same
+as those for --with-egl-platforms
. When the variable is not set,
+the main library uses the first platform listed in
+--with-egl-platforms
as the native platform
There are two categories of EGL drivers: Gallium and classic.
- -Gallium EGL drivers supports all rendering APIs specified in EGL 1.4. The
-support for optional EGL functions and EGL extensions is usually more complete
-than the classic ones. These drivers depend on the egl
state
-tracker to build. The available drivers are
egl_<dpy>_i915
egl_<dpy>_i965
egl_<dpy>_radeon
egl_<dpy>_nouveau
egl_<dpy>_swrast
egl_<dpy>_vmwgfx
egl_gallium
-<dpy>
is given by --with-egl-displays
at
-configuration time. There will be one EGL driver for each combination of the
-displays listed and the hardware drivers enabled.
This driver is based on Gallium3D. It supports all rendering APIs and +hardwares supported by Gallium3D. It is the only driver that supports OpenVG. +The supported platforms are X11, KMS, FBDEV, and GDI.
-Classic EGL drivers, on the other hand, supports only OpenGL as its
-rendering API. They can be found under src/egl/drivers/
. There
-are 3 of them
egl_glx
This driver provides a wrapper to GLX. It uses exclusively GLX to implement
@@ -224,9 +207,6 @@ are phasing out, it might eventually be replaced by egl_dri2
.
To use the classic drivers, one must manually set EGL_DRIVER
at
-runtime.
The sources of the main library and the classic drivers can be found at @@ -315,8 +295,12 @@ should as well lock the display before using it.
EGL_DISPLAY
loads all
-drivers and might eat too much memory.libGL.so
, libGLESv1_CM.so
, and
+libGLESv2.so
should an application link to? Bad things may happen
+when, say, an application is linked to libGLESv2.so
and
+libcairo
, which is linked to libGL.so
instead.