Index: webrtc/media/base/videosourceinterface.h |
diff --git a/webrtc/media/base/videosourceinterface.h b/webrtc/media/base/videosourceinterface.h |
index 14624585432194c74bec680c6f18befb56ce79f5..ef647fab66b04e1155231be9664942313946b56d 100644 |
--- a/webrtc/media/base/videosourceinterface.h |
+++ b/webrtc/media/base/videosourceinterface.h |
@@ -11,8 +11,11 @@ |
#ifndef WEBRTC_MEDIA_BASE_VIDEOSOURCEINTERFACE_H_ |
#define WEBRTC_MEDIA_BASE_VIDEOSOURCEINTERFACE_H_ |
+#include <limits> |
+ |
#include "webrtc/media/base/videosinkinterface.h" |
#include "webrtc/base/callback.h" |
+#include "webrtc/base/optional.h" |
namespace rtc { |
@@ -27,6 +30,21 @@ struct VideoSinkWants { |
// Tells the source whether the sink wants frames with rotation applied. |
// By default, the rotation is applied by the source. |
bool rotation_applied = true; |
+ |
+ struct ResolutionRequest { |
+ enum Request { kLargerThan, kSmallerThan }; |
+ Request request; |
+ int seen_number_of_pixels; |
+ |
+ bool operator==(const ResolutionRequest& rh) const { |
+ return request == rh.request && |
+ seen_number_of_pixels == rh.seen_number_of_pixels; |
+ } |
+ bool operator!=(const ResolutionRequest& rh) const { |
+ return !operator==(rh); |
+ } |
+ }; |
+ rtc::Optional<ResolutionRequest> resolution; |
}; |
template <typename VideoFrameT> |