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

Side by Side Diff: webrtc/media/base/fakemediaengine.h

Issue 1715883002: Remove DeviceManager and DeviceInfo. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: rebase Created 4 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
« no previous file with comments | « webrtc/examples/peerconnection/client/conductor.cc ('k') | webrtc/media/base/mediaengine.h » ('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 * Copyright (c) 2004 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2004 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 732 matching lines...) Expand 10 before | Expand all | Expand 10 after
743 FakeVideoMediaChannel* GetChannel(size_t index) { 743 FakeVideoMediaChannel* GetChannel(size_t index) {
744 return (channels_.size() > index) ? channels_[index] : NULL; 744 return (channels_.size() > index) ? channels_[index] : NULL;
745 } 745 }
746 void UnregisterChannel(VideoMediaChannel* channel) { 746 void UnregisterChannel(VideoMediaChannel* channel) {
747 channels_.erase(std::find(channels_.begin(), channels_.end(), channel)); 747 channels_.erase(std::find(channels_.begin(), channels_.end(), channel));
748 } 748 }
749 749
750 const std::vector<VideoCodec>& codecs() const { return codecs_; } 750 const std::vector<VideoCodec>& codecs() const { return codecs_; }
751 void SetCodecs(const std::vector<VideoCodec> codecs) { codecs_ = codecs; } 751 void SetCodecs(const std::vector<VideoCodec> codecs) { codecs_ = codecs; }
752 752
753 bool SetCaptureDevice(const Device* device) {
754 in_device_ = (device) ? device->name : "";
755 options_changed_ = true;
756 return true;
757 }
758 bool SetCapture(bool capture) { 753 bool SetCapture(bool capture) {
759 capture_ = capture; 754 capture_ = capture;
760 return true; 755 return true;
761 } 756 }
762 757
763 private: 758 private:
764 std::vector<FakeVideoMediaChannel*> channels_; 759 std::vector<FakeVideoMediaChannel*> channels_;
765 std::vector<VideoCodec> codecs_; 760 std::vector<VideoCodec> codecs_;
766 std::string in_device_;
767 bool capture_; 761 bool capture_;
768 VideoOptions options_; 762 VideoOptions options_;
769 763
770 friend class FakeMediaEngine; 764 friend class FakeMediaEngine;
771 }; 765 };
772 766
773 class FakeMediaEngine : 767 class FakeMediaEngine :
774 public CompositeMediaEngine<FakeVoiceEngine, FakeVideoEngine> { 768 public CompositeMediaEngine<FakeVoiceEngine, FakeVideoEngine> {
775 public: 769 public:
776 FakeMediaEngine() {} 770 FakeMediaEngine() {}
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
869 863
870 private: 864 private:
871 std::vector<FakeDataMediaChannel*> channels_; 865 std::vector<FakeDataMediaChannel*> channels_;
872 std::vector<DataCodec> data_codecs_; 866 std::vector<DataCodec> data_codecs_;
873 DataChannelType last_channel_type_; 867 DataChannelType last_channel_type_;
874 }; 868 };
875 869
876 } // namespace cricket 870 } // namespace cricket
877 871
878 #endif // WEBRTC_MEDIA_BASE_FAKEMEDIAENGINE_H_ 872 #endif // WEBRTC_MEDIA_BASE_FAKEMEDIAENGINE_H_
OLDNEW
« no previous file with comments | « webrtc/examples/peerconnection/client/conductor.cc ('k') | webrtc/media/base/mediaengine.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698