diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-04-28 15:34:23 +0400 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-04-28 15:34:23 +0400 |
commit | 124244ec48c1b733b7ad40eee67ae1a205f0162b (patch) | |
tree | 008dc0200bf07f47103ba573a247c8e8ba15fc78 | |
parent | 04001767728fd4ed8b4f9d2ebbb9f9a8c9a7be0d (diff) | |
parent | b963f021b603509b5159873de4919dec441d0782 (diff) |
Merge commit 'b963f021b603509b5159873de4919dec441d0782'
* commit 'b963f021b603509b5159873de4919dec441d0782':
fate: Invoke pixfmts lavfi tests through fate-run.sh
Conflicts:
tests/fate/avfilter.mak
tests/lavfi-regression.sh
Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | tests/Makefile | 4 | ||||
-rwxr-xr-x | tests/fate-run.sh | 22 | ||||
-rw-r--r-- | tests/fate/avfilter.mak | 9 | ||||
-rw-r--r-- | tests/fate/filter-video.mak | 25 | ||||
-rwxr-xr-x | tests/lavfi-regression.sh | 12 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-copy (renamed from tests/ref/lavfi/pixfmts_copy) | 0 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-crop (renamed from tests/ref/lavfi/pixfmts_crop) | 0 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-hflip (renamed from tests/ref/lavfi/pixfmts_hflip) | 0 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-null (renamed from tests/ref/lavfi/pixfmts_null) | 0 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-pad (renamed from tests/ref/lavfi/pixfmts_pad) | 0 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-scale (renamed from tests/ref/lavfi/pixfmts_scale) | 0 | ||||
-rw-r--r-- | tests/ref/fate/filter-pixfmts-vflip (renamed from tests/ref/lavfi/pixfmts_vflip) | 0 |
12 files changed, 54 insertions, 18 deletions
diff --git a/tests/Makefile b/tests/Makefile index b26729396d..8209435501 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -66,9 +66,11 @@ FILTERDEMDECENCMUX = $(call ALLYES, $(1)_FILTER $(2)_DEMUXER $(3)_DECODER $(4)_E include $(SRC_PATH)/tests/fate/acodec.mak include $(SRC_PATH)/tests/fate/vcodec.mak include $(SRC_PATH)/tests/fate/avformat.mak -include $(SRC_PATH)/tests/fate/avfilter.mak include $(SRC_PATH)/tests/fate/seek.mak +#FIXME should be removed +include $(SRC_PATH)/tests/fate/avfilter.mak + include $(SRC_PATH)/tests/fate/aac.mak include $(SRC_PATH)/tests/fate/ac3.mak include $(SRC_PATH)/tests/fate/adpcm.mak diff --git a/tests/fate-run.sh b/tests/fate-run.sh index da4f60eda9..42b9ebb5db 100755 --- a/tests/fate-run.sh +++ b/tests/fate-run.sh @@ -160,6 +160,7 @@ lavftest(){ regtest lavf lavf tests/vsynth1 } +#FIXME should be removed lavfitest(){ cleanfiles="tests/data/lavfi/${test#lavfi-}.nut" regtest lavfi lavfi tests/vsynth1 @@ -183,6 +184,27 @@ pixdesc(){ done } +pixfmts(){ + filter=${test#filter-pixfmts-} + filter_args=$1 + + showfiltfmts="$target_exec $target_path/libavfilter/filtfmts-test" + exclude_fmts=${outfile}${filter}_exclude_fmts + out_fmts=${outfile}${filter}_out_fmts + + # exclude pixel formats which are not supported as input + ffmpeg -pix_fmts list 2>/dev/null | awk 'NR > 8 && /^\..\./ { print $2 }' | sort >$exclude_fmts + $showfiltfmts scale | awk -F '[ \r:]' '/^OUTPUT/{ print $5 }' | sort | comm -23 - $exclude_fmts >$out_fmts + + pix_fmts=$($showfiltfmts $filter | awk -F '[ \r:]' '/^INPUT/{ print $5 }' | sort | comm -12 - $out_fmts) + for pix_fmt in $pix_fmts; do + test=$pix_fmt + video_filter "format=$pix_fmt,$filter=$filter_args" -pix_fmt $pix_fmt + done + + rm $exclude_fmts $out_fmts +} + mkdir -p "$outdir" # Disable globbing: command arguments may contain globbing characters and diff --git a/tests/fate/avfilter.mak b/tests/fate/avfilter.mak index 4c8c26a876..f68bf960c9 100644 --- a/tests/fate/avfilter.mak +++ b/tests/fate/avfilter.mak @@ -1,3 +1,5 @@ +#FIXME the whole file should be removed + FATE_LAVFI = fate-lavfi-alphaextract_rgb \ fate-lavfi-alphaextract_yuv \ fate-lavfi-alphamerge_rgb \ @@ -12,13 +14,6 @@ FATE_LAVFI = fate-lavfi-alphaextract_rgb \ fate-lavfi-overlay_yuv420 \ fate-lavfi-overlay_yuv444 \ fate-lavfi-pad \ - fate-lavfi-pixfmts_copy \ - fate-lavfi-pixfmts_crop \ - fate-lavfi-pixfmts_hflip \ - fate-lavfi-pixfmts_null \ - fate-lavfi-pixfmts_pad \ - fate-lavfi-pixfmts_scale \ - fate-lavfi-pixfmts_vflip \ fate-lavfi-select \ fate-lavfi-setdar \ fate-lavfi-setsar \ diff --git a/tests/fate/filter-video.mak b/tests/fate/filter-video.mak index 75ac03a6b1..f1c0cf4de6 100644 --- a/tests/fate/filter-video.mak +++ b/tests/fate/filter-video.mak @@ -98,6 +98,31 @@ FATE_FILTER_VSYNTH-$(CONFIG_FORMAT_FILTER) += fate-filter-pixdesc fate-filter-pixdesc: CMD = pixdesc +FATE_FILTER_PIXFMTS += fate-filter-pixfmts-copy +fate-filter-pixfmts-copy: CMD = pixfmts + +FATE_FILTER_PIXFMTS += fate-filter-pixfmts-crop +fate-filter-pixfmts-crop: CMD = pixfmts "100:100:100:100" + +FATE_FILTER_PIXFMTS += fate-filter-pixfmts-hflip +fate-filter-pixfmts-hflip: CMD = pixfmts + +FATE_FILTER_PIXFMTS += fate-filter-pixfmts-null +fate-filter-pixfmts-null: CMD = pixfmts + +FATE_FILTER_PIXFMTS += fate-filter-pixfmts-pad +fate-filter-pixfmts-pad: CMD = pixfmts "500:400:20:20" + +FATE_FILTER_PIXFMTS += fate-filter-pixfmts-scale +fate-filter-pixfmts-scale: CMD = pixfmts "200:100" + +FATE_FILTER_PIXFMTS += fate-filter-pixfmts-vflip +fate-filter-pixfmts-vflip: CMD = pixfmts + +$(FATE_FILTER_PIXFMTS): libavfilter/filtfmts-test$(EXESUF) +FATE_FILTER_VSYNTH-$(CONFIG_FORMAT_FILTER) += $(FATE_FILTER_PIXFMTS) + + $(FATE_FILTER_VSYNTH-yes): $(VREF) $(FATE_FILTER_VSYNTH-yes): SRC = $(TARGET_PATH)/tests/vsynth1/%02d.pgm diff --git a/tests/lavfi-regression.sh b/tests/lavfi-regression.sh index 9301914ecb..63f991c6af 100755 --- a/tests/lavfi-regression.sh +++ b/tests/lavfi-regression.sh @@ -5,6 +5,8 @@ # #set -x +#FIXME the whole file should be removed + set -e . $(dirname $0)/regression-funcs.sh @@ -20,7 +22,6 @@ do_video_filter() { $ENC_OPTS -vf "$filters" -vcodec rawvideo $* -f nut md5: } -#should be removed do_lavfi_plain() { vfilters="$2" @@ -29,12 +30,10 @@ do_lavfi_plain() { fi } -#should be removed do_lavfi() { do_lavfi_plain $1 "$2" } -#should be removed do_lavfi_colormatrix() { do_lavfi "${1}1" "$1=$4:$5,$1=$5:$3,$1=$3:$4,$1=$4:$3,$1=$3:$5,$1=$5:$2" do_lavfi "${1}2" "$1=$2:$3,$1=$3:$2,$1=$2:$4,$1=$4:$2,$1=$2:$5,$1=$5:$4" @@ -103,14 +102,7 @@ do_lavfi_pixfmts "field" "field" "bottom" do_lavfi_pixfmts "histeq" "histeq" "antibanding=strong" do_lavfi_pixfmts "il" "il" "luma_mode=d:chroma_mode=d:alpha_mode=d" do_lavfi_pixfmts "kerndeint" "kerndeint" "" "tinterlace=interleave_top," -do_lavfi_pixfmts "pixfmts_copy" "copy" "" -do_lavfi_pixfmts "pixfmts_crop" "crop" "100:100:100:100" -do_lavfi_pixfmts "pixfmts_hflip" "hflip" "" -do_lavfi_pixfmts "pixfmts_null" "null" "" -do_lavfi_pixfmts "pixfmts_pad" "pad" "500:400:20:20" -do_lavfi_pixfmts "pixfmts_scale" "scale" "200:100" do_lavfi_pixfmts "pixfmts_super2xsai" "super2xsai" -do_lavfi_pixfmts "pixfmts_vflip" "vflip" do_lavfi_pixfmts "tinterlace_merge" "tinterlace" "merge" do_lavfi_pixfmts "tinterlace_pad" "tinterlace" "pad" diff --git a/tests/ref/lavfi/pixfmts_copy b/tests/ref/fate/filter-pixfmts-copy index 68ec82837a..68ec82837a 100644 --- a/tests/ref/lavfi/pixfmts_copy +++ b/tests/ref/fate/filter-pixfmts-copy diff --git a/tests/ref/lavfi/pixfmts_crop b/tests/ref/fate/filter-pixfmts-crop index 797aedcf73..797aedcf73 100644 --- a/tests/ref/lavfi/pixfmts_crop +++ b/tests/ref/fate/filter-pixfmts-crop diff --git a/tests/ref/lavfi/pixfmts_hflip b/tests/ref/fate/filter-pixfmts-hflip index ee5c2d36ab..ee5c2d36ab 100644 --- a/tests/ref/lavfi/pixfmts_hflip +++ b/tests/ref/fate/filter-pixfmts-hflip diff --git a/tests/ref/lavfi/pixfmts_null b/tests/ref/fate/filter-pixfmts-null index 68ec82837a..68ec82837a 100644 --- a/tests/ref/lavfi/pixfmts_null +++ b/tests/ref/fate/filter-pixfmts-null diff --git a/tests/ref/lavfi/pixfmts_pad b/tests/ref/fate/filter-pixfmts-pad index 192ff6a430..192ff6a430 100644 --- a/tests/ref/lavfi/pixfmts_pad +++ b/tests/ref/fate/filter-pixfmts-pad diff --git a/tests/ref/lavfi/pixfmts_scale b/tests/ref/fate/filter-pixfmts-scale index 9bc3ced29a..9bc3ced29a 100644 --- a/tests/ref/lavfi/pixfmts_scale +++ b/tests/ref/fate/filter-pixfmts-scale diff --git a/tests/ref/lavfi/pixfmts_vflip b/tests/ref/fate/filter-pixfmts-vflip index 7990c3ec34..7990c3ec34 100644 --- a/tests/ref/lavfi/pixfmts_vflip +++ b/tests/ref/fate/filter-pixfmts-vflip |