Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
4349 | Serge | 1 | Cairo - Multi-platform 2D graphics library |
2 | http://cairographics.org |
||
3 | |||
4 | What is cairo |
||
5 | ============= |
||
6 | Cairo is a 2D graphics library with support for multiple output |
||
7 | devices. Currently supported output targets include the X Window |
||
8 | System, quartz, win32, and image buffers, as well as PDF, PostScript, |
||
9 | and SVG file output. Experimental backends include OpenGL, XCB, BeOS, |
||
10 | OS/2, and DirectFB. |
||
11 | |||
12 | Cairo is designed to produce consistent output on all output media |
||
13 | while taking advantage of display hardware acceleration when available |
||
14 | (for example, through the X Render Extension). |
||
15 | |||
16 | The cairo API provides operations similar to the drawing operators of |
||
17 | PostScript and PDF. Operations in cairo include stroking and filling |
||
18 | cubic Bézier splines, transforming and compositing translucent images, |
||
19 | and antialiased text rendering. All drawing operations can be |
||
20 | transformed by any affine transformation (scale, rotation, shear, |
||
21 | etc.). |
||
22 | |||
23 | Cairo has been designed to let you draw anything you want in a modern |
||
24 | 2D graphical user interface. At the same time, the cairo API has been |
||
25 | designed to be as fun and easy to learn as possible. If you're not |
||
26 | having fun while programming with cairo, then we have failed |
||
27 | somewhere---let us know and we'll try to fix it next time around. |
||
28 | |||
29 | Cairo is free software and is available to be redistributed and/or |
||
30 | modified under the terms of either the GNU Lesser General Public |
||
31 | License (LGPL) version 2.1 or the Mozilla Public License (MPL) version |
||
32 | 1.1. |
||
33 | |||
34 | Where to get more information about cairo |
||
35 | ========================================= |
||
36 | The primary source of information about cairo is: |
||
37 | |||
38 | http://cairographics.org/ |
||
39 | |||
40 | The latest versions of cairo can always be found at: |
||
41 | |||
42 | http://cairographics.org/download |
||
43 | |||
44 | Documentation on using cairo and frequently-asked questions: |
||
45 | |||
46 | http://cairographics.org/documentation |
||
47 | http://cairographics.org/FAQ |
||
48 | |||
49 | Mailing lists for contacting cairo users and developers: |
||
50 | |||
51 | http://cairographics.org/lists |
||
52 | |||
53 | Roadmap and unscheduled things to do, (please feel free to help out): |
||
54 | |||
55 | http://cairographics.org/roadmap |
||
56 | http://cairographics.org/todo |
||
57 | |||
58 | Dependencies |
||
59 | ============ |
||
60 | The set of libraries needed to compile cairo depends on which backends |
||
61 | are enabled when cairo is configured. So look at the list below to |
||
62 | determine which dependencies are needed for the backends of interest. |
||
63 | |||
64 | For the surface backends, we have both "supported" and "experimental" |
||
65 | backends. Further, the supported backends can be divided into the |
||
66 | "standard" backends which can be easily built on any platform, and the |
||
67 | "platform" backends which depend on some underlying platform-specific |
||
68 | system, (such as the X Window System or some other window system). |
||
69 | |||
70 | As an example, for a standard Linux build, (with image, png, pdf, |
||
71 | PostScript, svg, and xlib surface backends, and the freetype font |
||
72 | backend), the following sample commands will install necessary |
||
73 | dependencies: |
||
74 | |||
75 | Debian (and similar): |
||
76 | |||
77 | apt-get install libpng12-dev libz-dev libxrender-dev libfontconfig1-dev |
||
78 | |||
79 | Fedora (and similar): |
||
80 | |||
81 | yum install libpng-devel zlib-devel libXrender-devel fontconfig-devel |
||
82 | |||
83 | (Those commands intentionally don't install pixman from a distribution |
||
84 | package since if you're manually compiling cairo, then you likely want |
||
85 | to grab pixman from the same place at the same time and compile it as |
||
86 | well.) |
||
87 | |||
88 | Supported, "standard" surface backends |
||
89 | ------------------------------------ |
||
90 | image backend (required) |
||
91 | ------------------------ |
||
92 | pixman >= 0.18.4 http://cairographics.org/releases |
||
93 | |||
94 | png support (can be left out if desired, but many |
||
95 | ----------- applications expect it to be present) |
||
96 | libpng http://www.libpng.org/pub/png/libpng.html |
||
97 | |||
98 | pdf backend |
||
99 | ----------- |
||
100 | zlib http://www.gzip.org/zlib |
||
101 | |||
102 | postscript backend |
||
103 | ------------------ |
||
104 | zlib http://www.gzip.org/zlib |
||
105 | |||
106 | svg backend |
||
107 | ----------- |
||
108 | [none] |
||
109 | |||
110 | Supported, "platform" surface backends |
||
111 | ----------------------------------- |
||
112 | xlib backend |
||
113 | ------------ |
||
114 | X11 http://freedesktop.org/Software/xlibs |
||
115 | |||
116 | xlib-xrender backend |
||
117 | -------------------- |
||
118 | Xrender >= 0.6 http://freedesktop.org/Software/xlibs |
||
119 | |||
120 | quartz backend |
||
121 | -------------- |
||
122 | MacOS X >= 10.4 with Xcode >= 2.4 |
||
123 | |||
124 | win32 backend |
||
125 | ------------- |
||
126 | Microsoft Windows 2000 or newer[*]. |
||
127 | |||
128 | Font backends (required to have at least one) |
||
129 | --------------------------------------------- |
||
130 | freetype font backend |
||
131 | --------------------- |
||
132 | freetype >= 2.1.9 http://freetype.org |
||
133 | fontconfig http://fontconfig.org |
||
134 | |||
135 | quartz-font backend |
||
136 | ------------------- |
||
137 | MacOS X >= 10.4 with Xcode >= 2.4 |
||
138 | |||
139 | win32 font backend |
||
140 | ------------------ |
||
141 | Microsoft Windows 2000 or newer[*]. |
||
142 | |||
143 | [*] The Win32 backend should work on Windows 2000 and newer |
||
144 | (excluding Windows Me.) Most testing has been done on |
||
145 | Windows XP. While some portions of the code have been |
||
146 | adapted to work on older versions of Windows, considerable |
||
147 | work still needs to be done to get cairo running in those |
||
148 | environments. |
||
149 | |||
150 | Cairo can be compiled on Windows with either the gcc |
||
151 | toolchain (see http://www.mingw.org) or with Microsoft |
||
152 | Visual C++. If the gcc toolchain is used, the standard |
||
153 | build instructions using configure apply, (see INSTALL). |
||
154 | If Visual C++ is desired, GNU make is required and |
||
155 | Makefile.win32 can be used via 'make -f Makefile.win32'. |
||
156 | The compiler, include paths, and library paths must be set |
||
157 | up correctly in the environment. |
||
158 | |||
159 | MSVC versions earlier than 7.1 are known to miscompile |
||
160 | parts of cairo and pixman, and so should be avoided. MSVC |
||
161 | 7.1 or later, including the free Microsoft Visual Studio |
||
162 | Express editions, produce correct code. |
||
163 | |||
164 | Experimental surface backends |
||
165 | ----------------------------- |
||
166 | xcb backend |
||
167 | ----------- |
||
168 | XCB http://xcb.freedesktop.org |
||
169 | |||
170 | beos backend |
||
171 | ------------ |
||
172 | No dependencies in itself other than an installed BeOS system, but cairo |
||
173 | requires a font backend. See the freetype dependency list. |
||
174 | |||
175 | os2 backend |
||
176 | ----------- |
||
177 | Cairo should run on any recent version of OS/2 or eComStation, but it |
||
178 | requires a font backend. See the freetype dependency list. Ready to use |
||
179 | packages and developer dependencies are available at Netlabs: |
||
180 | ftp://ftp.netlabs.org/pub/cairo |
||
181 | |||
182 | Compiling |
||
183 | ========= |
||
184 | See the INSTALL document for build instructions. |
||
185 | |||
186 | History |
||
187 | ======= |
||
188 | Cairo was originally developed by Carl Worth |
||
189 | Keith Packard |
||
190 | without whose patient help our ignorance would be much more apparent. |
||
191 | |||
192 | Since the original development, many more people have contributed to |
||
193 | cairo. See the AUTHORS files for as complete a list as we've been able |
||
194 | to compile so far. |