Skip to content

Commit 86e7792

Browse files
Merge pull request #3054 from kesmeey/apng-dispose-blend-reference-tests
Add APNG dispose and blend reference tests
2 parents 7248641 + f52ad41 commit 86e7792

25 files changed

Lines changed: 41 additions & 0 deletions
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# The 3-Clause BSD License
2+
3+
Copyright © web-platform-tests contributors
4+
5+
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
6+
7+
1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
8+
2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
9+
3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
10+
11+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
APNG dispose/blend reference tests copied or derived from Web Platform Tests.
2+
3+
WPT source: https://github.com/web-platform-tests/wpt/tree/b63305b743ed9ce2725d4ae09c5c8f0c40d8e6e1/png/apng
4+
5+
Credits:
6+
- Chris Lilley, main author of the WPT PNG/APNG tests.
7+
- Philip Taylor, author of the earlier APNG testsuite that many WPT APNG tests
8+
were ported from.
9+
10+
These files cover all APNG dispose/blend operation combinations:
11+
12+
WPT files copied as-is:
13+
- support/013.png -> fcTL-dispose-in-region-none.png
14+
- support/015.png -> fcTL-dispose-in-region-background.png
15+
- support/016.png -> fcTL-dispose-in-region-previous.png
16+
- support/018.png -> fcTL-blend-source-transparent.png
17+
18+
The current WPT APNG files cover none+over, none+source, background+over, and
19+
previous+over. The background+source and previous+source combinations do not
20+
exist in WPT, so these two files are derived:
21+
22+
- dispose-background-blend-source.png
23+
- dispose-previous-blend-source.png
24+
25+
The derived files are minimal 3x1 APNGs. Each has an opaque red base frame, a
26+
half-transparent target frame using the dispose/blend operation named by the
27+
file, and a marker frame that makes the target frame's disposal result visible.
28+
29+
The reference frames in tests/reference/png/apng/wpt/ were generated with APNG
30+
Disassembler 2.9 (apngdis), independently of this crate's PNG decoder.
270 Bytes
Loading
270 Bytes
Loading
534 Bytes
Loading
492 Bytes
Loading
613 Bytes
Loading
677 Bytes
Loading
72 Bytes
Loading
78 Bytes
Loading

0 commit comments

Comments
 (0)