]> git.sesse.net Git - ffmpeg/commit
lavfi/deshake: fix deshake crash issue.
authorJun Zhao <mypopydev@gmail.com>
Tue, 18 Sep 2018 06:57:49 +0000 (14:57 +0800)
committerJun Zhao <jun.zhao@intel.com>
Sat, 6 Oct 2018 13:30:18 +0000 (21:30 +0800)
commit5a3ce4a92b84cded3aab7ffd7fb80e0c9130e74c
treebc7165906b625876878cd83e4023c22163d7d970
parent6ff4473012bc0131a3a47ff613c3c0aa5ecb1881
lavfi/deshake: fix deshake crash issue.

Fixes ticket #7441.

for block contrast calculate, the block is like this:

|<---------------- stride-----------------------|
+----------------------------------------------->  X
|
|            w = 16
|    (cx,cy)+------+
|           |      |
|h=blocksize|      |
|           |      |
|           +------+
V

Y

so we calc the block contrast use:
   (cy + y) * stride + (cx + x)

Signed-off-by: Jun Zhao <mypopydev@gmail.com>
libavfilter/vf_deshake.c