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

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

Issue 201583003: Implement a source for remote video tracks. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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_MOCK_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ 5 #ifndef CONTENT_RENDERER_MEDIA_MOCK_MEDIA_STREAM_DEPENDENCY_FACTORY_H_
6 #define CONTENT_RENDERER_MEDIA_MOCK_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ 6 #define CONTENT_RENDERER_MEDIA_MOCK_MEDIA_STREAM_DEPENDENCY_FACTORY_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 123
124 protected: 124 protected:
125 virtual ~MockLocalVideoTrack(); 125 virtual ~MockLocalVideoTrack();
126 126
127 private: 127 private:
128 bool enabled_; 128 bool enabled_;
129 std::string id_; 129 std::string id_;
130 TrackState state_; 130 TrackState state_;
131 scoped_refptr<webrtc::VideoSourceInterface> source_; 131 scoped_refptr<webrtc::VideoSourceInterface> source_;
132 webrtc::ObserverInterface* observer_; 132 webrtc::ObserverInterface* observer_;
133 webrtc::VideoRendererInterface* renderer_;
133 }; 134 };
134 135
135 class MockMediaStream : public webrtc::MediaStreamInterface { 136 class MockMediaStream : public webrtc::MediaStreamInterface {
136 public: 137 public:
137 explicit MockMediaStream(const std::string& label); 138 explicit MockMediaStream(const std::string& label);
138 139
139 virtual bool AddTrack(webrtc::AudioTrackInterface* track) OVERRIDE; 140 virtual bool AddTrack(webrtc::AudioTrackInterface* track) OVERRIDE;
140 virtual bool AddTrack(webrtc::VideoTrackInterface* track) OVERRIDE; 141 virtual bool AddTrack(webrtc::VideoTrackInterface* track) OVERRIDE;
141 virtual bool RemoveTrack(webrtc::AudioTrackInterface* track) OVERRIDE; 142 virtual bool RemoveTrack(webrtc::AudioTrackInterface* track) OVERRIDE;
142 virtual bool RemoveTrack(webrtc::VideoTrackInterface* track) OVERRIDE; 143 virtual bool RemoveTrack(webrtc::VideoTrackInterface* track) OVERRIDE;
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 private: 214 private:
214 scoped_refptr <MockAudioSource> last_audio_source_; 215 scoped_refptr <MockAudioSource> last_audio_source_;
215 scoped_refptr <MockVideoSource> last_video_source_; 216 scoped_refptr <MockVideoSource> last_video_source_;
216 217
217 DISALLOW_COPY_AND_ASSIGN(MockMediaStreamDependencyFactory); 218 DISALLOW_COPY_AND_ASSIGN(MockMediaStreamDependencyFactory);
218 }; 219 };
219 220
220 } // namespace content 221 } // namespace content
221 222
222 #endif // CONTENT_RENDERER_MEDIA_MOCK_MEDIA_STREAM_DEPENDENCY_FACTORY_H_ 223 #endif // CONTENT_RENDERER_MEDIA_MOCK_MEDIA_STREAM_DEPENDENCY_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698