OLD | NEW |
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/public/common/media_stream_request.h" | 5 #include "content/public/common/media_stream_request.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 | 8 |
9 namespace content { | 9 namespace content { |
10 | 10 |
11 bool IsAudioMediaType(MediaStreamType type) { | 11 bool IsAudioMediaType(MediaStreamType type) { |
12 return (type == content::MEDIA_DEVICE_AUDIO_CAPTURE || | 12 return (type == MEDIA_DEVICE_AUDIO_CAPTURE || |
13 type == content::MEDIA_TAB_AUDIO_CAPTURE || | 13 type == content::MEDIA_TAB_AUDIO_CAPTURE || |
14 type == content::MEDIA_LOOPBACK_AUDIO_CAPTURE); | 14 type == content::MEDIA_LOOPBACK_AUDIO_CAPTURE); |
15 } | 15 } |
16 | 16 |
17 bool IsVideoMediaType(MediaStreamType type) { | 17 bool IsVideoMediaType(MediaStreamType type) { |
18 return (type == content::MEDIA_DEVICE_VIDEO_CAPTURE || | 18 return (type == MEDIA_DEVICE_VIDEO_CAPTURE || |
19 type == content::MEDIA_TAB_VIDEO_CAPTURE || | 19 type == content::MEDIA_TAB_VIDEO_CAPTURE || |
20 type == content::MEDIA_DESKTOP_VIDEO_CAPTURE); | 20 type == content::MEDIA_DESKTOP_VIDEO_CAPTURE); |
21 } | 21 } |
22 | 22 |
23 MediaStreamDevice::MediaStreamDevice() | 23 MediaStreamDevice::MediaStreamDevice() |
24 : type(MEDIA_NO_SERVICE), | 24 : type(MEDIA_NO_SERVICE), |
25 video_facing(MEDIA_VIDEO_FACING_NONE) { | 25 video_facing(MEDIA_VIDEO_FACING_NONE) { |
26 } | 26 } |
27 | 27 |
28 MediaStreamDevice::MediaStreamDevice( | 28 MediaStreamDevice::MediaStreamDevice( |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 request_type(request_type), | 84 request_type(request_type), |
85 requested_audio_device_id(requested_audio_device_id), | 85 requested_audio_device_id(requested_audio_device_id), |
86 requested_video_device_id(requested_video_device_id), | 86 requested_video_device_id(requested_video_device_id), |
87 audio_type(audio_type), | 87 audio_type(audio_type), |
88 video_type(video_type) { | 88 video_type(video_type) { |
89 } | 89 } |
90 | 90 |
91 MediaStreamRequest::~MediaStreamRequest() {} | 91 MediaStreamRequest::~MediaStreamRequest() {} |
92 | 92 |
93 } // namespace content | 93 } // namespace content |
OLD | NEW |