Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
a70eac7a
Commit
a70eac7a
authored
Aug 08, 2018
by
Diego Biurrun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tests: Convert image2pipe tests to non-legacy test scripts
parent
5846b496
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
67 additions
and
31 deletions
+67
-31
Makefile
tests/Makefile
+1
-0
fate-run.sh
tests/fate-run.sh
+45
-0
avformat.mak
tests/fate/avformat.mak
+0
-3
lavf-image2pipe.mak
tests/fate/lavf-image2pipe.mak
+12
-0
lavf-regression.sh
tests/lavf-regression.sh
+0
-19
pbmpipe
tests/ref/lavf/pbmpipe
+3
-3
pgmpipe
tests/ref/lavf/pgmpipe
+3
-3
ppmpipe
tests/ref/lavf/ppmpipe
+3
-3
No files found.
tests/Makefile
View file @
a70eac7a
...
...
@@ -61,6 +61,7 @@ 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/lavf-image2pipe.mak
include
$(SRC_PATH)/tests/fate/seek.mak
include
$(SRC_PATH)/tests/fate/aac.mak
...
...
tests/fate-run.sh
View file @
a70eac7a
...
...
@@ -152,6 +152,51 @@ enc_dec(){
tests/tiny_psnr
$srcfile
$decfile
$cmp_unit
$cmp_shift
}
# FIXME: There is a certain duplication between the avconv-related helper
# functions above and below that should be refactored.
avconv2
=
"
$target_exec
${
target_path
}
/avconv"
raw_src
=
"
${
target_path
}
/tests/vsynth1/%02d.pgm"
crcfile
=
"tests/data/
$test
.lavf.crc"
target_crcfile
=
"
${
target_path
}
/
$crcfile
"
echov
(){
echo
"
$@
"
>
&3
}
AVCONV_OPTS
=
"-nostats -y -cpuflags
$cpuflags
-threads
$threads
"
DEC_OPTS
=
"-flags +bitexact -idct simple -sws_flags +accurate_rnd+bitexact -fflags +bitexact"
ENC_OPTS
=
"
$DEC_OPTS
-threads 1 -dct fastint"
run_avconv
(){
$echov
$avconv2
$AVCONV_OPTS
$*
$avconv2
$AVCONV_OPTS
$*
}
do_avconv
(){
f
=
"
$1
"
shift
set
--
$*
${
target_path
}
/
$f
run_avconv
$*
do_md5sum
$f
echo
$(
wc
-c
$f
)
}
do_avconv_crc
(){
f
=
"
$1
"
shift
run_avconv
$*
-f
crc
"
$target_crcfile
"
echo
"
$f
$(
cat
$crcfile
)
"
}
lavf_image2pipe
(){
t
=
"
${
test
#lavf-
}
"
t
=
"
${
t
%pipe
}
"
outdir
=
"tests/data/lavf"
file
=
${
outdir
}
/
${
t
}
pipe.
$t
do_avconv
$file
$DEC_OPTS
-f
image2
-c
:v pgmyuv
-i
$raw_src
-f
image2pipe
$ENC_OPTS
-t
1
-qscale
10
do_avconv_crc
$file
$DEC_OPTS
-f
image2pipe
-i
$target_path
/
$file
}
lavftest
(){
t
=
"
${
test
#lavf-
}
"
ref
=
${
base
}
/ref/lavf/
$t
...
...
tests/fate/avformat.mak
View file @
a70eac7a
...
...
@@ -20,13 +20,10 @@ FATE_LAVF-$(call ENCDEC2, MPEG2VIDEO, PCM_S16LE, MXF_D10 MXF) += mxf_d10
FATE_LAVF-$(call ENCDEC2, MPEG4, MP2, NUT) += nut
FATE_LAVF-$(call ENCDEC, FLAC, OGG) += ogg
FATE_LAVF-$(call ENCDEC, PAM, IMAGE2) += pam
FATE_LAVF-$(call ENCDEC, PBM, IMAGE2PIPE) += pbmpipe
FATE_LAVF-$(call ENCDEC, PCX, IMAGE2) += pcx
FATE_LAVF-$(call ENCDEC, PGM, IMAGE2) += pgm
FATE_LAVF-$(call ENCDEC, PGM, IMAGE2PIPE) += pgmpipe
FATE_LAVF-$(call ENCDEC, PNG, IMAGE2) += png
FATE_LAVF-$(call ENCDEC, PPM, IMAGE2) += ppm
FATE_LAVF-$(call ENCDEC, PPM, IMAGE2PIPE) += ppmpipe
FATE_LAVF-$(call ENCMUX, RV10 AC3_FIXED, RM) += rm
FATE_LAVF-$(call ENCDEC, PCM_U8, RSO) += rso
FATE_LAVF-$(call ENCDEC, SGI, IMAGE2) += sgi
...
...
tests/fate/lavf-image2pipe.mak
0 → 100644
View file @
a70eac7a
FATE_LAVF_IMAGE2PIPE-$(call ENCDEC, PBM, IMAGE2PIPE) += pbmpipe
FATE_LAVF_IMAGE2PIPE-$(call ENCDEC, PGM, IMAGE2PIPE) += pgmpipe
FATE_LAVF_IMAGE2PIPE-$(call ENCDEC, PPM, IMAGE2PIPE) += ppmpipe
FATE_LAVF_IMAGE2PIPE = $(FATE_LAVF_IMAGE2PIPE-yes:%=fate-lavf-%)
$(FATE_LAVF_IMAGE2PIPE): CMD = lavf_image2pipe
$(FATE_LAVF_IMAGE2PIPE): REF = $(SRC_PATH)/tests/ref/lavf/$(@:fate-lavf-%=%)
$(FATE_LAVF_IMAGE2PIPE): $(VREF)
FATE_AVCONV += $(FATE_LAVF_IMAGE2PIPE)
fate-lavf-image2pipe fate-lavf: $(FATE_LAVF_IMAGE2PIPE)
tests/lavf-regression.sh
View file @
a70eac7a
...
...
@@ -19,13 +19,6 @@ do_lavf()
do_avconv_crc
$file
$DEC_OPTS
-i
$target_path
/
$file
$4
}
do_streamed_images
()
{
file
=
${
outfile
}${
1
}
pipe.
$1
do_avconv
$file
$DEC_OPTS
-f
image2
-c
:v pgmyuv
-i
$raw_src
-f
image2pipe
$ENC_OPTS
-t
1
-qscale
10
do_avconv_crc
$file
$DEC_OPTS
-f
image2pipe
-i
$target_path
/
$file
}
do_image_formats
()
{
outfile
=
"
$datadir
/images/
$1
/"
...
...
@@ -109,18 +102,6 @@ fi
#do_avconv $file -t 1 -qscale 10 -f image2 -c:v pgmyuv -i $raw_src
#do_avconv_crc $file -i $target_path/$file
if
[
-n
"
$do_pbmpipe
"
]
;
then
do_streamed_images pbm
fi
if
[
-n
"
$do_pgmpipe
"
]
;
then
do_streamed_images pgm
fi
if
[
-n
"
$do_ppmpipe
"
]
;
then
do_streamed_images ppm
fi
if
[
-n
"
$do_gif
"
]
;
then
file
=
${
outfile
}
lavf.gif
do_avconv
$file
$DEC_OPTS
-f
image2
-c
:v pgmyuv
-i
$raw_src
$ENC_OPTS
-t
1
-qscale
10
-pix_fmt
rgb24
...
...
tests/ref/lavf/pbmpipe
View file @
a70eac7a
8ced96f5b6b7362358199ae993b4ceb7 *
./
tests/data/lavf/pbmpipe.pbm
317075
./
tests/data/lavf/pbmpipe.pbm
./
tests/data/lavf/pbmpipe.pbm CRC=0xfae0a1ba
8ced96f5b6b7362358199ae993b4ceb7 *tests/data/lavf/pbmpipe.pbm
317075 tests/data/lavf/pbmpipe.pbm
tests/data/lavf/pbmpipe.pbm CRC=0xfae0a1ba
tests/ref/lavf/pgmpipe
View file @
a70eac7a
04e66c8e9e064c8310bd657ee559bd70 *
./
tests/data/lavf/pgmpipe.pgm
2534775
./
tests/data/lavf/pgmpipe.pgm
./
tests/data/lavf/pgmpipe.pgm CRC=0xadf48ba9
04e66c8e9e064c8310bd657ee559bd70 *tests/data/lavf/pgmpipe.pgm
2534775 tests/data/lavf/pgmpipe.pgm
tests/data/lavf/pgmpipe.pgm CRC=0xadf48ba9
tests/ref/lavf/ppmpipe
View file @
a70eac7a
74f1f6651ad8f192a7b4c11c2b6c71e5 *
./
tests/data/lavf/ppmpipe.ppm
7603575
./
tests/data/lavf/ppmpipe.ppm
./
tests/data/lavf/ppmpipe.ppm CRC=0x87b3c15f
74f1f6651ad8f192a7b4c11c2b6c71e5 *tests/data/lavf/ppmpipe.ppm
7603575 tests/data/lavf/ppmpipe.ppm
tests/data/lavf/ppmpipe.ppm CRC=0x87b3c15f
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment