Index: webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoSource.h |
diff --git a/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoSource.h b/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoSource.h |
index 96bb6f369973c55ea7345d8528b368fc6cebb4e1..27a58f27cb782eb87d91353b2a45ae1ca06086e4 100644 |
--- a/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoSource.h |
+++ b/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCVideoSource.h |
@@ -12,14 +12,30 @@ |
#import <WebRTC/RTCMacros.h> |
#import <WebRTC/RTCMediaSource.h> |
+#import <WebRTC/RTCVideoCapturer.h> |
NS_ASSUME_NONNULL_BEGIN |
RTC_EXPORT |
-@interface RTCVideoSource : RTCMediaSource |
+ |
+@interface RTCVideoSource : RTCMediaSource <RTCVideoCapturerDelegate> |
- (instancetype)init NS_UNAVAILABLE; |
+// RTCVideoCapturerDelegate protocol implementation. |
+- (void)capturer:(RTCVideoCapturer*)capturer |
+ didCaptureVideoFrame:(RTCVideoFrame*)frame; |
+ |
+/** |
+ * Calling this function will cause frames to be scaled down to the |
+ * requested resolution. Also, frames will be cropped to match the |
+ * requested aspect ratio, and frames will be dropped to match the |
+ * requested fps. The requested aspect ratio is orientation agnostic and |
+ * will be adjusted to maintain the input orientation, so it doesn't |
+ * matter if e.g. 1280x720 or 720x1280 is requested. |
+ */ |
+- (void)adaptOutputFormatToWidth:(int)width height:(int)height fps:(int)fps; |
+ |
@end |
NS_ASSUME_NONNULL_END |