Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What roles do the Xorg server and a window manager - for example, metacity - play in displaying windows? Does the window manager communicate with the OS or Xorg? Does Xorg then use OpenGl to display things?

Can someone explain exactly what the Xorg server does, what the window manager does, and any differences between the two? If you could also show me the Windows equivalent, that would be helpful.

share|improve this question
up vote 2 down vote accepted

Windows does not exactly have an equivalent to the way that Xorg works.

Xorg communicates to the system's graphics hardware and via the OS, handles input events from your keyboard and mouse. All graphical applications you run on your Xorg desktop communicate to Xorg to draw to the screen and to receive input events. The window manager is just another application on your system, but it handles events such as moving and resizing windows, it draws the borders around windows including any buttons such as those that provide minimize, maximize, and close functions.

Xorg itself supports OpenGL via a mechanism called GLX. There is also a feature called Compositing which Xorg supports, allowing window managers to be written in OpenGL/GLX. In the case of a compositing window manager, the window manager will retrieve the contents of windows from Xorg and will render them via OpenGL/GLX. In this case, the Xorg server would generally only render the graphics provided by the window manager.

Finally, it should be noted that Xorg simply implements a protocol called X11. Everything described here also applies to other X11 servers, although features may vary, some X11 servers may not support GLX or Compositing.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .