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 WEBKIT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 5 #ifndef WEBKIT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
6 #define WEBKIT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 6 #define WEBKIT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 void Seek(base::TimeDelta time); | 63 void Seek(base::TimeDelta time); |
64 | 64 |
65 void CancelPendingSeek(); | 65 void CancelPendingSeek(); |
66 | 66 |
67 void NotifyDemuxerReady(const std::string& key_system); | 67 void NotifyDemuxerReady(const std::string& key_system); |
68 | 68 |
69 // Called when DemuxerStreamPlayer needs to read data from ChunkDemuxer. | 69 // Called when DemuxerStreamPlayer needs to read data from ChunkDemuxer. |
70 // If it's the first request after the seek, |seek_done| will be true. | 70 // If it's the first request after the seek, |seek_done| will be true. |
71 void OnReadFromDemuxer(media::DemuxerStream::Type type, bool seek_done); | 71 void OnReadFromDemuxer(media::DemuxerStream::Type type, bool seek_done); |
72 | 72 |
| 73 // Called when the player needs the new config data from ChunkDemuxer. |
| 74 void OnMediaConfigRequest(); |
| 75 |
73 // Called by the Destroyer to destroy an instance of this object. | 76 // Called by the Destroyer to destroy an instance of this object. |
74 void Destroy(); | 77 void Destroy(); |
75 | 78 |
76 private: | 79 private: |
77 // This is private to enforce use of the Destroyer. | 80 // This is private to enforce use of the Destroyer. |
78 virtual ~MediaSourceDelegate(); | 81 virtual ~MediaSourceDelegate(); |
79 | 82 |
80 // Methods inherited from DemuxerHost. | 83 // Methods inherited from DemuxerHost. |
81 virtual void SetTotalBytes(int64 total_bytes) OVERRIDE; | 84 virtual void SetTotalBytes(int64 total_bytes) OVERRIDE; |
82 virtual void AddBufferedByteRange(int64 start, int64 end) OVERRIDE; | 85 virtual void AddBufferedByteRange(int64 start, int64 end) OVERRIDE; |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
140 scoped_ptr<media::MediaPlayerHostMsg_ReadFromDemuxerAck_Params> audio_params_; | 143 scoped_ptr<media::MediaPlayerHostMsg_ReadFromDemuxerAck_Params> audio_params_; |
141 scoped_ptr<media::MediaPlayerHostMsg_ReadFromDemuxerAck_Params> video_params_; | 144 scoped_ptr<media::MediaPlayerHostMsg_ReadFromDemuxerAck_Params> video_params_; |
142 | 145 |
143 bool seeking_; | 146 bool seeking_; |
144 | 147 |
145 DISALLOW_COPY_AND_ASSIGN(MediaSourceDelegate); | 148 DISALLOW_COPY_AND_ASSIGN(MediaSourceDelegate); |
146 }; | 149 }; |
147 | 150 |
148 } // namespace webkit_media | 151 } // namespace webkit_media |
149 #endif // WEBKIT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ | 152 #endif // WEBKIT_RENDERER_MEDIA_ANDROID_MEDIA_SOURCE_DELEGATE_H_ |
OLD | NEW |