aboutsummaryrefslogtreecommitdiffstats
path: root/libavdevice/decklink_common.cpp
diff options
context:
space:
mode:
authorManuel Lauss <manuel.lauss@gmail.com>2025-08-14 00:21:09 +0200
committerManuel Lauss <manuel.lauss@gmail.com>2025-08-18 09:11:09 +0000
commit0226b6fb2c0855eca417feb0a4e3bdf1f1193332 (patch)
tree21bf2cb53128a86dbd00b824ee06506045602ca9 /libavdevice/decklink_common.cpp
parent8426622bb9584ec4fc32215f006a91e7ddc480cc (diff)
downloadffmpeg-0226b6fb2c0855eca417feb0a4e3bdf1f1193332.tar.gz
avcodec/sanm: bl16: fix artifacts in larger videos
The DOS/Windows decoder precomputes a table of linear offsets of all motion vectors given the current image width. For larger widths (>=762), the pairs starting at indices 1 and 254 of motion_vectors[] will overflow the int16_t, changing the sign. Playing back the 800x600 "jonesopn_8.snm" video of "Indiana Jones and the Infernal Machine" reveals a lot of artifacts and a lot of "Ignoring invalid motion vector (149, -41)->(136, 0), block size = 8" messages, hinting at the wrong direction of the motion vectors. Fix this by doing the calculation that the DOS/Windows players do, let the value overflow and reextract the "new" mvec x/y components.
Diffstat (limited to 'libavdevice/decklink_common.cpp')
0 files changed, 0 insertions, 0 deletions