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

Side by Side Diff: content/browser/renderer_host/media/media_stream_manager.h

Issue 2634263002: Pass camera facing info to audio client (Closed)
Patch Set: refactor to pass VideoCaptureObserver in setters, not in ctor Created 3 years, 10 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 // MediaStreamManager is used to open media capture devices (video supported 5 // MediaStreamManager is used to open media capture devices (video supported
6 // now). Call flow: 6 // now). Call flow:
7 // 1. GenerateStream is called when a render process wants to use a capture 7 // 1. GenerateStream is called when a render process wants to use a capture
8 // device. 8 // device.
9 // 2. MediaStreamManager will ask MediaStreamUIController for permission to 9 // 2. MediaStreamManager will ask MediaStreamUIController for permission to
10 // use devices and for which device to use. 10 // use devices and for which device to use.
(...skipping 27 matching lines...) Expand all
38 #include "base/message_loop/message_loop.h" 38 #include "base/message_loop/message_loop.h"
39 #include "base/power_monitor/power_observer.h" 39 #include "base/power_monitor/power_observer.h"
40 #include "base/threading/thread.h" 40 #include "base/threading/thread.h"
41 #include "build/build_config.h" 41 #include "build/build_config.h"
42 #include "content/browser/renderer_host/media/media_devices_manager.h" 42 #include "content/browser/renderer_host/media/media_devices_manager.h"
43 #include "content/browser/renderer_host/media/media_stream_provider.h" 43 #include "content/browser/renderer_host/media/media_stream_provider.h"
44 #include "content/common/content_export.h" 44 #include "content/common/content_export.h"
45 #include "content/common/media/media_devices.h" 45 #include "content/common/media/media_devices.h"
46 #include "content/common/media/media_stream_options.h" 46 #include "content/common/media/media_stream_options.h"
47 #include "content/public/browser/media_request_state.h" 47 #include "content/public/browser/media_request_state.h"
48 #include "media/base/video_facing.h"
48 49
49 namespace media { 50 namespace media {
50 class AudioManager; 51 class AudioManager;
51 } 52 }
52 53
53 namespace url { 54 namespace url {
54 class Origin; 55 class Origin;
55 } 56 }
56 57
57 namespace content { 58 namespace content {
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 91
91 // Used to access VideoCaptureManager. 92 // Used to access VideoCaptureManager.
92 VideoCaptureManager* video_capture_manager(); 93 VideoCaptureManager* video_capture_manager();
93 94
94 // Used to access AudioInputDeviceManager. 95 // Used to access AudioInputDeviceManager.
95 AudioInputDeviceManager* audio_input_device_manager(); 96 AudioInputDeviceManager* audio_input_device_manager();
96 97
97 // Used to access MediaDevicesManager. 98 // Used to access MediaDevicesManager.
98 MediaDevicesManager* media_devices_manager(); 99 MediaDevicesManager* media_devices_manager();
99 100
101 void SetVideoCaptureObserver(media::VideoCaptureObserver* capture_observer);
chfremer1 2017/01/25 18:13:44 I recommend that we indicate to the reader that th
shenghao 2017/01/29 10:21:01 Done.
102
100 // Creates a new media access request which is identified by a unique string 103 // Creates a new media access request which is identified by a unique string
101 // that's returned to the caller. This will trigger the infobar and ask users 104 // that's returned to the caller. This will trigger the infobar and ask users
102 // for access to the device. |render_process_id| and |render_frame_id| are 105 // for access to the device. |render_process_id| and |render_frame_id| are
103 // used to determine where the infobar will appear to the user. |callback| is 106 // used to determine where the infobar will appear to the user. |callback| is
104 // used to send the selected device to the clients. An empty list of device 107 // used to send the selected device to the clients. An empty list of device
105 // will be returned if the users deny the access. 108 // will be returned if the users deny the access.
106 std::string MakeMediaAccessRequest( 109 std::string MakeMediaAccessRequest(
107 int render_process_id, 110 int render_process_id,
108 int render_frame_id, 111 int render_frame_id,
109 int page_request_id, 112 int page_request_id,
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
407 std::map<int, base::Callback<void(const std::string&)>> log_callbacks_; 410 std::map<int, base::Callback<void(const std::string&)>> log_callbacks_;
408 411
409 GenerateStreamTestCallback generate_stream_test_callback_; 412 GenerateStreamTestCallback generate_stream_test_callback_;
410 413
411 DISALLOW_COPY_AND_ASSIGN(MediaStreamManager); 414 DISALLOW_COPY_AND_ASSIGN(MediaStreamManager);
412 }; 415 };
413 416
414 } // namespace content 417 } // namespace content
415 418
416 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_MEDIA_STREAM_MANAGER_H_ 419 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_MEDIA_STREAM_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698