Add tool for aligning cropped region of video files

This class adds logic for aligning what part of a test video has been
encoded from a reference video. It does that by cropping and zooming in
on a region of the reference video that most closely matches the test
video. A small cropping does not have much impact on human perception,
but it has a big impact on PSNR and SSIM calculations.

For example, if the test video is cropped with one row in the top and
bottom, adjusting for this improves average PSNR from 27.7146 to
29.3357 and average SSIM from 0.934891 to 0.95318 in an example test
video.

TBR=phoglund

Bug: webrtc:9642
Change-Id: I02cfe0e2261fb58df8cdb1e15ba93285e3dc4538
Reviewed-on: https://webrtc-review.googlesource.com/c/99480
Commit-Queue: Magnus Jedvert <magjed@webrtc.org>
Reviewed-by: Patrik Höglund <phoglund@google.com>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#25755}
diff --git a/rtc_tools/BUILD.gn b/rtc_tools/BUILD.gn
index 6f60ab1..5214bc3 100644
--- a/rtc_tools/BUILD.gn
+++ b/rtc_tools/BUILD.gn
@@ -92,6 +92,8 @@
     "frame_analyzer/linear_least_squares.h",
     "frame_analyzer/video_color_aligner.cc",
     "frame_analyzer/video_color_aligner.h",
+    "frame_analyzer/video_geometry_aligner.cc",
+    "frame_analyzer/video_geometry_aligner.h",
     "frame_analyzer/video_quality_analysis.cc",
     "frame_analyzer/video_quality_analysis.h",
     "frame_analyzer/video_temporal_aligner.cc",
@@ -100,6 +102,7 @@
   deps = [
     ":video_file_reader",
     "../api:array_view",
+    "../api/video:video_frame",
     "../api/video:video_frame_i420",
     "../common_video",
     "../rtc_base:checks",
@@ -343,6 +346,7 @@
       "frame_analyzer/linear_least_squares_unittest.cc",
       "frame_analyzer/reference_less_video_analysis_unittest.cc",
       "frame_analyzer/video_color_aligner_unittest.cc",
+      "frame_analyzer/video_geometry_aligner_unittest.cc",
       "frame_analyzer/video_quality_analysis_unittest.cc",
       "frame_analyzer/video_temporal_aligner_unittest.cc",
       "frame_editing/frame_editing_unittest.cc",