git.shiar.nl
/
sheet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
codec: gif format (best effort comparison)
[sheet.git]
/
codec.inc.pl
diff --git
a/codec.inc.pl
b/codec.inc.pl
index a76b04d0a0c9e4b7dd17750f88a76b184e52d57a..6b6b4e09d0e582e8370dd303b87ddc8183efeb73 100644
(file)
--- a/
codec.inc.pl
+++ b/
codec.inc.pl
@@
-5,6
+5,10
@@
codec => {
name => '<abbr title="Joint Photographic Experts Group">JPEG</abbr>',
available => 1992,
},
name => '<abbr title="Joint Photographic Experts Group">JPEG</abbr>',
available => 1992,
},
+ gif => {
+ name => '<abbr title="Graphics Interchange Format">GIF</abbr>',
+ available => 1987,
+ },
png => {
name => '<abbr title="Portable Network Graphics">PNG</abbr>',
available => 1996,
png => {
name => '<abbr title="Portable Network Graphics">PNG</abbr>',
available => 1996,
@@
-31,10
+35,14
@@
codec => {
},
},
feature => {
},
},
feature => {
+ default => {
+ children => [qw( quality_photo quality_art speed limits features royalties )],
+ },
quality_photo => {
name => 'compression (photo)',
score => {
jpeg => 3,
quality_photo => {
name => 'compression (photo)',
score => {
jpeg => 3,
+ gif => 1,
png => 1,
jp2k => 4,
webp => 3,
png => 1,
jp2k => 4,
webp => 3,
@@
-42,23
+50,28
@@
feature => {
avif => 5,
jxl => 5,
},
avif => 5,
jxl => 5,
},
+ children => [qw( quality_photo_1 quality_photo_2 quality_photo_3 quality_photo_ll )],
},
quality_photo_1 => {
},
quality_photo_1 => {
- name => 'low fidelity',
+ parent => 'quality_photo',
+ name => 'thumbnails',
score => {
jpeg => 2,
score => {
jpeg => 2,
+ gif => 1,
png => 1,
jp2k => 3,
png => 1,
jp2k => 3,
- webp =>
3
,
+ webp =>
4
,
heic => 5,
avif => 5,
heic => 5,
avif => 5,
- jxl =>
4
,
+ jxl =>
3
,
},
},
quality_photo_2 => {
},
},
quality_photo_2 => {
+ parent => 'quality_photo',
name => 'medium fidelity',
score => {
jpeg => 3,
name => 'medium fidelity',
score => {
jpeg => 3,
+ gif => 1,
png => 1,
jp2k => 4,
webp => 3,
png => 1,
jp2k => 4,
webp => 3,
@@
-68,9
+81,11
@@
feature => {
},
},
quality_photo_3 => {
},
},
quality_photo_3 => {
+ parent => 'quality_photo',
name => 'high fidelity',
score => {
jpeg => 3,
name => 'high fidelity',
score => {
jpeg => 3,
+ gif => 1,
png => 2,
jp2k => 4,
webp => 2,
png => 2,
jp2k => 4,
webp => 2,
@@
-80,9
+95,11
@@
feature => {
},
},
quality_photo_ll => {
},
},
quality_photo_ll => {
+ parent => 'quality_photo',
name => 'lossless',
score => {
jpeg => 1,
name => 'lossless',
score => {
jpeg => 1,
+ gif => 1,
png => 2,
jp2k => 4,
webp => 3,
png => 2,
jp2k => 4,
webp => 3,
@@
-95,6
+112,7
@@
feature => {
name => 'compression (other images)',
score => {
jpeg => 2,
name => 'compression (other images)',
score => {
jpeg => 2,
+ gif => 1,
png => 3,
jp2k => 2,
webp => 4,
png => 3,
jp2k => 2,
webp => 4,
@@
-102,11
+120,13
@@
feature => {
avif => 4.5,
jxl => 5,
},
avif => 4.5,
jxl => 5,
},
+ children => [qw( quality_art_2 quality_art_ll quality_art_mixed )],
},
quality_art_2 => {
name => 'lossy non-photographic',
score => {
jpeg => 2,
},
quality_art_2 => {
name => 'lossy non-photographic',
score => {
jpeg => 2,
+ gif => 2,
png => 3,
jp2k => 2,
webp => 4,
png => 3,
jp2k => 2,
webp => 4,
@@
-119,6
+139,7
@@
feature => {
name => 'lossless non-photographic',
score => {
jpeg => 1,
name => 'lossless non-photographic',
score => {
jpeg => 1,
+ gif => 1,
png => 4,
jp2k => 2,
webp => 5,
png => 4,
jp2k => 2,
webp => 5,
@@
-131,6
+152,7
@@
feature => {
name => 'mixed photo/nonphoto',
score => {
jpeg => 2,
name => 'mixed photo/nonphoto',
score => {
jpeg => 2,
+ gif => 1,
png => 2,
jp2k => 2,
webp => 3,
png => 2,
jp2k => 2,
webp => 3,
@@
-142,6
+164,7
@@
feature => {
speed => {
score => {
jpeg => 5,
speed => {
score => {
jpeg => 5,
+ gif => 4,
png => 4,
jp2k => 3,
webp => 4,
png => 4,
jp2k => 3,
webp => 4,
@@
-149,11
+172,14
@@
feature => {
avif => 3,
jxl => 5,
},
avif => 3,
jxl => 5,
},
+ children => [qw( speed_encode speed_decode speed_parallel )],
},
speed_encode => {
},
speed_encode => {
+ parent => 'speed',
name => 'single-core encode',
score => {
jpeg => 5,
name => 'single-core encode',
score => {
jpeg => 5,
+ gif => 3, # palette conversion
png => 3,
jp2k => 4,
webp => 4,
png => 3,
jp2k => 4,
webp => 4,
@@
-163,9
+189,11
@@
feature => {
},
},
speed_decode => {
},
},
speed_decode => {
+ parent => 'speed',
name => 'single-core decode',
score => {
jpeg => 5,
name => 'single-core decode',
score => {
jpeg => 5,
+ gif => 5,
png => 5,
jp2k => 4,
webp => 5,
png => 5,
jp2k => 4,
webp => 5,
@@
-175,9
+203,11
@@
feature => {
},
},
speed_parallel => {
},
},
speed_parallel => {
+ parent => 'speed',
name => 'pararellizable',
score => {
jpeg => 2,
name => 'pararellizable',
score => {
jpeg => 2,
+ gif => 2,
png => 2,
jp2k => 4,
webp => 2,
png => 2,
jp2k => 4,
webp => 2,
@@
-189,6
+219,7
@@
feature => {
limits => {
score => {
jpeg => 3,
limits => {
score => {
jpeg => 3,
+ gif => 2,
png => 4,
jp2k => 5,
webp => 2,
png => 4,
jp2k => 5,
webp => 2,
@@
-196,23
+227,48
@@
feature => {
avif => 4.5,
jxl => 5,
},
avif => 4.5,
jxl => 5,
},
+ children => [qw( max_dimensions max_bitdepth color_444 hdr max_channels )],
},
max_dimensions => {
},
max_dimensions => {
+ parent => 'limits',
name => 'maximum image dimensions',
name => 'maximum image dimensions',
+ score => {
+ jpeg => 3,
+ gif => 3,
+ png => 4,
+ jp2k => 5,
+ webp => 1,
+ heic => 2,
+ avif => 3,
+ jxl => 4,
+ },
data => {
jpeg => '65k²', # 2**16
data => {
jpeg => '65k²', # 2**16
+ gif => '65k²', # 2**16
png => '2G²', # 2**31
jp2k => '4G²', # 2**32
webp => '16k²', # 2**14
png => '2G²', # 2**31
jp2k => '4G²', # 2**32
webp => '16k²', # 2**14
- heic => '8k×4k+', #
2**13
- avif => '
8k×4k+',
+ heic => '8k×4k+', #
8193x4320
+ avif => '
65k²+', # 2**16, 8193x4320 with profile
jxl => '1G²', # 2**30
},
},
max_bitdepth => {
jxl => '1G²', # 2**30
},
},
max_bitdepth => {
+ parent => 'limits',
name => 'precision (max. bit depth)',
name => 'precision (max. bit depth)',
+ score => {
+ jpeg => 2,
+ gif => 2,
+ png => 4,
+ jp2k => 5,
+ webp => 2,
+ heic => 3,
+ avif => 3,
+ jxl => 5,
+ },
data => {
jpeg => 8,
data => {
jpeg => 8,
+ gif => 8,
png => 16,
jp2k => 38,
webp => 8,
png => 16,
jp2k => 38,
webp => 8,
@@
-222,9
+278,11
@@
feature => {
},
},
color_444 => {
},
},
color_444 => {
+ parent => 'limits',
name => 'can do (lossy) 4:4:4',
score => {
jpeg => 'y',
name => 'can do (lossy) 4:4:4',
score => {
jpeg => 'y',
+ gif => 'y',
png => 'y',
jp2k => 'y',
webp => 'n',
png => 'y',
jp2k => 'y',
webp => 'n',
@@
-234,9
+292,11
@@
feature => {
},
},
hdr => {
},
},
hdr => {
+ parent => 'limits',
name => 'wide gamut/HDR',
score => {
jpeg => 'n',
name => 'wide gamut/HDR',
score => {
jpeg => 'n',
+ gif => 'n',
png => 'y',
jp2k => 'y',
webp => 'n',
png => 'y',
jp2k => 'y',
webp => 'n',
@@
-246,9
+306,21
@@
feature => {
},
},
max_channels => {
},
},
max_channels => {
+ parent => 'limits',
name => 'maximum number of channels',
name => 'maximum number of channels',
+ score => {
+ jpeg => 2,
+ gif => 1,
+ png => 2,
+ jp2k => 5,
+ webp => 2,
+ heic => 3,
+ avif => 3,
+ jxl => 4,
+ },
data => {
jpeg => 4, # cmyk
data => {
jpeg => 4, # cmyk
+ gif => 3,
png => 4, # cmyk
jp2k => 2**15,
webp => 4,
png => 4, # cmyk
jp2k => 2**15,
webp => 4,
@@
-260,6
+332,7
@@
feature => {
features => {
score => {
jpeg => 2,
features => {
score => {
jpeg => 2,
+ gif => 2,
png => 3,
jp2k => 4,
webp => 2,
png => 3,
jp2k => 4,
webp => 2,
@@
-267,13
+340,16
@@
feature => {
avif => 4,
jxl => 5,
},
avif => 4,
jxl => 5,
},
+ children => [qw( animation progressive alpha depthmap overlays authoring reencode compat_jpeg )],
},
animation => {
},
animation => {
+ parent => 'features',
name => 'supports animation',
score => {
name => 'supports animation',
score => {
- jpeg => 'n',
- png => 'y',
- jp2k => 'n',
+ jpeg => 2,
+ gif => 'y',
+ png => 4,
+ jp2k => 2,
webp => 'y',
heic => 'y',
avif => 'y',
webp => 'y',
heic => 'y',
avif => 'y',
@@
-286,9
+362,11
@@
feature => {
},
},
progressive => {
},
},
progressive => {
+ parent => 'features',
name => 'progressive decoding',
score => {
jpeg => 4,
name => 'progressive decoding',
score => {
jpeg => 4,
+ gif => 2,
png => 2,
jp2k => 5,
webp => 'n',
png => 2,
jp2k => 5,
webp => 'n',
@@
-298,9
+376,11
@@
feature => {
},
},
alpha => {
},
},
alpha => {
+ parent => 'features',
name => 'alpha transparency',
score => {
jpeg => 'n',
name => 'alpha transparency',
score => {
jpeg => 'n',
+ gif => 3,
png => 'y',
jp2k => 'y',
webp => 'y',
png => 'y',
jp2k => 'y',
webp => 'y',
@@
-308,11
+388,16
@@
feature => {
avif => 'y',
jxl => 'y',
},
avif => 'y',
jxl => 'y',
},
+ data => {
+ gif => '1 bit',
+ },
},
depthmap => {
},
depthmap => {
+ parent => 'features',
name => 'depth map',
score => {
jpeg => 'n',
name => 'depth map',
score => {
jpeg => 'n',
+ gif => 'n',
png => 'n',
jp2k => 'n',
webp => 'n',
png => 'n',
jp2k => 'n',
webp => 'n',
@@
-322,9
+407,11
@@
feature => {
},
},
overlays => {
},
},
overlays => {
- name => 'overlays',
+ parent => 'features',
+ name => 'overlays (layers)',
score => {
jpeg => 'n',
score => {
jpeg => 'n',
+ gif => 'y',
png => 'n',
jp2k => 'n',
webp => 'n',
png => 'n',
jp2k => 'n',
webp => 'n',
@@
-334,9
+421,11
@@
feature => {
},
},
authoring => {
},
},
authoring => {
+ parent => 'features',
name => 'authoring workflow suitability',
score => {
jpeg => 2,
name => 'authoring workflow suitability',
score => {
jpeg => 2,
+ gif => 2,
png => 3,
jp2k => 3,
webp => 2,
png => 3,
jp2k => 3,
webp => 2,
@@
-346,10
+435,12
@@
feature => {
},
},
reencode => {
},
},
reencode => {
+ parent => 'features',
name => 'generation loss resilience',
score => {
jpeg => 4,
name => 'generation loss resilience',
score => {
jpeg => 4,
- png => 'n/a',
+ png => 0,
+ gif => 0,
jp2k => 3,
webp => 2,
heic => 3,
jp2k => 3,
webp => 2,
heic => 3,
@@
-357,13
+448,16
@@
feature => {
jxl => 4,
},
data => {
jxl => 4,
},
data => {
+ gif => 'n/a',
png => 'n/a',
},
},
compat_jpeg => {
png => 'n/a',
},
},
compat_jpeg => {
+ parent => 'features',
name => 'lossless JPEG recompression',
score => {
jpeg => 0,
name => 'lossless JPEG recompression',
score => {
jpeg => 0,
+ gif => 'n',
png => 'n',
jp2k => 'n',
webp => 'n',
png => 'n',
jp2k => 'n',
webp => 'n',
@@
-378,14
+472,16
@@
feature => {
royalties => {
name => 'royalty-free',
score => {
royalties => {
name => 'royalty-free',
score => {
- jpeg => 'y',
- png => 'y',
- jp2k => 'y',
- webp => 'y',
- heic => 'n',
- avif => 'y',
- jxl => 'y',
+ jpeg => 5,
+ gif => 5, # patents expired
+ png => 5,
+ jp2k => 3, # specs not freely available
+ webp => 4, # submarine risk
+ heic => 'n', # patents enforced
+ avif => 4,
+ jxl => 4,
},
},
+ children => [],
},
},
}
},
},
}