| OLD | NEW |
| 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 BinaryValue; | 18 class BinaryValue; |
| 19 class DictionaryValue; | 19 class DictionaryValue; |
| 20 class SingleThreadTaskRunner; | 20 class SingleThreadTaskRunner; |
| 21 } // namespace base | 21 } // namespace base |
| 22 | 22 |
| 23 namespace media { | 23 namespace media { |
| 24 class VideoFrame; | |
| 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 namespace content { | |
| 32 class P2PSocketClient; | |
| 33 } // namespace content | |
| 34 | |
| 35 class CastSessionDelegate; | 30 class CastSessionDelegate; |
| 36 | 31 |
| 37 // 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 |
| 38 // configured on the main thread. Actual work is forwarded to | 33 // configured on the main thread. Actual work is forwarded to |
| 39 // CastSessionDelegate on the IO thread. | 34 // CastSessionDelegate on the IO thread. |
| 40 class CastSession : public base::RefCounted<CastSession> { | 35 class CastSession : public base::RefCounted<CastSession> { |
| 41 public: | 36 public: |
| 42 using AudioFrameInputAvailableCallback = | 37 using AudioFrameInputAvailableCallback = |
| 43 base::Callback<void(const scoped_refptr<media::cast::AudioFrameInput>&)>; | 38 base::Callback<void(const scoped_refptr<media::cast::AudioFrameInput>&)>; |
| 44 using VideoFrameInputAvailableCallback = | 39 using VideoFrameInputAvailableCallback = |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 // because it is owned by this object. | 102 // because it is owned by this object. |
| 108 std::unique_ptr<CastSessionDelegate> delegate_; | 103 std::unique_ptr<CastSessionDelegate> delegate_; |
| 109 | 104 |
| 110 // Proxy to the IO task runner. | 105 // Proxy to the IO task runner. |
| 111 const scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_; | 106 const scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_; |
| 112 | 107 |
| 113 DISALLOW_COPY_AND_ASSIGN(CastSession); | 108 DISALLOW_COPY_AND_ASSIGN(CastSession); |
| 114 }; | 109 }; |
| 115 | 110 |
| 116 #endif // CHROME_RENDERER_MEDIA_CAST_SESSION_H_ | 111 #endif // CHROME_RENDERER_MEDIA_CAST_SESSION_H_ |
| OLD | NEW |