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

Unified Diff: webrtc/test/video_capturer.h

Issue 2716643002: Add framerate to VideoSinkWants and ability to signal on overuse (Closed)
Patch Set: Comments Created 3 years, 9 months 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
« no previous file with comments | « webrtc/test/vcm_capturer.cc ('k') | webrtc/test/video_capturer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/test/video_capturer.h
diff --git a/webrtc/test/video_capturer.h b/webrtc/test/video_capturer.h
index 111f986643d37956c847bc1406628d4b1e4b6858..667d89c89c55804db90014b27506be3ab9361f7e 100644
--- a/webrtc/test/video_capturer.h
+++ b/webrtc/test/video_capturer.h
@@ -12,23 +12,42 @@
#include <stddef.h>
+#include <memory>
+
+#include "webrtc/api/video/i420_buffer.h"
#include "webrtc/api/video/video_frame.h"
+#include "webrtc/base/criticalsection.h"
+#include "webrtc/base/optional.h"
+#include "webrtc/media/base/videoadapter.h"
#include "webrtc/media/base/videosourceinterface.h"
-namespace webrtc {
+namespace cricket {
+class VideoAdapter;
+} // namespace cricket
+namespace webrtc {
class Clock;
-
namespace test {
class VideoCapturer : public rtc::VideoSourceInterface<VideoFrame> {
public:
- virtual ~VideoCapturer() {}
+ VideoCapturer();
+ virtual ~VideoCapturer();
virtual void Start() = 0;
virtual void Stop() = 0;
+
+ void AddOrUpdateSink(rtc::VideoSinkInterface<VideoFrame>* sink,
+ const rtc::VideoSinkWants& wants) override;
+
+ protected:
+ rtc::Optional<VideoFrame> AdaptFrame(const VideoFrame& frame);
+ rtc::VideoSinkWants GetSinkWants();
+
+ private:
+ const std::unique_ptr<cricket::VideoAdapter> video_adapter_;
};
-} // test
-} // webrtc
+} // namespace test
+} // namespace webrtc
#endif // WEBRTC_TEST_VIDEO_CAPTURER_H_
« no previous file with comments | « webrtc/test/vcm_capturer.cc ('k') | webrtc/test/video_capturer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698