| 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 #ifndef CONTENT_RENDERER_MEDIA_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ |
| 6 #define CONTENT_RENDERER_MEDIA_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ | 6 #define CONTENT_RENDERER_MEDIA_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 204 virtual scoped_refptr<webrtc::VideoTrackInterface> | 204 virtual scoped_refptr<webrtc::VideoTrackInterface> |
| 205 CreateLocalVideoTrack(const std::string& id, | 205 CreateLocalVideoTrack(const std::string& id, |
| 206 cricket::VideoCapturer* capturer); | 206 cricket::VideoCapturer* capturer); |
| 207 | 207 |
| 208 virtual bool EnsurePeerConnectionFactory(); | 208 virtual bool EnsurePeerConnectionFactory(); |
| 209 virtual bool PeerConnectionFactoryCreated(); | 209 virtual bool PeerConnectionFactoryCreated(); |
| 210 | 210 |
| 211 // Returns a new capturer or existing capturer based on the |render_view_id| | 211 // Returns a new capturer or existing capturer based on the |render_view_id| |
| 212 // and |device_info|. When the |render_view_id| and |device_info| are valid, | 212 // and |device_info|. When the |render_view_id| and |device_info| are valid, |
| 213 // it reuses existing capture if any; otherwise it creates a new capturer. | 213 // it reuses existing capture if any; otherwise it creates a new capturer. |
| 214 virtual scoped_refptr<WebRtcAudioCapturer> MaybeCreateAudioCapturer( | 214 virtual scoped_refptr<WebRtcAudioCapturer> CreateAudioCapturer( |
| 215 int render_view_id, const StreamDeviceInfo& device_info); | 215 int render_view_id, const StreamDeviceInfo& device_info); |
| 216 | 216 |
| 217 private: | 217 private: |
| 218 // Creates and deletes |pc_factory_|, which in turn is used for | 218 // Creates and deletes |pc_factory_|, which in turn is used for |
| 219 // creating PeerConnection objects. | 219 // creating PeerConnection objects. |
| 220 bool CreatePeerConnectionFactory(); | 220 bool CreatePeerConnectionFactory(); |
| 221 | 221 |
| 222 void InitializeWorkerThread(talk_base::Thread** thread, | 222 void InitializeWorkerThread(talk_base::Thread** thread, |
| 223 base::WaitableEvent* event); | 223 base::WaitableEvent* event); |
| 224 | 224 |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 263 base::Thread chrome_worker_thread_; | 263 base::Thread chrome_worker_thread_; |
| 264 | 264 |
| 265 base::PlatformFile aec_dump_file_; | 265 base::PlatformFile aec_dump_file_; |
| 266 | 266 |
| 267 DISALLOW_COPY_AND_ASSIGN(MediaStreamDependencyFactory); | 267 DISALLOW_COPY_AND_ASSIGN(MediaStreamDependencyFactory); |
| 268 }; | 268 }; |
| 269 | 269 |
| 270 } // namespace content | 270 } // namespace content |
| 271 | 271 |
| 272 #endif // CONTENT_RENDERER_MEDIA_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ | 272 #endif // CONTENT_RENDERER_MEDIA_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ |
| OLD | NEW |