24 Jul 2000: There is now a libart mailing list, for questions and discussions related to using and integrating Libart effectively. Please see http://mail.gnome.org/mailman/listinfo/libart for archives and sign-up info.
Libart is a library of functions for 2D graphics supporting a superset of the PostScript imaging model, designed to be integrated with graphics, artwork, and illustration programs. It is written in optimized C, and is fully compatible with C++. With a small footprint of 10,000 lines of code, it is especially suitable for embedded applications. Libart is currently being used in several free software applications, including Gill (the Gnome SVG editor), the Gnome Canvas, and several others under development.
Antialiasing
The libart imaging model has two primary enhancements over PostScript: antialiasing and alpha-transparency. In antialiasing, Libart smooths out the edges of graphics, eliminating the sawtooth edges known as "jaggies." For example, the edges of graphics primitives such as Bezier paths and text are rendered more smoothly. The result is improved readability, better accuracy, and better overall quality. (Insert visual here showing before and after antialiasing of a letter)
Alpha Transparency
The other imaging model enhancement, alpha transparency, renders graphics objects with partial transparency. This is particularly effective for graphical displays containing more than one layer. The result is more precise compositing, fewer redos, faster rendering, and better quality. (Insert visual illustrating alpha transparency)
Additional Libart Imaging Operations
While antialiasing and alpha transparency are two primary enhancements available with Libart, it also supports a wide range of basic imaging operations. These include Bezier paths, vector paths, sorted vector paths, vector path operations, outline stroking, raster images, and microtile arrays. Each of these additional features is described below:
Bezier Paths
A Bezier path is an outline composed of straight lines and curved (Bezier) segments. This format is the most efficient and flexible way to represent shapes. Bezier paths are compatible with industry standard graphics tools and font formats, including Type 1 and TrueType. (Insert visual showing bezier paths)
Vector Paths
A vector path is an outline composed of straight lines. Libart generally renders Bezier paths by reducing them to vector paths, with an adjustable "smoothness" or antialiasing parameter. (Insert visual showing vector paths)
Sorted Vector Paths
Sorted vector paths speed up rendering and other geometric operations. Libart sorts a vector path into segments, which are either "up"or "down" in direction. These sorted vector paths can then be rendered or clipped much faster than the original vector path. This optimization is particularly helpful for incremental rendering of layered data.
Vector Path Operations
Libart supports a full range of geometric operations on vector paths, including union, intersection (clipping), difference, symmetric difference, and stroke outline with all the PostScript join and capstyle options. (Insert visual showing operations and style options)
Microtile Arrays
Libart's unique microtile arrays are a lightweight and efficient approximate representation of specific regions. These microtile arrays are particularly useful for minimizing the re-display area on incremental display, speeding up response time and making motion smoother. (Insert visual)
Raster Images
Libart has full support for RGB and RGBA image operations, including rotation, scaling, skewing, and alpha compositing.
Applications for Libart
Applications for Libart are numerous and cross many disciplines. A brief sampling follows:
Libart is developed to be a comprehensive library for manipulating and rendering 2D graphics. Ongoing technical support and custom integration services are available. Development of new features continues actively.
- Interactive graphics applications, using libart's sorted vector paths and microtiles to optimize incremental redisplay.
- Dynamic generation of web graphics, for example charts or personalized buttons.
- Rendering maps and other GIS (Geographic Information Systems) data, both for Web delivery and personal computer applications.
- Presentation of biomedical and industrial data on embedded displays.
- SVG viewers and editors for desktop and web graphics.
Draft documentation is available at www.levien.com/libart.
A current stable release of libart, with some API documentation included in the .c files, can be downloaded here:
For the current development snapshot, checkout the module libart_lgpl from Gnome CVS.
For more information about licensing, contact:
Miles Jones
V.P. of Sales
artofcode LLC
101 Lucas Valley Road #110
San Rafael, CA 94903
tel +1 415 492 9861
fax +1 415 492 9862
miles@artofcode.com