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

Side by Side Diff: content/renderer/media/media_stream_dependency_factory.h

Issue 12383016: Merge AssociateStreamWithProducer message into CreateStream message for both audio output and input. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 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 | Annotate | Revision Log
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_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 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 WebKit::WebRTCPeerConnectionHandlerClient* client); 64 WebKit::WebRTCPeerConnectionHandlerClient* client);
65 65
66 // CreateNativeMediaSources creates libjingle representations of 66 // CreateNativeMediaSources creates libjingle representations of
67 // the underlying sources to the tracks in |description|. 67 // the underlying sources to the tracks in |description|.
68 // |sources_created| is invoked when the sources have either been created and 68 // |sources_created| is invoked when the sources have either been created and
69 // transitioned to a live state or failed. 69 // transitioned to a live state or failed.
70 // The libjingle sources is stored in the extra data field of 70 // The libjingle sources is stored in the extra data field of
71 // WebMediaStreamSource. 71 // WebMediaStreamSource.
72 // |audio_constraints| and |video_constraints| set parameters for the sources. 72 // |audio_constraints| and |video_constraints| set parameters for the sources.
73 void CreateNativeMediaSources( 73 void CreateNativeMediaSources(
74 int render_view_id,
74 const WebKit::WebMediaConstraints& audio_constraints, 75 const WebKit::WebMediaConstraints& audio_constraints,
75 const WebKit::WebMediaConstraints& video_constraints, 76 const WebKit::WebMediaConstraints& video_constraints,
76 WebKit::WebMediaStream* description, 77 WebKit::WebMediaStream* description,
77 const MediaSourcesCreatedCallback& sources_created); 78 const MediaSourcesCreatedCallback& sources_created);
78 79
79 // Creates a libjingle representation of a MediaStream and stores 80 // Creates a libjingle representation of a MediaStream and stores
80 // it in the extra data field of |description|. 81 // it in the extra data field of |description|.
81 void CreateNativeLocalMediaStream( 82 void CreateNativeLocalMediaStream(
82 WebKit::WebMediaStream* description); 83 WebKit::WebMediaStream* description);
83 84
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 // Asks the PeerConnection factory to create a Local Video Source. 141 // Asks the PeerConnection factory to create a Local Video Source.
141 virtual scoped_refptr<webrtc::VideoSourceInterface> 142 virtual scoped_refptr<webrtc::VideoSourceInterface>
142 CreateLocalVideoSource( 143 CreateLocalVideoSource(
143 int video_session_id, 144 int video_session_id,
144 bool is_screen_cast, 145 bool is_screen_cast,
145 const webrtc::MediaConstraintsInterface* constraints); 146 const webrtc::MediaConstraintsInterface* constraints);
146 147
147 // Initializes the source using audio parameters for the selected 148 // Initializes the source using audio parameters for the selected
148 // capture device and specifies which capture device to use as capture 149 // capture device and specifies which capture device to use as capture
149 // source. 150 // source.
150 virtual bool InitializeAudioSource(const StreamDeviceInfo& device_info); 151 virtual bool InitializeAudioSource(int render_view_id,
152 const StreamDeviceInfo& device_info);
151 153
152 // Creates a media::AudioCapturerSource with an implementation that is 154 // Creates a media::AudioCapturerSource with an implementation that is
153 // specific for a WebAudio source. The created WebAudioCapturerSource 155 // specific for a WebAudio source. The created WebAudioCapturerSource
154 // instance will function as audio source instead of the default 156 // instance will function as audio source instead of the default
155 // WebRtcAudioCapturer. 157 // WebRtcAudioCapturer.
156 virtual bool CreateWebAudioSource(WebKit::WebMediaStreamSource* source); 158 virtual bool CreateWebAudioSource(WebKit::WebMediaStreamSource* source);
157 159
158 // Asks the PeerConnection factory to create a Local AudioTrack object. 160 // Asks the PeerConnection factory to create a Local AudioTrack object.
159 virtual scoped_refptr<webrtc::AudioTrackInterface> 161 virtual scoped_refptr<webrtc::AudioTrackInterface>
160 CreateLocalAudioTrack(const std::string& id, 162 CreateLocalAudioTrack(const std::string& id,
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 talk_base::Thread* signaling_thread_; 198 talk_base::Thread* signaling_thread_;
197 talk_base::Thread* worker_thread_; 199 talk_base::Thread* worker_thread_;
198 base::Thread chrome_worker_thread_; 200 base::Thread chrome_worker_thread_;
199 201
200 DISALLOW_COPY_AND_ASSIGN(MediaStreamDependencyFactory); 202 DISALLOW_COPY_AND_ASSIGN(MediaStreamDependencyFactory);
201 }; 203 };
202 204
203 } // namespace content 205 } // namespace content
204 206
205 #endif // CONTENT_RENDERER_MEDIA_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ 207 #endif // CONTENT_RENDERER_MEDIA_MEDIA_STREAM_DEPENDENCY_FACTORY_H_
OLDNEW
« no previous file with comments | « content/renderer/media/audio_renderer_mixer_manager.cc ('k') | content/renderer/media/media_stream_dependency_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698