The Linux kernel provides an abstraction for the graphical hardware in the form of framebuffer devices. These allow applications to access graphics hardware through a well-defined API. The framebuffer is also used to provide a graphical console to the Linux kernel, so that it can, for example, display colors and a logo. In this recipe, we will explore how applications can use the Linux framebuffer to display graphics and video.
Some applications, especially in embedded devices, are able to access the framebuffer by mapping memory and accessing it directly. For example, the
gstreamer framework is able to work directly over the framebuffer, as is the Qt graphical framework. Some applications, like the Qt framework, also include support for hardware acceleration-not only video but also 2D and 3D graphical acceleration provided through the OpenGL and OpenVG APIs.