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

Unified Diff: webrtc/video/video_quality_test.cc

Issue 2852463002: Fix video_loopback to work with -duration flag: add missing ntp_timestamp to frames (Closed)
Patch Set: Created 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/video/video_quality_test.cc
diff --git a/webrtc/video/video_quality_test.cc b/webrtc/video/video_quality_test.cc
index 508ba13c836913c462ea89db2c3cb0fe2918550b..b5541702dd0be4b398a6c62810f3b9123a5c7848 100644
--- a/webrtc/video/video_quality_test.cc
+++ b/webrtc/video/video_quality_test.cc
@@ -909,11 +909,13 @@ class VideoAnalyzer : public PacketReceiver,
// Frames from the capturer does not have a rtp timestamp.
// Create one so it can be used for comparison.
RTC_DCHECK_EQ(0, video_frame.timestamp());
+ if (copy.ntp_time_ms() == 0)
+ copy.set_ntp_time_ms(rtc::TimeMillis());
copy.set_timestamp(copy.ntp_time_ms() * 90);
analyzer_->AddCapturedFrameForComparison(copy);
rtc::CritScope lock(&crit_);
if (send_stream_input_)
- send_stream_input_->OnFrame(video_frame);
+ send_stream_input_->OnFrame(copy);
}
// Called when |send_stream_.SetSource()| is called.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698