Commit graph

247 commits

Author SHA1 Message Date
Chris Wilson
6d4f3c40ef Add a private copy of GLEW
This appears to be the simplest mechanism to build libglew at the moment -
should a system copy be unavailable.  Fortunately libglew is now distributed
under a permissive licence.

If you want to pass 'make -C src check' you have to use the system copy,
or spend quite a bit of time cairo-fying libglew.
2009-09-14 09:26:02 +01:00
Chris Wilson
55bd590561 [tessellator] Use a priority queue for the events
The skip list was suffering from severe overhead, so though the search was
quick, the extra copies during insertion and deletion were slow.
2009-08-29 08:08:29 +01:00
Chris Wilson
f8bb3617c3 Eliminate self-intersecting strokes.
We refactor the surface fallbacks to convert full strokes and fills to the
intermediate polygon representation (as opposed to before where we
returned the trapezoidal representation). This allow greater flexibility
to choose how then to rasterize the polygon. Where possible we use the
local spans rasteriser for its increased performance, but still have the
option to use the tessellator instead (for example, with the current
Render protocol which does not yet have a polygon image).

In order to accommodate this, the spans interface is tweaked to accept
whole polygons instead of a path and the tessellator is tweaked for speed.

Performance Impact
==================

...
Still measuring, expecting some severe regressions.
...
2009-08-29 08:08:28 +01:00
Vladimir Vukicevic
22587f57bd Import Qt backend by Mozilla
Written by Vladimir Vukicevic to enable integration with Qt embedded
devices, this backend allows cairo code to target QPainter, and use
it as a source for other cairo backends.

This imports the sources from mozilla-central:
http://mxr.mozilla.org/mozilla-central/find?text=&kind=text&string=cairo-qpainter
renames them from cairo-qpainter to cairo-qt, and integrates the patch
by Oleg Romashin:
https://bugs.freedesktop.org/attachment.cgi?id=18953

And then attempts to restore 'make check' to full functionality.

However:
 - C++ does not play well with the PLT symbol hiding, and leaks into the
   global namespace. 'make check' fails at check-plt.sh

 - Qt embeds a GUI into QApplication which it requires to construct any
   QPainter drawable, i.e. used by the boilerplate to create a cairo-qt
   surface, and this leaks fonts (cairo-ft-fonts no less) causing assertion
   failures that all cairo objects are accounted for upon destruction.

[Updated by Chris Wilson]
Acked-by: Jeff Muizelaar <jeff@infidigm.net>
Acked-by: Carl Worth <cworth@cworth.org>
2009-06-16 11:03:46 +01:00
Behdad Esfahbod
c22ca79863 Don't distribute cairo-features.h (#19992)
Second time I fix this bug.  Mabe we should add a test for it!
2009-02-06 12:56:48 -05:00
Behdad Esfahbod
06deaa98b6 [build] Include all generated win32 build files in the repo
So a git clone can be built on win32.  The files only change after adding
new backends.
2009-01-09 15:55:24 -05:00
Chris Wilson
43edb4dd7b Fix compilation with gcov
We need to add --coverage to LDFLAGS, so create CAIRO_LDFLAGS and use that
to populate AM_LDFLAGS.
2008-12-14 16:44:03 +00:00
Chris Wilson
032be9849d [skiplist] Inline testing.
Add a loop to create a skip list to allow manual checking.
2008-11-16 16:21:23 +00:00
Behdad Esfahbod
fba0211ed6 [Makefile.win32] Add makefile rules to generate cairo-features.h 2008-09-22 23:41:07 -04:00
Behdad Esfahbod
ebb5eb57b7 Generate build/Makefile.win32.features 2008-09-22 22:24:38 -04:00
Behdad Esfahbod
23b9767bb3 Rename Makefile.*.config to Makefile.*.features as they should not be modified
The .config naming was giving people the impression that they can modify it.
That's not the case.
2008-09-22 17:34:36 -04:00
Behdad Esfahbod
fee72c26af Make sure feature macros are checked using #if, not #ifdef; add a test for it
This is more robust to cases where people want to assign 0 to those variables.
(win32/alternate build systems, etc)
2008-09-20 17:20:36 -04:00
Behdad Esfahbod
9c36a5f3f1 [src/Makefile.am.analysis] Check that all headers can be compiled standalone
This ensures that each header includes all headers it depends on.
This is now enforced by "make check".
2008-09-19 18:51:03 -04:00
Behdad Esfahbod
d84752605a Make sure (and check) that all private headers include some cairo header first
The macros CAIRO_BEGIN_DECLS and CAIRO_END_DECLS are declared in two
places: config.h and cairo.h.  On Win32 build there is no config.h.  So,
we can't rely on pulling CAIRO_BEGIN_DECLS from there.  Hence, we now:

  * Not add those declarations to config.h anymore,

  * Test that every cairo private header includes some other cairo
    header before any other includes.

These two are fairly enough to ensure that cairo.h is seen from all
private headers.  There's still the case of headers not including
any header file at all.  I'll fix that later.
2008-09-19 17:19:10 -04:00
Behdad Esfahbod
73c70488f3 [src/check-*.sh] Use computed list of source files instead of running "find"
When the lists are available use them.  They will be available to test
programs by make.
2008-09-18 15:56:53 -04:00
Behdad Esfahbod
1de35c04e0 Revert "[Makefile.am] Add CAIRO_LIBS to check-link."
This reverts commit a341cb5a98.
The change introduced in that commit should not be needed and libtool
should just do the right thing.  I cannot reproduce the problem
Chris was having no matter how hard I tried.
2008-09-17 02:11:38 -04:00
Chris Wilson
a341cb5a98 [Makefile.am] Add CAIRO_LIBS to check-link.
With --enable-gcov, make check aborts with gcov errors on check-link - it
appears that -lgcov is magic and requires explicit invovation on the
command-line.
2008-09-16 23:06:53 +01:00
Behdad Esfahbod
49c8c62040 [src/Makefile.am.analysis] Split off from src/Makefile.am 2008-09-16 03:58:21 -04:00
Behdad Esfahbod
a908fc04a7 [boilerplate/Makefile.am] Distribute Makefile.win32.config 2008-09-16 03:58:21 -04:00
Chris Wilson
87094e8c78 [Makefile] Amend checks for horrible msys environment.
automake-1.8 requires $(EXEEXT) for TESTS and feeds lt-check-*.c to
check-cairoint.h. Workaround both misfeatures.
2008-09-16 01:50:29 +01:00
Behdad Esfahbod
50f45d7768 [src/Makefile.am] Add comment referring to Makefile.sources 2008-09-15 14:50:07 -04:00
Behdad Esfahbod
93325a3f08 [configure.ac.enable] Cleanup Makefile.*.config generation 2008-09-11 19:12:31 -04:00
Behdad Esfahbod
66d6cb642c [Makefile.am.common] Unify more common rules 2008-09-11 18:06:57 -04:00
Behdad Esfahbod
de5b8bce37 Makefile.am cleanup
Use a common build/Makefile.am.common file.
2008-09-11 15:49:09 -04:00
Behdad Esfahbod
87dfceb9ec [Makefile.am] Rename INCLUDES to AM_CPPFLAGS
Fixes automake warnings
2008-09-08 15:13:07 -04:00
Behdad Esfahbod
7ad076442d Rename src/*.mk to src/Makefile.*
Namely:

	src/Sources.mk      -> src/Makefile.sources
	src/Config.mk       -> src/Makefile.am.config
	src/Config.mk.win32 -> src/Makefile.win32.config
2008-09-04 22:23:42 -04:00
Behdad Esfahbod
37f82a4d1b Get rid of CAIRO_LDADD in favor of CAIRO_LIBS 2008-09-04 16:13:05 -04:00
Behdad Esfahbod
097c4ac022 [Makefile.am] Use check_PROGRAMS 2008-09-03 20:52:17 -04:00
Behdad Esfahbod
b1ced45f06 [doc] Fix out-of-tree build 2008-09-03 20:52:12 -04:00
Behdad Esfahbod
99e2e2d0bb [src/Makefile.am] Minor fix in MAINTAINERCLEANFILES 2008-09-03 12:06:35 -04:00
Chris Wilson
3b7726e3d4 [src/Makefile.am] s/libcairo_la_CFLAGS/INCLUDES/
Update the custom rules after the overall to the build system.
2008-09-03 14:07:37 +01:00
Chris Wilson
c18cc5b441 [src/Makefile.am] make check compile fix
Minor typo preventing TESTS from building.
2008-09-03 10:20:45 +01:00
Behdad Esfahbod
cf212ddaca Also test linking when cross-compiling
We build the test.  Just don't run it.
2008-09-02 22:05:06 -04:00
Behdad Esfahbod
2823ebaa6e [src/check-link.c] Simple test to check we can link to the built cairo.so 2008-09-02 21:31:43 -04:00
Behdad Esfahbod
5926257770 Revamp the build system.
Quick summary of changes:

  - Move list of cairo source files out of src/Makefile.am and into
    src/Sources.mk,

  - Generate files src/Config.mk and src/Config.mk.win32 that choose
    the right set of source files and headers based on configured
    backends and features.  This drastically simplifies building
    using other build systems.  The src/Makefile.win32 file needs
    to be updated to reflect these changes.

  - Add README files to various directories,

  - Add toplevel HACKING file.
2008-09-02 20:24:08 -04:00
Behdad Esfahbod
894940b81f Some nasty tracks to make changing version number not cause a total rebuild
Quite slick!  This comes handy when git-bisect'ing.  The canonical version
number is in toplevel cairo-version.h now.
2008-08-28 18:18:23 -04:00
Behdad Esfahbod
89900525fb Move version number to src/cairo-version.h 2008-08-28 17:28:08 -04:00
Behdad Esfahbod
df64e0e632 Cleanup libtool version handling
In preparation to remove the manual numbering completely
2008-08-27 18:41:22 -04:00
Behdad Esfahbod
719c17c293 [src/Makefile.am] Remove gcc dependency 2008-08-27 17:09:19 -04:00
Chris Wilson
12d3d32f22 [Makefile.am] Support uno.
For the extreme masochist only. At the moment, it only generate syntax
errors, but the command line appears functional.
2008-08-17 21:41:36 +01:00
Chris Wilson
db7e3cb854 [Makefile.am] Delete intermediates
Clean up after calling 'gcc -save-temps'.
2008-08-17 11:39:56 +01:00
Behdad Esfahbod
2c53acea0b [src/Makefile.am] Include missing header file 2008-08-11 13:54:26 -04:00
Vladimir Vukicevic
acdc306905 [win32] Adding cairo-features-win32.h to EXTRA_DIST 2008-08-05 13:16:17 -07:00
Adrian Johnson
100a34bea6 Implement PDF Type 3 font subsetting of user fonts
show_glyphs inside a Type 3 font currently results in a fallback
image. Some refactoring is required before font subsets can be created
while emitting all the font subsets.
2008-06-08 17:11:39 +09:30
Behdad Esfahbod
626edfc333 [cairo-mutex] Prepare mutex infrastructure for adding mutex debugging facilities
Essentially renaming cairo-mutex-type-private.h to cairo-mutex-impl-private.h
and changing all its namespace from cairo_mutex to cairo_mutex_impl.
cairo-mutex-type-private.h then does all the sanity checks on the
implementation that used to be in cairo-mutex-private.h.  Plus, defines macros
for the cairo-mutex namespace to map to the cairo-mutex-impl namespace.  This
extra mapping layer allows for add debugging facilities.
2008-05-27 05:11:00 -04:00
Behdad Esfahbod
17f21ea307 [cairo-user-font] Implement user fonts 2008-05-10 01:21:45 +02:00
Behdad Esfahbod
e39127627a [Makefile.am] Rename cairo_all_source_file to cairo_all_source_files 2008-05-09 14:54:31 +02:00
Behdad Esfahbod
d6654ce2a6 [Makefile.am] Sort source files 2008-05-09 14:54:30 +02:00
Chris Wilson
a0d71e5a38 [Makefile.am] Fix breakage in previous commit.
I checked with --disable-pdf and with --disable-ps, but forgot to
check with them both enabled. D'oh.
2008-04-16 14:33:00 +01:00
Chris Wilson
472637da05 [Makefile.am] Add cairo-pdf-operators*.[ch] to ps_sources
The postscript backends depends upon cairo-pdf-operators.c, so list it
as a requirement in ps_sources. This enables the postscript backend to
build even if the pdf backend is disable by the user during configure.

(Fixes http://bugs.freedesktop.org/show_bug.cgi?id=15532.)
2008-04-16 14:19:02 +01:00