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

Side by Side Diff: talk/app/webrtc/localaudiosource.h

Issue 1522903002: Add a 'remote' property to MediaSourceInterface. Also adding an implementation to the relevant sour… (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Address comments Created 5 years 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
« no previous file with comments | « talk/app/webrtc/audiotrack.cc ('k') | talk/app/webrtc/mediastream_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * libjingle 2 * libjingle
3 * Copyright 2012 Google Inc. 3 * Copyright 2012 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 30 matching lines...) Expand all
41 41
42 class MediaConstraintsInterface; 42 class MediaConstraintsInterface;
43 43
44 class LocalAudioSource : public Notifier<AudioSourceInterface> { 44 class LocalAudioSource : public Notifier<AudioSourceInterface> {
45 public: 45 public:
46 // Creates an instance of LocalAudioSource. 46 // Creates an instance of LocalAudioSource.
47 static rtc::scoped_refptr<LocalAudioSource> Create( 47 static rtc::scoped_refptr<LocalAudioSource> Create(
48 const PeerConnectionFactoryInterface::Options& options, 48 const PeerConnectionFactoryInterface::Options& options,
49 const MediaConstraintsInterface* constraints); 49 const MediaConstraintsInterface* constraints);
50 50
51 virtual SourceState state() const { return source_state_; } 51 SourceState state() const override { return source_state_; }
52 bool remote() const override { return false; }
53
52 virtual const cricket::AudioOptions& options() const { return options_; } 54 virtual const cricket::AudioOptions& options() const { return options_; }
53 55
56 void AddSink(AudioTrackSinkInterface* sink) override {}
57 void RemoveSink(AudioTrackSinkInterface* sink) override {}
58
54 protected: 59 protected:
55 LocalAudioSource() 60 LocalAudioSource() : source_state_(kInitializing) {}
56 : source_state_(kInitializing) { 61 ~LocalAudioSource() override {}
57 }
58
59 ~LocalAudioSource() {
60 }
61 62
62 private: 63 private:
63 void Initialize(const PeerConnectionFactoryInterface::Options& options, 64 void Initialize(const PeerConnectionFactoryInterface::Options& options,
64 const MediaConstraintsInterface* constraints); 65 const MediaConstraintsInterface* constraints);
65 66
66 cricket::AudioOptions options_; 67 cricket::AudioOptions options_;
67 SourceState source_state_; 68 SourceState source_state_;
68 }; 69 };
69 70
70 } // namespace webrtc 71 } // namespace webrtc
71 72
72 #endif // TALK_APP_WEBRTC_LOCALAUDIOSOURCE_H_ 73 #endif // TALK_APP_WEBRTC_LOCALAUDIOSOURCE_H_
OLDNEW
« no previous file with comments | « talk/app/webrtc/audiotrack.cc ('k') | talk/app/webrtc/mediastream_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698