Commit 89930744 authored by Loren Merritt's avatar Loren Merritt

cosmetics in regression test


git-svn-id: svn://svn.videolan.org/x264/trunk@626 df754926-b1dd-0310-bc7b-ec298dee348c
parent 6e1bbd2f
...@@ -112,7 +112,7 @@ ifeq (,$(VIDS)) ...@@ -112,7 +112,7 @@ ifeq (,$(VIDS))
fprofiled: fprofiled:
@echo 'usage: make fprofiled VIDS="infile1 infile2 ..."' @echo 'usage: make fprofiled VIDS="infile1 infile2 ..."'
@echo 'where infiles are anything that x264 understands,' @echo 'where infiles are anything that x264 understands,'
@echo 'i.e. YUV with resolution in the filename, or avisynth.' @echo 'i.e. YUV with resolution in the filename, y4m, or avisynth.'
else else
fprofiled: fprofiled:
$(MAKE) clean $(MAKE) clean
...@@ -168,9 +168,15 @@ TAGS: ...@@ -168,9 +168,15 @@ TAGS:
dox: dox:
doxygen Doxyfile doxygen Doxyfile
# usage is same as for fprofiled ifeq (,$(VIDS))
test:
@echo 'usage: make test VIDS="infile1 infile2 ..."'
@echo 'where infiles are anything that x264 understands,'
@echo 'i.e. YUV with resolution in the filename, y4m, or avisynth.'
else
test: test:
perl tools/regression-test.pl --version=head,current --options='$(OPT0)' --options='$(OPT1)' --options='$(OPT2)' $(VIDS:%=--input=%) perl tools/regression-test.pl --version=head,current --options='$(OPT0)' --options='$(OPT1)' --options='$(OPT2)' $(VIDS:%=--input=%)
endif
testclean: testclean:
rm -f test/*.log test/*.264 rm -f test/*.log test/*.264
......
...@@ -74,18 +74,16 @@ foreach my $version (@versions) ...@@ -74,18 +74,16 @@ foreach my $version (@versions)
print("building version: $version\n"); print("building version: $version\n");
if ($version eq "current") if ($version eq "current")
{ {
system("./configure > build.log"); system("(./configure && make) &> test/build.log");
system("make >> build.log 2>&1");
mkpath("test/x264-$version"); mkpath("test/x264-$version");
if (! -e "x264") { print("build failed \n"); exit 1; } if (! -e "x264") { print("build failed \n"); exit 1; }
copy("x264", "test/x264-$version/x264"); copy("x264", "test/x264-$version/x264");
chmod(0755, "test/x264-$version/x264"); chmod(0755, "test/x264-$version/x264");
next; next;
} }
system("svn checkout -$version svn://svn.videolan.org/x264/trunk/ test/x264-$version"); system("svn checkout -$version svn://svn.videolan.org/x264/trunk/ test/x264-$version >/dev/null");
chdir("test/x264-$version"); chdir("test/x264-$version");
system("./configure > build.log"); system("(./configure && make) &> build.log");
system("make >> build.log 2>&1");
chdir("../.."); chdir("../..");
if (! -e "test/x264-$version/x264") { print("build failed \n"); exit 1; } if (! -e "test/x264-$version/x264") { print("build failed \n"); exit 1; }
} }
...@@ -183,7 +181,7 @@ sub compare_logs ...@@ -183,7 +181,7 @@ sub compare_logs
# $is_diff = 1; # $is_diff = 1;
#} #}
return $is_diff; return $is_diff;
# TODO compare frame by frame PSNR/SSIM, record improved or unimproved ranges # TODO compare frame by frame PSNR/SSIM, record improved or unimproved ranges
#parse_log_frame_stats($log1); #parse_log_frame_stats($log1);
...@@ -208,10 +206,10 @@ sub compare_raw264 ...@@ -208,10 +206,10 @@ sub compare_raw264
if ($rawdata1 ne $rawdata2) if ($rawdata1 ne $rawdata2)
{ {
print("compressed files differ \n"); print("compressed files differ \n");
return 1; return 1;
} }
return 0; return 0;
} }
sub parse_log_frame_stats sub parse_log_frame_stats
......
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