summaryrefslogtreecommitdiff
path: root/util/cairo-trace
Commit message (Collapse)AuthorAgeFilesLines
* Fix -Wunused-function warningsKhaled Hosny2023-02-061-6/+6
|
* Drop cairo-glEmmanuele Bassi2023-01-271-188/+0
| | | | | | | | | The GL support in Cairo has always been a prototype, and nothing happened in the past 10+ years to make it work as it was meant to. GL support is not enabled by any downstream packagers of Cairo, so nobody should notice its absence.
* svg-font: return SVG_FONT_ERROR on errorAdrian Johnson2023-01-201-0/+1
|
* Remove autotools buildAdrian Johnson2023-01-081-40/+0
|
* Fix build with newer binutils-dev installedSimon McVittie2022-07-141-2/+2
| | | | | | | | It seems the PTR typedef (or macro?) has been removed from newer versions of libbfd. Resolves: https://gitlab.freedesktop.org/cairo/cairo/-/issues/581 Signed-off-by: Simon McVittie <smcv@debian.org>
* Replace use of ctype functions with internal version where only ASCII chars ↵Adrian Johnson2022-04-091-5/+7
| | | | | | | | | are used In !309 Taylor R Campbell found a number of instances of ctype incorrectly passed a signed char. In many cases, where only ASCII characters are used, the code should have been using the cairo version of the ctype function to avoid locale issues.
* DWrite font docsAdrian Johnson2022-03-051-0/+1
|
* Drop cairo-vg surfaceEmmanuele Bassi2022-02-251-79/+0
| | | | | OpenVG is a failed experiment from 10 years ago, and nobody has been using the cairo-vg surface in pretty much the same amount of time.
* Fix some MinGW warningsAdrian Johnson2021-09-021-1/+6
| | | | | | | | | | | | | | | | | The FT change is because my MinGW build is using a more recent version of FT. Remove the disabled _cairo_win32_scaled_font_text_to_glyphs() code to fix the defined but not used warning. _cairo_win32_scaled_font_text_to_glyphs() was diabled in d9408041aa with the comment: "Currently disable the win32-font text_to_glyphs(), until that one is updated. Or better yet, remove it and implement ucs4_to_index(). It's the toy font API afterall." _cairo_win32_scaled_font_ucs4_to_index() was added in d1c619bc7d.
* Use uintptr_t for all casts between pointer and integerAdrian Johnson2021-07-252-2/+2
| | | | | | | | | | | | On 64-bit windows, long is 32-bit. When compiling there are a large number of warnings about mismatched sizes when casting long to/from a pointer. Use the (u)intptr_t type for any integer that will have a pointer stored in it. Use a (u)intptr_t cast when integers are stored in pointers to silence warnings. Fixes #263
* Drop the conditional inclusion of config.hEmmanuele Bassi2021-05-012-4/+0
| | | | | | | | | | | | We *always* generate this file, and we depend on its existence. The idea behind HAVE_CONFIG_H was being able to include random files from different projects, back in a time where "libraries" were literally just random files instead of actual shared objects. Since we're not in the '80s any more, and our build system(s) define HAVE_CONFIG_H *and* generate the config.h header file, we don't need a conditional guard around its inclusion.
* Remove stray _GNU_SOURCE definitionsEmmanuele Bassi2021-05-012-4/+0
| | | | | | We define _GNU_SOURCE globally in both the Autotools build, through the use of the AC_USE_SYSTEM_EXTENSIONS macro; and in the Meson build, with add_project_arguments().
* meson: Define HAVE_CONFIG_H as a project flagEmmanuele Bassi2021-05-011-1/+1
| | | | | | | | Precisely what Autotools does, instead of adding it as per-target C argument. Once we remove HAVE_CONFIG_H checks in every source file, we'll be able to drop it.
* meson: make cairo-trace executableTim-Philipp Müller2021-03-092-0/+1
| | | | | | | | Install with exec flag set and make sure tool is executable in build directory as well (by making the input file in the source directory executable). Fixes #462
* cairo-trace: fix build with newer versions of bfdTim-Philipp Müller2021-02-231-4/+3
| | | | | | | | | And update configure/meson checks to check for the new function. Drop libiberty.h check since it's only needed by backtrace-symbols.c which we're about to remove. Closes #391, #460
* cairo-trace: Fix escape character encoding in string literalsGeorge Matsumura2020-11-201-0/+1
| | | | | | | This fixes a typo wherein both a return character and a tab character were encoded when only a return character was specified for encoding. Signed-off-by: George Matsumura <gmmatsumura01@bvsd.org>
* build: Fix various compiler warningsGeorge Matsumura2020-11-071-3/+7
| | | | | | This fixes a few compiler warnings that were encountered with gcc 9.3.0. Signed-off-by: George Matsumura <gmmatsumura01@bvsd.org>
* meson: Fix musl buildGeorge Matsumura2020-09-021-1/+1
| | | | | | | This constitutes few fixes that are necessary to compile correctly and reduce errors when using musl libc. Signed-off-by: George Matsumura <gmmatsumura01@bvsd.org>
* meson: Fix undefined reference when bfd library is installedTing-Wei Lan2020-08-311-0/+4
| | | | Add the missing file which is necessary when symbol lookup is enabled.
* Add meson build definitionsMathieu Duponchelle2020-07-311-0/+30
| | | | | | | Co-Authored by: Nirbheek Chauhan <nirbheek@centricular.com> lb90 <luca.bacci982@gmail.com> Tim-Philipp Müller <tim@centricular.com>
* Add support for RGBA128F and RGB96F formats.Maarten Lankhorst2019-01-071-1/+11
| | | | | | | | | | | | | | IGT wants to add support for planes with a bit depth >10, which requires a higher precision format than we have currently. I'm using RGBA as format, because of its existence in OpenGL. With the new formats we can directly convert our bytes to half float, or multiply a colro vector with a matrix to go to the Y'CbCr colorspace. This requires pixman 0.36.0, so bump the version requirement. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Bryce Harrington <bryce@bryceharrington.org>
* cairo-trace: Simplify bigendian case in emit_image.Maarten Lankhorst2019-01-071-20/+5
| | | | | | | | | | All the cases are the same, except len is different. Use the already calculated len parameter to handle all cases except RGB24 the same. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Suggested-by: Bryce Harrington <bryce@bryceharrington.org> Reviewed-by: Bryce Harrington <bryce@bryceharrington.org>
* Use HTTPS URLs for gnome.org domainsPaul Menzel2018-10-161-1/+1
| | | | | | | | Run the command below suggested by geirha in ##sed@irc.freenode.net. git grep -l 'http://.*gnome.org' | xargs sed -i 's|http\(://\([[:alnum:].-]*\.\)\{0,1\}gnome\.org\)|https\1|g' Signed-off-by: Paul Menzel <pmenzel@molgen.mpg.de>
* script-surface: Check for invalid ids (CID #1159557, 1159558)Bryce Harrington2018-06-131-0/+2
| | | | | | | | | | | | | If the bitmap's min is non-zero, _bitmap_next_id() could break out of its loop early, before initializing the prev variable. prev would then be dereferenced without a null ptr check. This condition should never occur in practice, so add an assert() to assure it doesn't. Same issue is present in trace.c. Coverity IDs: #1159557, #1159558 Reviewed-By: Uli Schlachter <psychon@znc.in> Signed-off-by: Bryce Harrington <bryce@bryceharrington.org>
* fix compiler warningsAdrian Johnson2016-10-041-0/+1
|
* Bug 29319 - Modules are built as versioned shared objectsBehdad Esfahbod2016-09-021-1/+1
| | | | Fixes https://bugs.freedesktop.org/show_bug.cgi?id=29319
* Add CAIRO_STATUS_WIN32_GDI_ERROR for GDI errorsAdrian Johnson2016-03-261-0/+1
|
* Add CAIRO_STATUS_FREETYPE_ERROR for errors returned by libfreetypeAdrian Johnson2016-03-261-0/+1
|
* Adding missing error status to utilsAdrian Johnson2016-03-261-0/+1
|
* cairo-trace: Fix duplicated surface push on similar-imageEmanuele Aina2015-01-201-2/+1
| | | | | | | | | | | | | | | | | | | | | | The current code results in trace lines with the source surface being pushed on the stack two times instead of one: s1 s1 //ARGB32 48 48 similar-image % s2 Instead of: s1 //ARGB32 48 48 similar-image % s2 This greatly confuses later commands when the script was replayed, causing traces for trivial GTK3 programs to be unplayable, usually yielding the following error: "invalid value (typically too big) for the size of the input (surface, pattern, etc.)" Drop the duplicated entry from the trace line printed by the cairo_surface_create_similar_image() override. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=73580 Signed-off-by: Emanuele Aina <emanuele.aina@collabora.com>
* [trace] Don't print FC_CHARSET, FC_LANG, and FC_CAPABILITYBehdad Esfahbod2014-07-111-4/+17
| | | | | | There are many more that can go, but these take the most bytes. FC_CHARSET needs to go specially because I recently changed its format in fontconfig. Ouch!
* test and util: maintain consistency in the usage of ARRAY_LENGTH macroRavi Nanjundappa2014-04-301-3/+4
| | | | | | | | | | ARRAY_LENGTH macro is used in perf's cairo-perf.h, src's cairoint.h, test's cairo-test.h and in some internal header files of util's directory.So to maintain consistency ARRAY_SIZE is replaced with ARRAY_LENGTH macro. Signed-off-by: Ravi Nanjundappa <nravi.n@samsung.com> Reviewed-by: Bryce Harrington <b.harrington@samsung.com>
* cairo-trace: Stringify CAIRO_STATUS_JBIG2_GLOBAL_MISSINGBryce Harrington2014-01-311-0/+1
| | | | | | | | | | | This error enum was added last September when JBIG2 support was added. Support it as well in the tracing code. This fixes this warning: trace.c:1544:5: warning: enumeration value ‘CAIRO_STATUS_JBIG2_GLOBAL_MISSING’ not handled in switch [-Wswitch] Signed-off-by: Bryce Harrington <b.harrington@samsung.com> Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Fix operand emissionChris Wilson2013-09-271-50/+182
| | | | | | | | | | Recent updates (in the past couple of years) to firefox have exposed numerous bugs in the way we emit the operands. A few off-by-ones, missing surfaces and outright bugs all of which are intermixed into producing a corrupt stack. Reported-by: Siarhei Siamashka <siarhei.siamashka@gmail.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Record set-device-scaleChris Wilson2013-09-051-0/+12
| | | | Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Improve operand emissionChris Wilson2013-06-051-60/+87
| | | | | | | In particular fixing up a couple of corner cases in emitting the right instructions for scaled-fonts and patterns. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Do not forcibly add surfaces to the dictionaryChris Wilson2012-11-281-18/+32
| | | | | | | | Adjust the stack manipulation to avoid moving an unknown surface to the dictionary. Reported-by: Dongyeon Kim <dy5.kim@samsung.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Fix operand emission for map-to-image and unmap-imageChris Wilson2012-11-271-24/+34
| | | | | Reported-by: Dongyeon Kim <dy5.kim@samsung.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Fix propagation of CAIRO_TRACE_OUTDIR to childrenChris Wilson2012-08-111-1/+1
| | | | Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Wrap GL surfacesDongyeon Kim2012-03-191-0/+183
|
* trace: Add breadcrumb for cairo_image_surface_get_data()Chris Wilson2012-03-151-0/+22
| | | | | | | | | Just emit a marker for when cairo_image_surface_get_data() is called on a surface so that we have a breadcrumb for when the pixels are first exported. (Though note that pointer may be kept around and used much later.) Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* doc: fix a few typos found by codespellNis Martensen2012-03-101-1/+1
| | | | Signed-off-by: Uli Schlachter <psychon@znc.in>
* trace: Remove the warning about the unstable formatChris Wilson2011-11-251-1/+0
| | | | | | We're stuck with the PostScript style for this generation now. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* Convert cairo_mime_surface_t to cairo_raster_source_pattern_tChris Wilson2011-11-251-15/+12
| | | | | | | | | | As discussed, overloading the cairo_surface_t semantics to include sources (i.e. read-only surfaces) was duplicating the definition of cairo_pattern_t. So rather than introduce a new surface type with pattern semantics, start along the thorny road of extensible pattern types. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Emit an stack operation to create a pattern from an undefined surfaceChris Wilson2011-09-271-3/+14
| | | | Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* Introduce a new compositor architectureChris Wilson2011-09-121-28/+86
| | | | | | | | | | | | | | | | | | Having spent the last dev cycle looking at how we could specialize the compositors for various backends, we once again look for the commonalities in order to reduce the duplication. In part this is motivated by the idea that spans is a good interface for both the existent GL backend and pixman, and so they deserve a dedicated compositor. xcb/xlib target an identical rendering system and so they should be using the same compositor, and it should be possible to run that same compositor locally against pixman to generate reference tests. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> P.S. This brings massive upheaval (read breakage) I've tried delaying in order to fix as many things as possible but now this one patch does far, far, far too much. Apologies in advance for breaking your favourite backend, but trust me in that the end result will be much better. :)
* api: Extend cairo_antialias_t to include performace/quality hintsChris Wilson2011-08-301-0/+5
| | | | | | | | | | | The existing API only described the method to be used for performing rasterisation and unlike other API provided no opportunity for the user to give a hint as to how to trade off performance against speed. So in order to no be overly prescriptive, we extend the NONE/GRAY/SUBPIXEL methods with FAST/GOOD/BEST hints and leave the backend to decide how best to achieve those goals. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* Introduce cairo_mime_surface_tChris Wilson2011-08-151-0/+49
| | | | | | | | | | | The mime surface is a user-callback surface designed for interfacing cairo with an opaque data source. For instance, in a web browser, the incoming page may be laid out and rendered to a recording surface before all the image data has finished being downloaded. In this circumstance we need to pass a place holder to cairo and to supply the image data later upon demand. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* trace: Pop the surface after write-to-pngChris Wilson2011-08-101-2/+2
| | | | | | | | | It is convenient if the user can simply enable the use of the commented write-to-png operation just by removing the preceding '%'. However, to do so we need to make sure that the line is stack-neutral and so need to pop the surface that we place onto the stack after writing the png. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
* Remove useless checks for NULL before freeingAndrea Canciani2011-07-311-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch has been generated by the following Coccinelle semantic patch: // Remove useless checks for NULL before freeing // // free (NULL) is a no-op, so there is no need to avoid it @@ expression E; @@ + free (E); + E = NULL; - if (unlikely (E != NULL)) { - free(E); ( - E = NULL; | - E = 0; ) ... - } @@ expression E; @@ + free (E); - if (unlikely (E != NULL)) { - free (E); - }