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

Side by Side Diff: webkit/media/webvideoframe_impl.cc

Issue 10035054: Merge VideoCaptureDevice::Capability with media::VideoCaptureCapability (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 8 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 unified diff | Download patch
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 "webkit/media/webvideoframe_impl.h" 5 #include "webkit/media/webvideoframe_impl.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "media/base/video_frame.h" 8 #include "media/base/video_frame.h"
9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebVideoFrame.h" 9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebVideoFrame.h"
10 10
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 return 1; 66 return 1;
67 case media::VideoFrame::YV12: 67 case media::VideoFrame::YV12:
68 case media::VideoFrame::YV16: 68 case media::VideoFrame::YV16:
69 return 3; 69 return 3;
70 case media::VideoFrame::INVALID: 70 case media::VideoFrame::INVALID:
71 case media::VideoFrame::EMPTY: 71 case media::VideoFrame::EMPTY:
72 case media::VideoFrame::I420: 72 case media::VideoFrame::I420:
73 break; 73 break;
74 case media::VideoFrame::NATIVE_TEXTURE: 74 case media::VideoFrame::NATIVE_TEXTURE:
75 return 0; 75 return 0;
76 case media::VideoFrame::kColorUnknown:
77 case media::VideoFrame::kI420:
78 case media::VideoFrame::kYUY2:
79 case media::VideoFrame::kUYVY:
80 case media::VideoFrame::kRGB24:
81 case media::VideoFrame::kARGB:
82 case media::VideoFrame::kMJPEG:
83 break;
76 } 84 }
77 NOTREACHED(); 85 NOTREACHED();
78 return 0; 86 return 0;
79 } 87 }
80 88
81 int WebVideoFrameImpl::stride(unsigned plane) const { 89 int WebVideoFrameImpl::stride(unsigned plane) const {
82 if (video_frame_.get()) 90 if (video_frame_.get())
83 return static_cast<int>(video_frame_->stride(plane)); 91 return static_cast<int>(video_frame_->stride(plane));
84 return 0; 92 return 0;
85 } 93 }
(...skipping 10 matching lines...) Expand all
96 return video_frame_->texture_id(); 104 return video_frame_->texture_id();
97 } 105 }
98 106
99 unsigned WebVideoFrameImpl::textureTarget() const { 107 unsigned WebVideoFrameImpl::textureTarget() const {
100 if (!video_frame_.get() || format() != FormatNativeTexture) 108 if (!video_frame_.get() || format() != FormatNativeTexture)
101 return 0; 109 return 0;
102 return video_frame_->texture_target(); 110 return video_frame_->texture_target();
103 } 111 }
104 112
105 } // namespace webkit_media 113 } // namespace webkit_media
OLDNEW
« media/base/video_frame.h ('K') | « media/video/capture/win/video_capture_device_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698