diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-05-27 18:50:18 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-05-27 18:50:18 +0200 |
commit | ee189701a6f7fec56570ee3728d5d80378cbadd3 (patch) | |
tree | 53f1203c4eb82be52d59cb9a0b93dc53b573ebd4 | |
parent | 243cc38d944b1a457178d5984d250321361301b3 (diff) | |
download | ffmpeg-ee189701a6f7fec56570ee3728d5d80378cbadd3.tar.gz |
j2kenc: Allow encoding with the 9/7 wavelet
Also add a fate test that tests 9/7
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavcodec/j2kenc.c | 2 | ||||
-rw-r--r-- | tests/fate/vcodec.mak | 6 | ||||
-rw-r--r-- | tests/ref/vsynth/vsynth1-j2k-97 | 4 | ||||
-rw-r--r-- | tests/ref/vsynth/vsynth2-j2k-97 | 4 |
4 files changed, 13 insertions, 3 deletions
diff --git a/libavcodec/j2kenc.c b/libavcodec/j2kenc.c index 7807552706..bd90d4e55d 100644 --- a/libavcodec/j2kenc.c +++ b/libavcodec/j2kenc.c @@ -985,7 +985,7 @@ static av_cold int j2kenc_init(AVCodecContext *avctx) codsty->nreslevels = 7; codsty->log2_cblk_width = 4; codsty->log2_cblk_height = 4; - codsty->transform = 1; + codsty->transform = avctx->prediction_method; qntsty->nguardbits = 1; diff --git a/tests/fate/vcodec.mak b/tests/fate/vcodec.mak index cc2ad28ba0..167d97ce24 100644 --- a/tests/fate/vcodec.mak +++ b/tests/fate/vcodec.mak @@ -89,9 +89,11 @@ FATE_VCODEC-$(call ENCDEC, JPEGLS, AVI) += jpegls fate-vsynth%-jpegls: ENCOPTS = -sws_flags neighbor+full_chroma_int fate-vsynth%-jpegls: DECOPTS = -sws_flags area -FATE_VCODEC-$(call ENCDEC, J2K, AVI) += j2k -fate-vsynth%-j2k: ENCOPTS = -qscale 7 -strict experimental -pix_fmt rgb24 +FATE_VCODEC-$(call ENCDEC, J2K, AVI) += j2k j2k-97 +fate-vsynth%-j2k: ENCOPTS = -qscale 7 -strict experimental -pred 1 -pix_fmt rgb24 fate-vsynth%-j2k: DECINOPTS = -vcodec j2k -strict experimental +fate-vsynth%-j2k-97: ENCOPTS = -qscale 7 -strict experimental -pix_fmt rgb24 +fate-vsynth%-j2k-97: DECINOPTS = -vcodec j2k -strict experimental FATE_VCODEC-$(call ENCDEC, LJPEG MJPEG, AVI) += ljpeg fate-vsynth%-ljpeg: ENCOPTS = -strict -1 diff --git a/tests/ref/vsynth/vsynth1-j2k-97 b/tests/ref/vsynth/vsynth1-j2k-97 new file mode 100644 index 0000000000..fb1ad8b023 --- /dev/null +++ b/tests/ref/vsynth/vsynth1-j2k-97 @@ -0,0 +1,4 @@ +a8e2db2dc6fcd4c9ea3150dc8d6d7619 *tests/data/fate/vsynth1-j2k-97.avi +2963264 tests/data/fate/vsynth1-j2k-97.avi +68f26a8d366fce47cbd003cadc861cd8 *tests/data/fate/vsynth1-j2k-97.out.rawvideo +stddev: 7.66 PSNR: 30.44 MAXDIFF: 58 bytes: 7603200/ 7603200 diff --git a/tests/ref/vsynth/vsynth2-j2k-97 b/tests/ref/vsynth/vsynth2-j2k-97 new file mode 100644 index 0000000000..b799d18106 --- /dev/null +++ b/tests/ref/vsynth/vsynth2-j2k-97 @@ -0,0 +1,4 @@ +245c0ab429b553b39cac5989bb23c0ce *tests/data/fate/vsynth2-j2k-97.avi +1444170 tests/data/fate/vsynth2-j2k-97.avi +61c52045d566b70886113e2aeb8ddde4 *tests/data/fate/vsynth2-j2k-97.out.rawvideo +stddev: 7.13 PSNR: 31.06 MAXDIFF: 53 bytes: 7603200/ 7603200 |