Commit 98410244 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/jpeg2000dwt: More special cases to handle singularities in 9/7 decode

Fixes Ticket4634
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 63eaf529
......@@ -365,6 +365,8 @@ static void sr_1d97_float(float *p, int i0, int i1)
if (i1 <= i0 + 1) {
if (i0 == 1)
p[1] *= F_LFTG_K/2;
else
p[0] *= F_LFTG_X/2;
return;
}
......@@ -440,6 +442,8 @@ static void sr_1d97_int(int32_t *p, int i0, int i1)
if (i1 <= i0 + 1) {
if (i0 == 1)
p[1] = (p[1] * I_LFTG_K + (1<<16)) >> 17;
else
p[0] = (p[0] * I_LFTG_X + (1<<16)) >> 17;
return;
}
......
dfb35e733795195c6519ecc37e953931 *tests/data/fate/vsynth1-jpeg2000-97.avi
2243136 tests/data/fate/vsynth1-jpeg2000-97.avi
e1a095b40d7f6440f6c46f2995c4759c *tests/data/fate/vsynth1-jpeg2000-97.out.rawvideo
stddev: 6.23 PSNR: 32.23 MAXDIFF: 75 bytes: 7603200/ 7603200
30a9c13e18fe4acaf28062b5003bb671 *tests/data/fate/vsynth1-jpeg2000-97.out.rawvideo
stddev: 6.41 PSNR: 31.99 MAXDIFF: 75 bytes: 7603200/ 7603200
f8880f48a46ad43623d00de15ecba2cd *tests/data/fate/vsynth2-jpeg2000-97.avi
1467472 tests/data/fate/vsynth2-jpeg2000-97.avi
e523db4385f586d73aa0ee2688a75d2e *tests/data/fate/vsynth2-jpeg2000-97.out.rawvideo
stddev: 5.44 PSNR: 33.41 MAXDIFF: 57 bytes: 7603200/ 7603200
9ec4f90641d5d0e6424184b654923676 *tests/data/fate/vsynth2-jpeg2000-97.out.rawvideo
stddev: 6.32 PSNR: 32.11 MAXDIFF: 57 bytes: 7603200/ 7603200
ba27504dcabe43d6608798c9cadc5cca *tests/data/fate/vsynth_lena-jpeg2000-97.avi
1118956 tests/data/fate/vsynth_lena-jpeg2000-97.avi
8ac8b9ee81fa73c873668e9f6b78764d *tests/data/fate/vsynth_lena-jpeg2000-97.out.rawvideo
stddev: 4.95 PSNR: 34.23 MAXDIFF: 60 bytes: 7603200/ 7603200
9d69ac6d46152ed2d6dd6a90d5793c80 *tests/data/fate/vsynth_lena-jpeg2000-97.out.rawvideo
stddev: 5.32 PSNR: 33.61 MAXDIFF: 60 bytes: 7603200/ 7603200
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment