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

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

Issue 1865283002: Use microsecond timestamp in cricket::VideoFrame. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Add missing override, intending to reland. 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 | « no previous file | webrtc/media/base/videobroadcaster.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/media/base/fakevideocapturer.h
diff --git a/webrtc/media/base/fakevideocapturer.h b/webrtc/media/base/fakevideocapturer.h
index 89dcf652f1480a3558d91837ee9eca08a14e8ba8..026bf80a7b15f0f83f94bf66a9fe52eb23bc7cd5 100644
--- a/webrtc/media/base/fakevideocapturer.h
+++ b/webrtc/media/base/fakevideocapturer.h
@@ -31,7 +31,7 @@ class FakeVideoCapturer : public cricket::VideoCapturer {
public:
FakeVideoCapturer(bool is_screencast)
: running_(false),
- initial_unix_timestamp_(time(NULL) * rtc::kNumNanosecsPerSec),
+ initial_timestamp_(rtc::TimeNanos()),
next_timestamp_(rtc::kNumNanosecsPerMillisec),
is_screencast_(is_screencast),
rotation_(webrtc::kVideoRotation_0) {
@@ -99,7 +99,7 @@ class FakeVideoCapturer : public cricket::VideoCapturer {
frame.height = height;
frame.fourcc = fourcc;
frame.data_size = size;
- frame.time_stamp = initial_unix_timestamp_ + next_timestamp_;
+ frame.time_stamp = initial_timestamp_ + next_timestamp_;
next_timestamp_ += timestamp_interval;
std::unique_ptr<char[]> data(new char[size]);
@@ -153,7 +153,7 @@ class FakeVideoCapturer : public cricket::VideoCapturer {
private:
bool running_;
- int64_t initial_unix_timestamp_;
+ int64_t initial_timestamp_;
int64_t next_timestamp_;
const bool is_screencast_;
webrtc::VideoRotation rotation_;
« no previous file with comments | « no previous file | webrtc/media/base/videobroadcaster.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698