GLX

From Wikipedia, the free encyclopedia
Jump to: navigation, search
GLX
Original author(s) SGI
Stable release 1.4
Written in C
License SGI FreeB License[1]
Website dri.freedesktop.org/wiki/GLX
GLX and AIGLX versus direct rendering.
GLX over Utah GLX.

GLX (initialism for "OpenGL Extension to the X Window System") provides the interface connecting OpenGL and the X Window System: it enables programs wishing to use OpenGL to do so within a window provided by the X Window System.

The Linux DRI Graphic Stack in 2013

History[edit]

Silicon Graphics developed GLX as part of their effort to support OpenGL in the X Window System. In 1999 SGI released GLX under an open source license,[2] letting it being incorporated in XFree86's source code version 4.0 in 2000. From there, the code was inherited by the forked X.Org Foundation's version of the X Window System X11R6.7.0. On September 19, 2008, SGI created a new SGI FreeB License Version 2.0, which "now mirrors the free X11 license used by X.Org" and "meets the free and open source software community's widely accepted definition of 'free'".[3] As of 2011 GLX has reached version 1.4.

The first internal implementation of GLX API, called GLcore,[4] loaded a version of the software render of Mesa inside the X server and rendered the OpenGL commands in a window or pixmap. With the development of DRI, it was added the ability to use hardware accelerated OpenGL through direct contexts (primarily used by videogames). In 2006, the popularization of the nested Xgl X server and Compiz compositing window manager lead to the development of Accelerated Indirect GLX or AIGLX. AIGLX brings hardware acceleration to the GLX (indirect context) applications by loading the Mesa DRI driver inside the X server. This method enables the sharing of GL objects between X clients using indirect contexts (they all are in the same address space in the X server) and also between a X client and the compositing window manager, thus accelerating composition. In 2008 the binding in GLcore to the Mesa software render was rewritten as a DRI interface module, called swrast_dri.so, improving the coupling of Mesa and the X server. Also in the year 2008 the new DRI2 was introduced to replace DRI, and with it a new model based in the Kernel mode-setting. In 2011 started the GLAMOR project aiming to add a generic hardware accelerated 2D X driver based in OpenGL. In 2013 Adam Jackson did a major rewrite of GLX code to consolidate the diverse paths from GLAMOR, indirect rendering, ... to one unique path to OpenGL's library libGL.[5]

Features[edit]

GLX demo (glxgears) included with X11

GLX consists of three parts:

  1. An API that provides OpenGL functions to an X Window System application.
  2. An extension of the X protocol, which allows the client (the OpenGL application) to send 3D rendering commands to the X server (the software responsible for the display). The client and server software may run on different computers.
  3. An extension of the X server that receives the rendering commands from the client and passes them on to the installed OpenGL library

If client and server are running on the same computer and an accelerated 3D graphics card using a suitable driver is available, the former two components can be bypassed by DRI. In this case, the client application is then allowed to directly access the video hardware through several API layers.

Implementations[edit]

See also[edit]

  • WGL – the equivalent Microsoft Windows interface to OpenGL
  • CGL – the equivalent Mac OS X interface to OpenGL
  • EGL – a similar cross-platform interface between OpenGL ES or VG and the underlying native platform window system
  • GLUT – library of utilities for OpenGL programs

References[edit]

  1. ^ http://oss.sgi.com/projects/FreeB/
  2. ^ "SGI Open Source Project List: OpenGL® Sample Implementation". Silicon Graphics International. Retrieved 5 February 2014. 
  3. ^ SGI Further Opens Its OpenGL Contributions
  4. ^ "DRI - GLcore". FreeDesktop. Retrieved 5 February 2014. 
  5. ^ Jackson, Adam. "Rewriting GLX To Rewrite X". Linux.conf Australia. Retrieved 7 February 2014. 

External links[edit]