diff options
author | NRK <nrk@disroot.org> | 2023-05-23 13:36:41 +0200 |
---|---|---|
committer | NRK <nrk@disroot.org> | 2023-05-23 13:36:41 +0200 |
commit | 0e1bc3c045384bca18922accbc50fa6914a67bd0 (patch) | |
tree | 605e9c952fa4b7a160e6c1005e1aa32c2f7998e1 /etc/examples/key-handler | |
parent | e4fceab18f4b7856a2ef6fbabebe1988c1fbfaea (diff) | |
download | nsxiv-0e1bc3c045384bca18922accbc50fa6914a67bd0.tar.zst |
set a default delay if delay is 0 (#445)
gif spec [0] doesn't mention what to do when "Delay Time" is 0.
apng spec [1] states:
| If the the value of the numerator is 0 the decoder should render the
| next frame as quickly as possible, though viewers may impose a
| reasonable lower bound.
webp spec [2]:
| the interpretation of frame duration of 0 (and often <= 10) is
| implementation defined.
so it seems that it's safe to set a default delay for 0 delay frames,
which is what the older gif and webp loaders were already doing. do the
same for the imlib2 multi-frame loader as well.
[0]: https://www.w3.org/Graphics/GIF/spec-gif89a.txt
[1]: https://wiki.mozilla.org/APNG_Specification
[2]: https://developers.google.com/speed/webp/docs/riff_container#animation
Reviewed-on: https://codeberg.org/nsxiv/nsxiv/pulls/445
Reviewed-by: eylles <eylles@noreply.codeberg.org>
Diffstat (limited to 'etc/examples/key-handler')
0 files changed, 0 insertions, 0 deletions