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

Unified Diff: webrtc/media/base/videocapturer.h

Issue 1827023002: Get VideoCapturer stats via VideoTrackSourceInterface in StatsCollector, (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Rebase. Created 4 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/media/base/mediachannel.h ('k') | webrtc/media/base/videocapturer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/media/base/videocapturer.h
diff --git a/webrtc/media/base/videocapturer.h b/webrtc/media/base/videocapturer.h
index 4ad102b7f2134921ac4dde176dee400fd7bba978..5ec743aaeedb629704390f4915696d64be7f672d 100644
--- a/webrtc/media/base/videocapturer.h
+++ b/webrtc/media/base/videocapturer.h
@@ -209,9 +209,7 @@ class VideoCapturer : public sigslot::has_slots<>,
// Takes ownership.
void set_frame_factory(VideoFrameFactory* frame_factory);
- // TODO(nisse): Rename function? Or pass the frame format before
- // adaptation in some other way.
- void GetStats(VideoFormat* last_captured_frame_format);
+ bool GetInputSize(int* width, int* height);
// Implements VideoSourceInterface
void AddOrUpdateSink(rtc::VideoSinkInterface<cricket::VideoFrame>* sink,
@@ -275,7 +273,7 @@ class VideoCapturer : public sigslot::has_slots<>,
// Returns true if format doesn't fulfill all applied restrictions.
bool ShouldFilterFormat(const VideoFormat& format) const;
- void UpdateStats(const CapturedFrame* captured_frame);
+ void UpdateInputSize(const CapturedFrame* captured_frame);
rtc::ThreadChecker thread_checker_;
std::string id_;
@@ -298,9 +296,10 @@ class VideoCapturer : public sigslot::has_slots<>,
CoordinatedVideoAdapter video_adapter_;
rtc::CriticalSection frame_stats_crit_;
-
- // The captured frame format before potential adapation.
- VideoFormat last_captured_frame_format_;
+ // The captured frame size before potential adapation.
+ bool input_size_valid_ GUARDED_BY(frame_stats_crit_) = false;
+ int input_width_ GUARDED_BY(frame_stats_crit_);
+ int input_height_ GUARDED_BY(frame_stats_crit_);
// Whether capturer should apply rotation to the frame before signaling it.
bool apply_rotation_;
« no previous file with comments | « webrtc/media/base/mediachannel.h ('k') | webrtc/media/base/videocapturer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698