Commit Graph

14 Commits

Author SHA1 Message Date
Ahmad Samir
f5d574b3ad clang-tidy: one declaration per line; braces around statements
clang-tidy checks:
readability-isolate-declaration and readability-braces-around-statements

KF task: https://phabricator.kde.org/T14729

GIT_SILENT
2021-08-13 15:13:21 +02:00
Ahmad Samir
1169859b07 Run clang-format on all cpp/h files
NO_CHANGELOG
2021-03-08 20:15:33 +02:00
Gary Wang
6cf05cf305 test: don't convert image format if possible 2020-11-10 13:03:37 +08:00
Andreas Cord-Landwehr
f4281984c1 Adapt license to LGPL-2.0-or-later
According to relicensecheck Brad is OK with changing LGPLv2 to LGPLv2+,
which is required to be compatible with the LGPL-2.1-or-later licensed
source files.
2020-07-21 09:26:47 +00:00
David Faure
1d12b345f9 GIT_SILENT add missing newline 2020-03-29 01:06:42 +01:00
David Faure
becd7aff3a autotests: print QImageReader::supportedImageFormats, to debug CI failures 2020-03-29 00:47:47 +01:00
Albert Astals Cid
75ef81a109 QImage::byteCount -> QImage::sizeInByes 2019-07-04 22:26:53 +02:00
Albert Astals Cid
a24ece396a autotests: Also exercise canRead 2019-03-31 20:58:26 +02:00
Laurent Montel
f1c6c15b06 compile without foreach
Summary: compile without foreach

Reviewers: dfaure, apol

Reviewed By: apol

Subscribers: apol, kde-frameworks-devel

Tags: #frameworks

Differential Revision: https://phabricator.kde.org/D19317
2019-02-28 23:02:41 +01:00
Albert Astals Cid
03c3c07004 Fix tests on jenkins
Qt also has a tga image plugin so unless we make sure ours is used first
tests are not testing what they should

On a side note their plugin fails our tests so someone with enough time
should report the failures to them
2019-01-28 21:27:22 +01:00
Montel Laurent
d7f457a124 Use QStringLiteral 2015-11-02 21:57:43 +01:00
Alex Merry
0f795e6625 Implement fuzzy image matching in readtest
Images are converted to ARGB32 format, then each byte (ie: each pixel
channel) in the read image is allowed to deviate by some specified
amount from the corresponding byte in the expected image, to allow for
rounding errors etc.

By default, no deviation is permitted, but the XCF tests are allowed a
deviation of 1, as the alpha blending can result in rounding errors
(depending on whether hardware acceleration is used, for example).  In
the end, we are not too concerned about a small deviation that is
invisible to the human eye.

REVIEW: 116567
2014-03-05 12:10:45 +00:00
Alex Merry
6d24f585b1 read autotest: write out data when comparison fails
This helps with debugging, as we can just grab the data rather than
using imageconvertor.

Reviewed-by: David Faure
2014-03-01 14:49:38 +00:00
Alex Merry
f0f6d14367 Add simple autotests
Two main tests: read the file and compare to a given image (loaded from
png), and write a file out and compare to a previously-written image.

The write test in particular is kind of fragile, but it should help
catch some errors where a code change was not intended to affect the
output of the plugin.

Tests are included for all the writable formats, as well as every
readable format that GIMP can write to (and so I could easily get an
example of).

REVIEW: 115430
2014-02-03 15:03:29 +00:00