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

Unified Diff: media/capture/video/fake_video_capture_device.cc

Issue 2068763002: Re-Reland: Make media/capture gn and gyps produce components (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Disable warning 4267 in Win capture.gyp (probs. lost in the previous relanding). Rebase Created 4 years, 6 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
Index: media/capture/video/fake_video_capture_device.cc
diff --git a/media/capture/video/fake_video_capture_device.cc b/media/capture/video/fake_video_capture_device.cc
index 116d2d025043e55a3ce2d1e6e69f288e8dab06fd..2acb5a454c22041017274538f5efde1478a26cf0 100644
--- a/media/capture/video/fake_video_capture_device.cc
+++ b/media/capture/video/fake_video_capture_device.cc
@@ -187,9 +187,9 @@ void FakeVideoCaptureDevice::CaptureUsingOwnBuffers(
base::TimeTicks now = base::TimeTicks::Now();
if (first_ref_time_.is_null())
first_ref_time_ = now;
- client_->OnIncomingCapturedData(fake_frame_.get(), frame_size,
- capture_format_, 0 /* rotation */, now,
- now - first_ref_time_);
+ client_->OnIncomingCapturedData(
+ fake_frame_.get(), static_cast<int>(frame_size), capture_format_,
+ 0u /* rotation */, now, now - first_ref_time_);
BeepAndScheduleNextCapture(
expected_execution_time,
base::Bind(&FakeVideoCaptureDevice::CaptureUsingOwnBuffers,
@@ -222,7 +222,8 @@ void FakeVideoCaptureDevice::CaptureUsingClientBuffers(
VideoFrame::PlaneSize(PIXEL_FORMAT_I420, i,
capture_format_.frame_size)
.GetArea();
- memcpy(capture_buffer->data(i), fake_frame_.get() + offset, plane_size);
+ memcpy(capture_buffer->data(i), fake_frame_.get() + offset,
+ static_cast<int>(plane_size));
offset += plane_size;
}
} else {

Powered by Google App Engine
This is Rietveld 408576698