mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2024-11-23 19:49:56 +00:00
tests: Convert lavf container tests to non-legacy test scripts
Rename some tests in the process for consistency and simplicity.
This commit is contained in:
parent
896fe15dbb
commit
618d02c1fa
@ -62,6 +62,7 @@ include $(SRC_PATH)/tests/fate/vcodec.mak
|
||||
|
||||
include $(SRC_PATH)/tests/fate/avformat.mak
|
||||
include $(SRC_PATH)/tests/fate/lavf-audio.mak
|
||||
include $(SRC_PATH)/tests/fate/lavf-container.mak
|
||||
include $(SRC_PATH)/tests/fate/lavf-image.mak
|
||||
include $(SRC_PATH)/tests/fate/lavf-image2pipe.mak
|
||||
include $(SRC_PATH)/tests/fate/seek.mak
|
||||
|
@ -197,6 +197,15 @@ lavf_audio(){
|
||||
do_avconv_crc $file $DEC_OPTS $3 -i $target_path/$file
|
||||
}
|
||||
|
||||
lavf_container(){
|
||||
t="${test#lavf-}"
|
||||
outdir="tests/data/lavf"
|
||||
file=${outdir}/lavf.$t
|
||||
do_avconv $file $DEC_OPTS -f image2 -c:v pgmyuv -i $raw_src $DEC_OPTS -ar 44100 -f s16le $1 -i $pcm_src $ENC_OPTS -b:a 64k -t 1 -qscale:v 10 $2
|
||||
test $3 = "disable_crc" ||
|
||||
do_avconv_crc $file $DEC_OPTS -i $target_path/$file $3
|
||||
}
|
||||
|
||||
lavf_image(){
|
||||
t="${test#lavf-}"
|
||||
outdir="tests/data/images/$t"
|
||||
|
@ -1,18 +1,4 @@
|
||||
FATE_LAVF-$(call ENCDEC2, MSMPEG4V3, MP2, ASF) += asf
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG4, MP2, AVI) += avi
|
||||
FATE_LAVF-$(call ENCDEC2, DVVIDEO, PCM_S16LE, AVI) += dv_fmt
|
||||
FATE_LAVF-$(call ENCDEC, FLV, FLV) += flv_fmt
|
||||
FATE_LAVF-$(call ENCDEC, GIF, IMAGE2) += gif
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG2VIDEO, PCM_S16LE, GXF) += gxf
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG4, MP2, MATROSKA) += mkv
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG4, PCM_ALAW, MOV) += mov
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG1VIDEO, MP2, MPEG1SYSTEM MPEGPS) += mpg
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG2VIDEO, PCM_S16LE, MXF) += mxf
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG2VIDEO, PCM_S16LE, MXF_D10 MXF) += mxf_d10
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG4, MP2, NUT) += nut
|
||||
FATE_LAVF-$(call ENCMUX, RV10 AC3_FIXED, RM) += rm
|
||||
FATE_LAVF-$(call ENCDEC, FLV, SWF) += swf
|
||||
FATE_LAVF-$(call ENCDEC2, MPEG2VIDEO, MP2, MPEGTS) += ts
|
||||
FATE_LAVF-$(CONFIG_YUV4MPEGPIPE_MUXER) += yuv4mpeg
|
||||
|
||||
FATE_LAVF += $(FATE_LAVF-yes:%=fate-lavf-%)
|
||||
|
37
tests/fate/lavf-container.mak
Normal file
37
tests/fate/lavf-container.mak
Normal file
@ -0,0 +1,37 @@
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MSMPEG4V3, MP2, ASF) += asf
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG4, MP2, AVI) += avi
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, DVVIDEO, PCM_S16LE, AVI) += dv
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC, FLV, FLV) += flv
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG2VIDEO, PCM_S16LE, GXF) += gxf
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG4, MP2, MATROSKA) += mkv
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG4, PCM_ALAW, MOV) += mov
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG1VIDEO, MP2, MPEG1SYSTEM MPEGPS) += mpg
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG2VIDEO, PCM_S16LE, MXF) += mxf
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG2VIDEO, PCM_S16LE, MXF_D10 MXF) += mxf_d10
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG4, MP2, NUT) += nut
|
||||
FATE_LAVF_CONTAINER-$(call ENCMUX, RV10 AC3_FIXED, RM) += rm
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC, FLV, SWF) += swf
|
||||
FATE_LAVF_CONTAINER-$(call ENCDEC2, MPEG2VIDEO, MP2, MPEGTS) += ts
|
||||
|
||||
FATE_LAVF_CONTAINER = $(FATE_LAVF_CONTAINER-yes:%=fate-lavf-%)
|
||||
|
||||
$(FATE_LAVF_CONTAINER): CMD = lavf_container
|
||||
$(FATE_LAVF_CONTAINER): REF = $(SRC_PATH)/tests/ref/lavf/$(@:fate-lavf-%=%)
|
||||
$(FATE_LAVF_CONTAINER): $(AREF) $(VREF)
|
||||
|
||||
fate-lavf-asf: CMD = lavf_container "" "-c:a mp2 -ar 44100" "-r 25"
|
||||
fate-lavf-avi fate-lavf-nut: CMD = lavf_container "" "-c:a mp2 -ar 44100"
|
||||
fate-lavf-dv: CMD = lavf_container "-ar 48000 -channel_layout stereo" "-r 25 -s pal"
|
||||
fate-lavf-flv fate-lavf-swf: CMD = lavf_container "" "-an"
|
||||
fate-lavf-gxf: CMD = lavf_container "-ar 48000" "-r 25 -s pal -ac 1"
|
||||
fate-lavf-mkv: CMD = lavf_container "" "-c:a mp2 -c:v mpeg4 -ar 44100"
|
||||
fate-lavf-mov: CMD = lavf_container "" "-c:a pcm_alaw -c:v mpeg4"
|
||||
fate-lavf-mpg: CMD = lavf_container "" "-ar 44100"
|
||||
fate-lavf-mxf: CMD = lavf_container "-ar 48000" "-bf 2 -timecode_frame_start 264363"
|
||||
fate-lavf-mxf_d10: CMD = lavf_container "-ar 48000 -ac 2" "-r 25 -vf scale=720:576,pad=720:608:0:32 -c:v mpeg2video -g 0 -flags +ildct+low_delay -dc 10 -non_linear_quant 1 -intra_vlc 1 -qscale 1 -ps 1 -qmin 1 -rc_max_vbv_use 1 -rc_min_vbv_use 1 -pix_fmt yuv422p -minrate 30000k -maxrate 30000k -b 30000k -bufsize 1200000 -top 1 -rc_init_occupancy 1200000 -qmax 12 -f mxf_d10"
|
||||
# The RealMedia muxer is broken.
|
||||
fate-lavf-rm: CMD = lavf_container "" "-c:a ac3_fixed" disable_crc
|
||||
fate-lavf-ts: CMD = lavf_container "" "-mpegts_transport_stream_id 42 -ar 44100"
|
||||
|
||||
FATE_AVCONV += $(FATE_LAVF_CONTAINER)
|
||||
fate-lavf-container fate-lavf: $(FATE_LAVF_CONTAINER)
|
@ -150,8 +150,8 @@ FATE_SEEK_LAVF-$(call ENCDEC2, MSMPEG4V3, MP2, ASF) += asf
|
||||
FATE_SEEK_LAVF-$(call ENCDEC, PCM_S16BE, AU) += au
|
||||
FATE_SEEK_LAVF-$(call ENCDEC2, MPEG4, MP2, AVI) += avi
|
||||
FATE_SEEK_LAVF-$(call ENCDEC, BMP, IMAGE2) += bmp
|
||||
FATE_SEEK_LAVF-$(call ENCDEC2, DVVIDEO, PCM_S16LE, AVI) += dv_fmt
|
||||
FATE_SEEK_LAVF-$(call ENCDEC, FLV, FLV) += flv_fmt
|
||||
FATE_SEEK_LAVF-$(call ENCDEC2, DVVIDEO, PCM_S16LE, AVI) += dv
|
||||
FATE_SEEK_LAVF-$(call ENCDEC, FLV, FLV) += flv
|
||||
FATE_SEEK_LAVF-$(call ENCDEC, GIF, IMAGE2) += gif
|
||||
FATE_SEEK_LAVF-$(call ENCDEC2, MPEG2VIDEO, PCM_S16LE, GXF) += gxf
|
||||
FATE_SEEK_LAVF-$(call ENCDEC, MJPEG, IMAGE2) += jpg
|
||||
@ -186,8 +186,8 @@ fate-seek-lavf-asf: SRC = lavf/lavf.asf
|
||||
fate-seek-lavf-au: SRC = lavf/lavf.au
|
||||
fate-seek-lavf-avi: SRC = lavf/lavf.avi
|
||||
fate-seek-lavf-bmp: SRC = images/bmp/%02d.bmp
|
||||
fate-seek-lavf-dv_fmt: SRC = lavf/lavf.dv
|
||||
fate-seek-lavf-flv_fmt: SRC = lavf/lavf.flv
|
||||
fate-seek-lavf-dv: SRC = lavf/lavf.dv
|
||||
fate-seek-lavf-flv: SRC = lavf/lavf.flv
|
||||
fate-seek-lavf-gif: SRC = lavf/lavf.gif
|
||||
fate-seek-lavf-gxf: SRC = lavf/lavf.gxf
|
||||
fate-seek-lavf-jpg: SRC = images/jpg/%02d.jpg
|
||||
|
@ -11,73 +11,6 @@ set -e
|
||||
|
||||
eval do_$test=y
|
||||
|
||||
do_lavf()
|
||||
{
|
||||
file=${outfile}lavf.$1
|
||||
do_avconv $file $DEC_OPTS -f image2 -c:v pgmyuv -i $raw_src $DEC_OPTS -ar 44100 -f s16le $2 -i $pcm_src $ENC_OPTS -b:a 64k -t 1 -qscale:v 10 $3
|
||||
test $5 = "disable_crc" ||
|
||||
do_avconv_crc $file $DEC_OPTS -i $target_path/$file $4
|
||||
}
|
||||
|
||||
if [ -n "$do_avi" ] ; then
|
||||
do_lavf avi "" "-c:a mp2 -ar 44100"
|
||||
fi
|
||||
|
||||
if [ -n "$do_asf" ] ; then
|
||||
do_lavf asf "" "-c:a mp2 -ar 44100" "-r 25"
|
||||
fi
|
||||
|
||||
if [ -n "$do_rm" ] ; then
|
||||
file=${outfile}lavf.rm
|
||||
# The RealMedia muxer is broken.
|
||||
do_lavf rm "" "-c:a ac3_fixed" "" disable_crc
|
||||
fi
|
||||
|
||||
if [ -n "$do_mpg" ] ; then
|
||||
do_lavf mpg "" "-ar 44100"
|
||||
fi
|
||||
|
||||
if [ -n "$do_mxf" ] ; then
|
||||
do_lavf mxf "-ar 48000" "-bf 2 -timecode_frame_start 264363"
|
||||
fi
|
||||
|
||||
if [ -n "$do_mxf_d10" ]; then
|
||||
do_lavf mxf_d10 "-ar 48000 -ac 2" "-r 25 -vf scale=720:576,pad=720:608:0:32 -c:v mpeg2video -g 0 -flags +ildct+low_delay -dc 10 -non_linear_quant 1 -intra_vlc 1 -qscale 1 -ps 1 -qmin 1 -rc_max_vbv_use 1 -rc_min_vbv_use 1 -pix_fmt yuv422p -minrate 30000k -maxrate 30000k -b 30000k -bufsize 1200000 -top 1 -rc_init_occupancy 1200000 -qmax 12 -f mxf_d10"
|
||||
fi
|
||||
|
||||
if [ -n "$do_ts" ] ; then
|
||||
do_lavf ts "" "-mpegts_transport_stream_id 42 -ar 44100"
|
||||
fi
|
||||
|
||||
if [ -n "$do_swf" ] ; then
|
||||
do_lavf swf "" "-an"
|
||||
fi
|
||||
|
||||
if [ -n "$do_flv_fmt" ] ; then
|
||||
do_lavf flv "" "-an"
|
||||
fi
|
||||
|
||||
if [ -n "$do_mov" ] ; then
|
||||
do_lavf mov "" "-c:a pcm_alaw -c:v mpeg4"
|
||||
fi
|
||||
|
||||
if [ -n "$do_dv_fmt" ] ; then
|
||||
do_lavf dv "-ar 48000 -channel_layout stereo" "-r 25 -s pal"
|
||||
fi
|
||||
|
||||
if [ -n "$do_gxf" ] ; then
|
||||
do_lavf gxf "-ar 48000" "-r 25 -s pal -ac 1"
|
||||
fi
|
||||
|
||||
if [ -n "$do_nut" ] ; then
|
||||
do_lavf nut "" "-c:a mp2 -ar 44100"
|
||||
fi
|
||||
|
||||
if [ -n "$do_mkv" ] ; then
|
||||
do_lavf mkv "" "-c:a mp2 -c:v mpeg4 -ar 44100"
|
||||
fi
|
||||
|
||||
|
||||
# streamed images
|
||||
# mjpeg
|
||||
#file=${outfile}lavf.mjpeg
|
||||
|
@ -1,3 +1,3 @@
|
||||
33e857a06b2b5dedce0bf76c9973944c *./tests/data/lavf/lavf.asf
|
||||
333379 ./tests/data/lavf/lavf.asf
|
||||
./tests/data/lavf/lavf.asf CRC=0xf6340a10
|
||||
33e857a06b2b5dedce0bf76c9973944c *tests/data/lavf/lavf.asf
|
||||
333379 tests/data/lavf/lavf.asf
|
||||
tests/data/lavf/lavf.asf CRC=0xf6340a10
|
||||
|
@ -1,3 +1,3 @@
|
||||
e2e7b7ceaf038b259558f41df203ded9 *./tests/data/lavf/lavf.avi
|
||||
330786 ./tests/data/lavf/lavf.avi
|
||||
./tests/data/lavf/lavf.avi CRC=0x4c963cda
|
||||
e2e7b7ceaf038b259558f41df203ded9 *tests/data/lavf/lavf.avi
|
||||
330786 tests/data/lavf/lavf.avi
|
||||
tests/data/lavf/lavf.avi CRC=0x4c963cda
|
||||
|
3
tests/ref/lavf/dv
Normal file
3
tests/ref/lavf/dv
Normal file
@ -0,0 +1,3 @@
|
||||
eb51fbb48af28584ea5515f9f2400fcd *tests/data/lavf/lavf.dv
|
||||
3600000 tests/data/lavf/lavf.dv
|
||||
tests/data/lavf/lavf.dv CRC=0x0e868a82
|
@ -1,3 +0,0 @@
|
||||
eb51fbb48af28584ea5515f9f2400fcd *./tests/data/lavf/lavf.dv
|
||||
3600000 ./tests/data/lavf/lavf.dv
|
||||
./tests/data/lavf/lavf.dv CRC=0x0e868a82
|
3
tests/ref/lavf/flv
Normal file
3
tests/ref/lavf/flv
Normal file
@ -0,0 +1,3 @@
|
||||
689e8e53031a2c0793fb5b99fc6f1024 *tests/data/lavf/lavf.flv
|
||||
329521 tests/data/lavf/lavf.flv
|
||||
tests/data/lavf/lavf.flv CRC=0x881785d1
|
@ -1,3 +0,0 @@
|
||||
689e8e53031a2c0793fb5b99fc6f1024 *./tests/data/lavf/lavf.flv
|
||||
329521 ./tests/data/lavf/lavf.flv
|
||||
./tests/data/lavf/lavf.flv CRC=0x881785d1
|
@ -1,3 +1,3 @@
|
||||
bfc25e31136275aff0f9126610b8a7e4 *./tests/data/lavf/lavf.gxf
|
||||
796428 ./tests/data/lavf/lavf.gxf
|
||||
./tests/data/lavf/lavf.gxf CRC=0xd04c769f
|
||||
bfc25e31136275aff0f9126610b8a7e4 *tests/data/lavf/lavf.gxf
|
||||
796428 tests/data/lavf/lavf.gxf
|
||||
tests/data/lavf/lavf.gxf CRC=0xd04c769f
|
||||
|
@ -1,3 +1,3 @@
|
||||
dad336329ef85127f97e9d12a3b57a59 *./tests/data/lavf/lavf.mkv
|
||||
320383 ./tests/data/lavf/lavf.mkv
|
||||
./tests/data/lavf/lavf.mkv CRC=0x63ed3cda
|
||||
dad336329ef85127f97e9d12a3b57a59 *tests/data/lavf/lavf.mkv
|
||||
320383 tests/data/lavf/lavf.mkv
|
||||
tests/data/lavf/lavf.mkv CRC=0x63ed3cda
|
||||
|
@ -1,3 +1,3 @@
|
||||
e46f42ed71a589ac356e9cfad4e1e56a *./tests/data/lavf/lavf.mov
|
||||
356797 ./tests/data/lavf/lavf.mov
|
||||
./tests/data/lavf/lavf.mov CRC=0xe3f4950d
|
||||
e46f42ed71a589ac356e9cfad4e1e56a *tests/data/lavf/lavf.mov
|
||||
356797 tests/data/lavf/lavf.mov
|
||||
tests/data/lavf/lavf.mov CRC=0xe3f4950d
|
||||
|
@ -1,3 +1,3 @@
|
||||
7df31ba8a5909e3c88b1d1a3f93c4ec2 *./tests/data/lavf/lavf.mpg
|
||||
372736 ./tests/data/lavf/lavf.mpg
|
||||
./tests/data/lavf/lavf.mpg CRC=0xdd24439e
|
||||
7df31ba8a5909e3c88b1d1a3f93c4ec2 *tests/data/lavf/lavf.mpg
|
||||
372736 tests/data/lavf/lavf.mpg
|
||||
tests/data/lavf/lavf.mpg CRC=0xdd24439e
|
||||
|
@ -1,3 +1,3 @@
|
||||
7c9efc1b6f5fc65bf39177887512fefd *./tests/data/lavf/lavf.mxf
|
||||
525881 ./tests/data/lavf/lavf.mxf
|
||||
./tests/data/lavf/lavf.mxf CRC=0x773f059a
|
||||
7c9efc1b6f5fc65bf39177887512fefd *tests/data/lavf/lavf.mxf
|
||||
525881 tests/data/lavf/lavf.mxf
|
||||
tests/data/lavf/lavf.mxf CRC=0x773f059a
|
||||
|
@ -1,3 +1,3 @@
|
||||
5fbb6252f6b146cd36d1491ca96ad8a3 *./tests/data/lavf/lavf.mxf_d10
|
||||
5330989 ./tests/data/lavf/lavf.mxf_d10
|
||||
./tests/data/lavf/lavf.mxf_d10 CRC=0x4474d480
|
||||
5fbb6252f6b146cd36d1491ca96ad8a3 *tests/data/lavf/lavf.mxf_d10
|
||||
5330989 tests/data/lavf/lavf.mxf_d10
|
||||
tests/data/lavf/lavf.mxf_d10 CRC=0x4474d480
|
||||
|
@ -1,3 +1,3 @@
|
||||
d685d5af89cfddb2660f03b1dee3f9a2 *./tests/data/lavf/lavf.nut
|
||||
319711 ./tests/data/lavf/lavf.nut
|
||||
./tests/data/lavf/lavf.nut CRC=0x4c963cda
|
||||
d685d5af89cfddb2660f03b1dee3f9a2 *tests/data/lavf/lavf.nut
|
||||
319711 tests/data/lavf/lavf.nut
|
||||
tests/data/lavf/lavf.nut CRC=0x4c963cda
|
||||
|
@ -1,2 +1,2 @@
|
||||
9eeb3b91c0a45f519fd7f2efea882cf4 *./tests/data/lavf/lavf.rm
|
||||
346414 ./tests/data/lavf/lavf.rm
|
||||
9eeb3b91c0a45f519fd7f2efea882cf4 *tests/data/lavf/lavf.rm
|
||||
346414 tests/data/lavf/lavf.rm
|
||||
|
@ -1,3 +1,3 @@
|
||||
62c5aeb636fc82cf6ba6277d36e42cb5 *./tests/data/lavf/lavf.swf
|
||||
329479 ./tests/data/lavf/lavf.swf
|
||||
./tests/data/lavf/lavf.swf CRC=0x881785d1
|
||||
62c5aeb636fc82cf6ba6277d36e42cb5 *tests/data/lavf/lavf.swf
|
||||
329479 tests/data/lavf/lavf.swf
|
||||
tests/data/lavf/lavf.swf CRC=0x881785d1
|
||||
|
@ -1,3 +1,3 @@
|
||||
7a479525b7dc9264291cb2fc3e1d28e5 *./tests/data/lavf/lavf.ts
|
||||
406456 ./tests/data/lavf/lavf.ts
|
||||
./tests/data/lavf/lavf.ts CRC=0xb4ca6cdc
|
||||
7a479525b7dc9264291cb2fc3e1d28e5 *tests/data/lavf/lavf.ts
|
||||
406456 tests/data/lavf/lavf.ts
|
||||
tests/data/lavf/lavf.ts CRC=0xb4ca6cdc
|
||||
|
Loading…
Reference in New Issue
Block a user