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

Side by Side Diff: chrome/renderer/media/cast_session_delegate.h

Issue 2113783002: Refactoring: Merge VideoSenderConfig and AudioSenderConfig. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed mek's comment. Created 4 years, 5 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 | « chrome/renderer/media/cast_session.cc ('k') | chrome/renderer/media/cast_session_delegate.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 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 CHROME_RENDERER_MEDIA_CAST_SESSION_DELEGATE_H_ 5 #ifndef CHROME_RENDERER_MEDIA_CAST_SESSION_DELEGATE_H_
6 #define CHROME_RENDERER_MEDIA_CAST_SESSION_DELEGATE_H_ 6 #define CHROME_RENDERER_MEDIA_CAST_SESSION_DELEGATE_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 #include <vector> 10 #include <vector>
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 const net::IPEndPoint& remote_endpoint, 97 const net::IPEndPoint& remote_endpoint,
98 std::unique_ptr<base::DictionaryValue> options, 98 std::unique_ptr<base::DictionaryValue> options,
99 const ErrorCallback& error_callback); 99 const ErrorCallback& error_callback);
100 100
101 // After calling StartAudio() or StartVideo() encoding of that media will 101 // After calling StartAudio() or StartVideo() encoding of that media will
102 // begin as soon as data is delivered to its sink, if the second method is 102 // begin as soon as data is delivered to its sink, if the second method is
103 // called the first media will be restarted. It is strongly recommended not to 103 // called the first media will be restarted. It is strongly recommended not to
104 // deliver any data between calling the two methods. 104 // deliver any data between calling the two methods.
105 // It's OK to call only one of the two methods. 105 // It's OK to call only one of the two methods.
106 // StartUDP must be called before these methods. 106 // StartUDP must be called before these methods.
107 void StartAudio(const media::cast::AudioSenderConfig& config, 107 void StartAudio(const media::cast::FrameSenderConfig& config,
108 const AudioFrameInputAvailableCallback& callback, 108 const AudioFrameInputAvailableCallback& callback,
109 const ErrorCallback& error_callback); 109 const ErrorCallback& error_callback);
110 110
111 void StartVideo(const media::cast::VideoSenderConfig& config, 111 void StartVideo(
112 const VideoFrameInputAvailableCallback& callback, 112 const media::cast::FrameSenderConfig& config,
113 const ErrorCallback& error_callback, 113 const VideoFrameInputAvailableCallback& callback,
114 const media::cast::CreateVideoEncodeAcceleratorCallback& 114 const ErrorCallback& error_callback,
115 create_vea_cb, 115 const media::cast::CreateVideoEncodeAcceleratorCallback& create_vea_cb,
116 const media::cast::CreateVideoEncodeMemoryCallback& 116 const media::cast::CreateVideoEncodeMemoryCallback&
117 create_video_encode_mem_cb); 117 create_video_encode_mem_cb);
118 118
119 void ToggleLogging(bool is_audio, bool enable); 119 void ToggleLogging(bool is_audio, bool enable);
120 void GetEventLogsAndReset(bool is_audio, 120 void GetEventLogsAndReset(bool is_audio,
121 const std::string& extra_data, const EventLogsCallback& callback); 121 const std::string& extra_data, const EventLogsCallback& callback);
122 void GetStatsAndReset(bool is_audio, const StatsCallback& callback); 122 void GetStatsAndReset(bool is_audio, const StatsCallback& callback);
123 123
124 protected: 124 protected:
125 // Called to report back operational status changes. The first time this is 125 // Called to report back operational status changes. The first time this is
126 // called with STATUS_INITIALIZED will result in running the "frame input 126 // called with STATUS_INITIALIZED will result in running the "frame input
127 // available" callback, to indicate the session is ready to accept incoming 127 // available" callback, to indicate the session is ready to accept incoming
(...skipping 15 matching lines...) Expand all
143 VideoFrameInputAvailableCallback video_frame_input_available_callback_; 143 VideoFrameInputAvailableCallback video_frame_input_available_callback_;
144 144
145 std::unique_ptr<media::cast::RawEventSubscriberBundle> event_subscribers_; 145 std::unique_ptr<media::cast::RawEventSubscriberBundle> event_subscribers_;
146 146
147 base::WeakPtrFactory<CastSessionDelegate> weak_factory_; 147 base::WeakPtrFactory<CastSessionDelegate> weak_factory_;
148 148
149 DISALLOW_COPY_AND_ASSIGN(CastSessionDelegate); 149 DISALLOW_COPY_AND_ASSIGN(CastSessionDelegate);
150 }; 150 };
151 151
152 #endif // CHROME_RENDERER_MEDIA_CAST_SESSION_DELEGATE_H_ 152 #endif // CHROME_RENDERER_MEDIA_CAST_SESSION_DELEGATE_H_
OLDNEW
« no previous file with comments | « chrome/renderer/media/cast_session.cc ('k') | chrome/renderer/media/cast_session_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698