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

Unified Diff: webrtc/modules/video_coding/video_sender.cc

Issue 1900193004: Remove VCMPacketizationCallback (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 8 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/modules/video_coding/video_coding_impl.cc ('k') | webrtc/video/send_statistics_proxy.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/modules/video_coding/video_sender.cc
diff --git a/webrtc/modules/video_coding/video_sender.cc b/webrtc/modules/video_coding/video_sender.cc
index 3a1debae520f7e1f40f9488ebd079d00ba98ce98..958f0ed93404fdd37ead22b6233cc431aa239d98 100644
--- a/webrtc/modules/video_coding/video_sender.cc
+++ b/webrtc/modules/video_coding/video_sender.cc
@@ -47,6 +47,7 @@ VideoSender::VideoSender(Clock* clock,
// one external project (diffractor).
_mediaOpt.EnableQM(qm_settings_callback_ != nullptr);
_mediaOpt.Reset();
+ _encodedFrameCallback.SetMediaOpt(&_mediaOpt);
main_thread_.DetachFromThread();
}
@@ -55,11 +56,19 @@ VideoSender::~VideoSender() {}
void VideoSender::Process() {
if (_sendStatsTimer.TimeUntilProcess() == 0) {
_sendStatsTimer.Processed();
+ std::string implementation_name;
+ {
+ rtc::CritScope cs(&encoder_crit_);
pbos-webrtc 2016/04/20 13:48:26 I don't like that ::Process starts blocking on enc
+ if (_encoder) {
+ implementation_name = _encoder->ImplementationName();
+ }
+ }
rtc::CritScope cs(&process_crit_);
if (_sendStatsCallback != nullptr) {
uint32_t bitRate = _mediaOpt.SentBitRate();
uint32_t frameRate = _mediaOpt.SentFrameRate();
- _sendStatsCallback->SendStatistics(bitRate, frameRate);
+ _sendStatsCallback->SendStatistics(bitRate, frameRate,
+ std::move(implementation_name));
}
}
@@ -235,14 +244,6 @@ void VideoSender::SetEncoderParameters(EncoderParameters params) {
_encoder->SetEncoderParameters(params);
}
-int32_t VideoSender::RegisterTransportCallback(
- VCMPacketizationCallback* transport) {
- rtc::CritScope lock(&encoder_crit_);
- _encodedFrameCallback.SetMediaOpt(&_mediaOpt);
- _encodedFrameCallback.SetTransportCallback(transport);
- return VCM_OK;
-}
-
// Register video output information callback which will be called to deliver
// information about the video stream produced by the encoder, for instance the
// average frame rate and bit rate.
« no previous file with comments | « webrtc/modules/video_coding/video_coding_impl.cc ('k') | webrtc/video/send_statistics_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698