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

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

Issue 2799093006: Remove base::BinaryValue (Closed)
Patch Set: Rebase Created 3 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
« no previous file with comments | « chrome/renderer/media/cast_rtp_stream.cc ('k') | chrome/renderer/media/cast_session_delegate.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 // 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_H_ 5 #ifndef CHROME_RENDERER_MEDIA_CAST_SESSION_H_
6 #define CHROME_RENDERER_MEDIA_CAST_SESSION_H_ 6 #define CHROME_RENDERER_MEDIA_CAST_SESSION_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/callback.h" 11 #include "base/callback.h"
12 #include "base/macros.h" 12 #include "base/macros.h"
13 #include "base/memory/ref_counted.h" 13 #include "base/memory/ref_counted.h"
14 #include "media/cast/cast_config.h" 14 #include "media/cast/cast_config.h"
15 #include "net/base/ip_endpoint.h" 15 #include "net/base/ip_endpoint.h"
16 16
17 namespace base { 17 namespace base {
18 class DictionaryValue; 18 class DictionaryValue;
19 class SingleThreadTaskRunner; 19 class SingleThreadTaskRunner;
20 class Value; 20 class Value;
21 using BinaryValue = Value;
22 } // namespace base 21 } // namespace base
23 22
24 namespace media { 23 namespace media {
25 namespace cast { 24 namespace cast {
26 class AudioFrameInput; 25 class AudioFrameInput;
27 class VideoFrameInput; 26 class VideoFrameInput;
28 } // namespace cast 27 } // namespace cast
29 } // namespace media 28 } // namespace media
30 29
31 class CastSessionDelegate; 30 class CastSessionDelegate;
32 31
33 // This class represents a Cast session and allows the session to be 32 // This class represents a Cast session and allows the session to be
34 // configured on the main thread. Actual work is forwarded to 33 // configured on the main thread. Actual work is forwarded to
35 // CastSessionDelegate on the IO thread. 34 // CastSessionDelegate on the IO thread.
36 class CastSession : public base::RefCounted<CastSession> { 35 class CastSession : public base::RefCounted<CastSession> {
37 public: 36 public:
38 using AudioFrameInputAvailableCallback = 37 using AudioFrameInputAvailableCallback =
39 base::Callback<void(const scoped_refptr<media::cast::AudioFrameInput>&)>; 38 base::Callback<void(const scoped_refptr<media::cast::AudioFrameInput>&)>;
40 using VideoFrameInputAvailableCallback = 39 using VideoFrameInputAvailableCallback =
41 base::Callback<void(const scoped_refptr<media::cast::VideoFrameInput>&)>; 40 base::Callback<void(const scoped_refptr<media::cast::VideoFrameInput>&)>;
42 using SendPacketCallback = base::Callback<void(const std::vector<char>&)>; 41 using SendPacketCallback = base::Callback<void(const std::vector<char>&)>;
43 using EventLogsCallback = 42 using EventLogsCallback = base::Callback<void(std::unique_ptr<base::Value>)>;
44 base::Callback<void(std::unique_ptr<base::BinaryValue>)>;
45 using StatsCallback = 43 using StatsCallback =
46 base::Callback<void(std::unique_ptr<base::DictionaryValue>)>; 44 base::Callback<void(std::unique_ptr<base::DictionaryValue>)>;
47 using ErrorCallback = base::Callback<void(const std::string&)>; 45 using ErrorCallback = base::Callback<void(const std::string&)>;
48 46
49 CastSession(); 47 CastSession();
50 48
51 // Start encoding of audio and video using the provided configuration. 49 // Start encoding of audio and video using the provided configuration.
52 // 50 //
53 // When Cast sender is started and ready to be used 51 // When Cast sender is started and ready to be used
54 // media::cast::FrameInput will be given through |callback|. 52 // media::cast::FrameInput will be given through |callback|.
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 // because it is owned by this object. 101 // because it is owned by this object.
104 std::unique_ptr<CastSessionDelegate> delegate_; 102 std::unique_ptr<CastSessionDelegate> delegate_;
105 103
106 // Proxy to the IO task runner. 104 // Proxy to the IO task runner.
107 const scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_; 105 const scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_;
108 106
109 DISALLOW_COPY_AND_ASSIGN(CastSession); 107 DISALLOW_COPY_AND_ASSIGN(CastSession);
110 }; 108 };
111 109
112 #endif // CHROME_RENDERER_MEDIA_CAST_SESSION_H_ 110 #endif // CHROME_RENDERER_MEDIA_CAST_SESSION_H_
OLDNEW
« no previous file with comments | « chrome/renderer/media/cast_rtp_stream.cc ('k') | chrome/renderer/media/cast_session_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698