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

Side by Side Diff: content/public/common/media_stream_request.h

Issue 2323913007: Add constructor taking group ID to MediaStreamDevice and StreamDeviceInfo (Closed)
Patch Set: Fix constructor Created 4 years, 3 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 #ifndef CONTENT_PUBLIC_COMMON_MEDIA_STREAM_REQUEST_H_ 5 #ifndef CONTENT_PUBLIC_COMMON_MEDIA_STREAM_REQUEST_H_
6 #define CONTENT_PUBLIC_COMMON_MEDIA_STREAM_REQUEST_H_ 6 #define CONTENT_PUBLIC_COMMON_MEDIA_STREAM_REQUEST_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 // audio or some video device. 87 // audio or some video device.
88 CONTENT_EXPORT bool IsAudioInputMediaType(MediaStreamType type); 88 CONTENT_EXPORT bool IsAudioInputMediaType(MediaStreamType type);
89 CONTENT_EXPORT bool IsVideoMediaType(MediaStreamType type); 89 CONTENT_EXPORT bool IsVideoMediaType(MediaStreamType type);
90 CONTENT_EXPORT bool IsScreenCaptureMediaType(MediaStreamType type); 90 CONTENT_EXPORT bool IsScreenCaptureMediaType(MediaStreamType type);
91 91
92 // TODO(xians): Change the structs to classes. 92 // TODO(xians): Change the structs to classes.
93 // Represents one device in a request for media stream(s). 93 // Represents one device in a request for media stream(s).
94 struct CONTENT_EXPORT MediaStreamDevice { 94 struct CONTENT_EXPORT MediaStreamDevice {
95 MediaStreamDevice(); 95 MediaStreamDevice();
96 96
97 MediaStreamDevice( 97 MediaStreamDevice(MediaStreamType type,
98 MediaStreamType type, 98 const std::string& id,
99 const std::string& id, 99 const std::string& name);
100 const std::string& name);
101 100
102 MediaStreamDevice( 101 MediaStreamDevice(MediaStreamType type,
103 MediaStreamType type, 102 const std::string& id,
104 const std::string& id, 103 const std::string& name,
105 const std::string& name, 104 const std::string& group_id);
106 int sample_rate, 105
107 int channel_layout, 106 MediaStreamDevice(MediaStreamType type,
108 int frames_per_buffer); 107 const std::string& id,
108 const std::string& name,
109 const std::string& group_id,
110 int sample_rate,
111 int channel_layout,
112 int frames_per_buffer);
109 113
110 MediaStreamDevice(const MediaStreamDevice& other); 114 MediaStreamDevice(const MediaStreamDevice& other);
111 115
112 ~MediaStreamDevice(); 116 ~MediaStreamDevice();
113 117
114 bool IsEqual(const MediaStreamDevice& second) const; 118 bool IsEqual(const MediaStreamDevice& second) const;
115 119
116 // The device's type. 120 // The device's type.
117 MediaStreamType type; 121 MediaStreamType type;
118 122
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after
271 275
272 // Callback used return results of media access requests. 276 // Callback used return results of media access requests.
273 typedef base::Callback<void(const MediaStreamDevices& devices, 277 typedef base::Callback<void(const MediaStreamDevices& devices,
274 content::MediaStreamRequestResult result, 278 content::MediaStreamRequestResult result,
275 std::unique_ptr<MediaStreamUI> ui)> 279 std::unique_ptr<MediaStreamUI> ui)>
276 MediaResponseCallback; 280 MediaResponseCallback;
277 281
278 } // namespace content 282 } // namespace content
279 283
280 #endif // CONTENT_PUBLIC_COMMON_MEDIA_STREAM_REQUEST_H_ 284 #endif // CONTENT_PUBLIC_COMMON_MEDIA_STREAM_REQUEST_H_
OLDNEW
« no previous file with comments | « content/common/media/media_stream_options.cc ('k') | content/public/common/media_stream_request.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698