Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1533)

Unified Diff: webrtc/sdk/objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h

Issue 2528493004: Add method on AVFoundation capturer to adapt output format. (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/sdk/objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h
diff --git a/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h b/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h
index 2a732b9686b877644541814da1d6a025611362d3..254196d9e1614616319516ee37ca008011324d4f 100644
--- a/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h
+++ b/webrtc/sdk/objc/Framework/Headers/WebRTC/RTCAVFoundationVideoSource.h
@@ -29,6 +29,16 @@ RTC_EXPORT
- (instancetype)init NS_UNAVAILABLE;
+/**
+ * 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;
tkchin_webrtc 2016/11/30 22:08:52 is there a way to do this without touching the cap
magjed_webrtc 2016/12/01 09:31:44 I think this is the "WebRTC" way of doing it. We h
tkchin_webrtc 2016/12/02 22:02:20 I'm totally with you that mobile is a different wo
+
/** Returns whether rear-facing camera is available for use. */
@property(nonatomic, readonly) BOOL canUseBackCamera;

Powered by Google App Engine
This is Rietveld 408576698