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

Side by Side Diff: content/browser/renderer_host/media/video_capture_controller.cc

Issue 760593003: Add PIXEL_FORMAT_NV12 into VideoPixelFormat (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove un-needed mock framewok Created 6 years 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/browser/renderer_host/media/video_capture_controller_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/renderer_host/media/video_capture_controller.h" 5 #include "content/browser/renderer_host/media/video_capture_controller.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 404 matching lines...) Expand 10 before | Expand all | Expand 10 after
415 case media::PIXEL_FORMAT_UNKNOWN: // Color format not set. 415 case media::PIXEL_FORMAT_UNKNOWN: // Color format not set.
416 break; 416 break;
417 case media::PIXEL_FORMAT_I420: 417 case media::PIXEL_FORMAT_I420:
418 DCHECK(!chopped_width && !chopped_height); 418 DCHECK(!chopped_width && !chopped_height);
419 origin_colorspace = libyuv::FOURCC_I420; 419 origin_colorspace = libyuv::FOURCC_I420;
420 break; 420 break;
421 case media::PIXEL_FORMAT_YV12: 421 case media::PIXEL_FORMAT_YV12:
422 DCHECK(!chopped_width && !chopped_height); 422 DCHECK(!chopped_width && !chopped_height);
423 origin_colorspace = libyuv::FOURCC_YV12; 423 origin_colorspace = libyuv::FOURCC_YV12;
424 break; 424 break;
425 case media::PIXEL_FORMAT_NV12:
426 DCHECK(!chopped_width && !chopped_height);
427 origin_colorspace = libyuv::FOURCC_NV12;
428 break;
425 case media::PIXEL_FORMAT_NV21: 429 case media::PIXEL_FORMAT_NV21:
426 DCHECK(!chopped_width && !chopped_height); 430 DCHECK(!chopped_width && !chopped_height);
427 origin_colorspace = libyuv::FOURCC_NV21; 431 origin_colorspace = libyuv::FOURCC_NV21;
428 break; 432 break;
429 case media::PIXEL_FORMAT_YUY2: 433 case media::PIXEL_FORMAT_YUY2:
430 DCHECK(!chopped_width && !chopped_height); 434 DCHECK(!chopped_width && !chopped_height);
431 origin_colorspace = libyuv::FOURCC_YUY2; 435 origin_colorspace = libyuv::FOURCC_YUY2;
432 break; 436 break;
433 case media::PIXEL_FORMAT_UYVY: 437 case media::PIXEL_FORMAT_UYVY:
434 DCHECK(!chopped_width && !chopped_height); 438 DCHECK(!chopped_width && !chopped_height);
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after
708 DCHECK_CURRENTLY_ON(BrowserThread::IO); 712 DCHECK_CURRENTLY_ON(BrowserThread::IO);
709 int active_client_count = 0; 713 int active_client_count = 0;
710 for (ControllerClient* client : controller_clients_) { 714 for (ControllerClient* client : controller_clients_) {
711 if (!client->paused) 715 if (!client->paused)
712 ++active_client_count; 716 ++active_client_count;
713 } 717 }
714 return active_client_count; 718 return active_client_count;
715 } 719 }
716 720
717 } // namespace content 721 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/browser/renderer_host/media/video_capture_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698