Add scaling interface to VideoFrameBuffer

This can be overriden for kNative frame types to perform scaling efficiently.

Default implementations for existing buffer types require actual
buffer implementation, thus this CL also merges "video_frame"
with "video_frame_I420" build targets.

Bug: webrtc:11976, chromium:1132299
Change-Id: I3bf5f6bf179db5e7ab165b1c2301980043a08765
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/186303
Commit-Queue: Ilya Nikolaevskiy <ilnik@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Stefan Holmer <stefan@webrtc.org>
Reviewed-by: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Evan Shrubsole <eshr@google.com>
Cr-Commit-Position: refs/heads/master@{#32352}
This commit is contained in:
Ilya Nikolaevskiy
2020-10-08 14:34:14 +02:00
committed by Commit Bot
parent 2d05878689
commit c79f1d8cfb
26 changed files with 179 additions and 133 deletions

View File

@ -54,7 +54,6 @@ public class VideoFrame implements RefCounted {
* Crops a region defined by |cropx|, |cropY|, |cropWidth| and |cropHeight|. Scales it to size
* |scaleWidth| x |scaleHeight|.
*/
@CalledByNative("Buffer")
Buffer cropAndScale(
int cropX, int cropY, int cropWidth, int cropHeight, int scaleWidth, int scaleHeight);
}