Reland "Update video_quality_analysis to align videos instead of using barcodes"
This is a reland of d65e143801a7aaa9affdb939ea836aec1955cdcc
The binary for frame_analyzer.cpp is precompiled and stored in the cloud, so it
won't automatically pick up change to the source file. Therefore, restore all
old code to be backwards compatible.
Original change's description:
> Update video_quality_analysis to align videos instead of using barcodes
>
> This CL is a follow-up to the previous CL
> https://webrtc-review.googlesource.com/c/src/+/94773 that added generic
> logic for aligning videos. This will allow us to easily extend
> video_quality_analysis with new sophisticated video quality metrics.
> Also, we can use any kind of video that does not necessarily need to
> contain bar codes. Removing the need to decode barcodes also leads to a
> big speedup for the tests.
>
> Bug: webrtc:9642
> Change-Id: I74b0d630b3e1ed44781ad024115ded3143e28f50
> Reviewed-on: https://webrtc-review.googlesource.com/94845
> Reviewed-by: Paulina Hensman <phensman@webrtc.org>
> Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
> Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#24423}
TBR=phensman@webrtc.org,phoglund@webrtc.org
Bug: webrtc:9642
Change-Id: Id8d129ce103284504c67690f8363c03eaae3eee7
Reviewed-on: https://webrtc-review.googlesource.com/96000
Reviewed-by: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Patrik Höglund <phoglund@webrtc.org>
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#24429}
diff --git a/examples/androidtests/video_quality_loopback_test.py b/examples/androidtests/video_quality_loopback_test.py
index 225f885..52ae3b1 100755
--- a/examples/androidtests/video_quality_loopback_test.py
+++ b/examples/androidtests/video_quality_loopback_test.py
@@ -165,8 +165,6 @@
def RunTest(android_device, adb_path, build_dir, temp_dir, num_retries,
chartjson_result_file):
ffmpeg_path = os.path.join(TOOLCHAIN_DIR, 'ffmpeg')
- def ConvertVideo(input_video, output_video):
- _RunCommand([ffmpeg_path, '-y', '-i', input_video, output_video])
# Start loopback call and record video.
test_script = os.path.join(
@@ -183,13 +181,6 @@
reference_video = os.path.join(SRC_DIR,
'resources', 'reference_video_640x360_30fps.y4m')
- test_video_yuv = os.path.join(temp_dir, 'test_video.yuv')
- reference_video_yuv = os.path.join(
- temp_dir, 'reference_video_640x360_30fps.yuv')
-
- ConvertVideo(test_video, test_video_yuv)
- ConvertVideo(reference_video, reference_video_yuv)
-
# Run comparison script.
compare_script = os.path.join(SRC_DIR, 'rtc_tools', 'compare_videos.py')
frame_analyzer = os.path.join(TOOLCHAIN_DIR, 'frame_analyzer')
@@ -198,8 +189,8 @@
stats_file_test = os.path.join(temp_dir, 'stats_test.txt')
args = [
- '--ref_video', reference_video_yuv,
- '--test_video', test_video_yuv,
+ '--ref_video', reference_video,
+ '--test_video', test_video,
'--yuv_frame_width', '640',
'--yuv_frame_height', '360',
'--stats_file_ref', stats_file_ref,