Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
36 changes: 36 additions & 0 deletions tests/tests/swfs/visual/define_bits_jpeg2/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
This test verifies various images embedded into a SWF.
If you need to add more images, it's better to copy this test than to extend it.

List of images:

* `01_image.gif` – standard GIF,
* `02_image_i.gif` – GIF with interlacing,
* `03_image_420.jpeg` – JPEG with 4:2:0 chroma subsampling,
* `04_image_422.jpeg` – JPEG with 4:2:2 chroma subsampling,
* `05_image_440.jpeg` – JPEG with 4:4:0 chroma subsampling,
* `06_image_444.jpeg` – JPEG with 4:4:4 chroma subsampling,
* `07_image_ac.jpeg` – JPEG with arithmetic coding,
* `08_image_cmyk.jpeg` – JPEG with CMYK color coding,
* `09_image_fi.jpeg` – JPEG with Fast Integer DCT,
* `10_image_fp.jpeg` – JPEG with Floating-Point DCT,
* `11_image_low_quality.jpeg` – JPEG with low quality,
* `12_image_meta.jpeg` – JPEG with additional metadata,
* `13_image_np.jpeg` – non-progressive JPEG,
* `14_image_rm8.jpeg` – JPEG with restart markers, 8 MCU rows,
* `15_image_rm16.jpeg` – JPEG with restart markers, 16 MCU rows,
* `16_image_rm32.jpeg` – JPEG with restart markers, 32 MCU rows,
* `17_image_8gray.png` – 8-bit gray PNG,
* `18_image_8graya.png` – 8-bit gray PNG with alpha,
* `19_image_8rgb.png` – 8-bit RGB PNG,
* `20_image_8rgba.png` – 8-bit RGB PNG with alpha,
* `21_image_16gray.png` – 16-bit gray PNG,
* `22_image_16graya.png` – 16-bit gray PNG with alpha,
* `23_image_16rgb.png` – 16-bit RGB PNG,
* `24_image_16rgba.png` – 16-bit RGB PNG with alpha,
* `25_image_adam7.png` – PNG with interlacing,
* `26_image_c0.png` – PNG with compression level 0,
* `27_image_c5.png` – PNG with compression level 5,
* `28_image_c9.png` – PNG with compression level 9,
* `29_image_meta.png` – PNG with additional metadata.

Images are embedded sequentially.
Empty file.
Binary file not shown.
18 changes: 18 additions & 0 deletions tests/tests/swfs/visual/define_bits_jpeg2/test.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
num_ticks = 1

# FIXME We're badly decoding JPEG images with 4:2:0 and 4:4:0 chroma subsampling
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the test pattern was rotated by 90 degrees, perhaps some other subsampling options would (also) look wrong!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Always those chroma sample locations...

image

https://www.pcmag.com/encyclopedia/term/chroma-subsampling

image

https://www.sciencedirect.com/topics/engineering/chroma-sample

Notice how there is a difference of horizontal and vertical chroma sample offsets in the different modes.

What I'm also saying is - if the test pattern was magnified just 2x (with nearest interpolation, or even recreated with two-pixel tall gradients) - it would probably look a lot less wrong, even if there's technically a mismatch. And not a lot of real world content is like these images.


[[image_comparisons.output.checks]]
tolerance = 0
max_outliers = 1500

[[image_comparisons.output.checks]]
tolerance = 24
max_outliers = 50

[[image_comparisons.output.checks]]
tolerance = 64
max_outliers = 0

[player_options]
with_renderer = { optional = false, sample_count = 4 }
Loading