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

Unified Diff: content/browser/renderer_host/media/video_capture_controller.cc

Issue 22875047: EVEA cleanup: use video utility functions in media::* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@git-svn
Patch Set: b2b1b2ee Last comments. Created 7 years, 4 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: content/browser/renderer_host/media/video_capture_controller.cc
diff --git a/content/browser/renderer_host/media/video_capture_controller.cc b/content/browser/renderer_host/media/video_capture_controller.cc
index bac43289a214164353fe028bf61d7c311ec02431..3efc4ce26edf02b563027172c47cd4104634d7d0 100644
--- a/content/browser/renderer_host/media/video_capture_controller.cc
+++ b/content/browser/renderer_host/media/video_capture_controller.cc
@@ -573,8 +573,11 @@ void VideoCaptureController::DoFrameInfoOnIOThread() {
return;
scoped_refptr<VideoCaptureBufferPool> buffer_pool =
- new VideoCaptureBufferPool(frame_info_.width * frame_info_.height * 3 / 2,
- kNoOfBuffers);
+ new VideoCaptureBufferPool(
+ media::VideoFrame::AllocationSize(
+ media::VideoFrame::I420,
+ gfx::Size(frame_info_.width, frame_info_.height)),
+ kNoOfBuffers);
// Check whether all buffers were created successfully.
if (!buffer_pool->Allocate()) {

Powered by Google App Engine
This is Rietveld 408576698