OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_MEDIA_WEBMEDIAPLAYER_PROXY_H_ | 5 #ifndef WEBKIT_MEDIA_WEBMEDIAPLAYER_PROXY_H_ |
6 #define WEBKIT_MEDIA_WEBMEDIAPLAYER_PROXY_H_ | 6 #define WEBKIT_MEDIA_WEBMEDIAPLAYER_PROXY_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
68 void Paint(SkCanvas* canvas, const gfx::Rect& dest_rect, uint8_t alpha); | 68 void Paint(SkCanvas* canvas, const gfx::Rect& dest_rect, uint8_t alpha); |
69 void Detach(); | 69 void Detach(); |
70 void GetCurrentFrame(scoped_refptr<media::VideoFrame>* frame_out); | 70 void GetCurrentFrame(scoped_refptr<media::VideoFrame>* frame_out); |
71 void PutCurrentFrame(scoped_refptr<media::VideoFrame> frame); | 71 void PutCurrentFrame(scoped_refptr<media::VideoFrame> frame); |
72 bool HasSingleOrigin(); | 72 bool HasSingleOrigin(); |
73 bool DidPassCORSAccessCheck() const; | 73 bool DidPassCORSAccessCheck() const; |
74 | 74 |
75 void AbortDataSource(); | 75 void AbortDataSource(); |
76 | 76 |
77 // Methods for Pipeline -> WebMediaPlayerImpl communication. | 77 // Methods for Pipeline -> WebMediaPlayerImpl communication. |
78 void PipelineInitializationCallback(media::PipelineStatus status); | |
79 void PipelineSeekCallback(media::PipelineStatus status); | 78 void PipelineSeekCallback(media::PipelineStatus status); |
80 void PipelineEndedCallback(media::PipelineStatus status); | 79 void PipelineEndedCallback(media::PipelineStatus status); |
81 void PipelineErrorCallback(media::PipelineStatus error); | 80 void PipelineErrorCallback(media::PipelineStatus error); |
81 void PipelineReadyStateCallback(media::Pipeline::ReadyState readyState); | |
scherkus (not reviewing)
2012/08/15 23:43:16
unix_hacker
acolwell GONE FROM CHROMIUM
2012/08/16 00:54:18
Done.
| |
82 | 82 |
83 // ChunkDemuxerClient implementation. | 83 // ChunkDemuxerClient implementation. |
84 virtual void DemuxerOpened(media::ChunkDemuxer* demuxer) OVERRIDE; | 84 virtual void DemuxerOpened(media::ChunkDemuxer* demuxer) OVERRIDE; |
85 virtual void DemuxerClosed() OVERRIDE; | 85 virtual void DemuxerClosed() OVERRIDE; |
86 virtual void DemuxerNeedKey(scoped_array<uint8> init_data, | 86 virtual void DemuxerNeedKey(scoped_array<uint8> init_data, |
87 int init_data_size) OVERRIDE; | 87 int init_data_size) OVERRIDE; |
88 | 88 |
89 // Methods for Demuxer communication. | 89 // Methods for Demuxer communication. |
90 void DemuxerStartWaitingForSeek(); | 90 void DemuxerStartWaitingForSeek(); |
91 void DemuxerCancelPendingSeek(); | 91 void DemuxerCancelPendingSeek(); |
(...skipping 25 matching lines...) Expand all Loading... | |
117 scoped_array<uint8> init_data, | 117 scoped_array<uint8> init_data, |
118 int init_data_size) OVERRIDE; | 118 int init_data_size) OVERRIDE; |
119 | 119 |
120 private: | 120 private: |
121 friend class base::RefCountedThreadSafe<WebMediaPlayerProxy>; | 121 friend class base::RefCountedThreadSafe<WebMediaPlayerProxy>; |
122 virtual ~WebMediaPlayerProxy(); | 122 virtual ~WebMediaPlayerProxy(); |
123 | 123 |
124 // Invoke |webmediaplayer_| to perform a repaint. | 124 // Invoke |webmediaplayer_| to perform a repaint. |
125 void RepaintTask(); | 125 void RepaintTask(); |
126 | 126 |
127 // Notify |webmediaplayer_| that initialization has finished. | |
128 void PipelineInitializationTask(media::PipelineStatus status); | |
129 | |
130 // Notify |webmediaplayer_| that a seek has finished. | 127 // Notify |webmediaplayer_| that a seek has finished. |
131 void PipelineSeekTask(media::PipelineStatus status); | 128 void PipelineSeekTask(media::PipelineStatus status); |
132 | 129 |
133 // Notify |webmediaplayer_| that the media has ended. | 130 // Notify |webmediaplayer_| that the media has ended. |
134 void PipelineEndedTask(media::PipelineStatus status); | 131 void PipelineEndedTask(media::PipelineStatus status); |
135 | 132 |
136 // Notify |webmediaplayer_| that a pipeline error has occurred during | 133 // Notify |webmediaplayer_| that a pipeline error has occurred during |
137 // playback. | 134 // playback. |
138 void PipelineErrorTask(media::PipelineStatus error); | 135 void PipelineErrorTask(media::PipelineStatus error); |
139 | 136 |
137 // Notify |webmediaplayer_| of readyState changes. | |
scherkus (not reviewing)
2012/08/15 23:43:16
unix_hacker
acolwell GONE FROM CHROMIUM
2012/08/16 00:54:18
Done.
| |
138 void PipelineReadyStateTask(media::Pipeline::ReadyState readyState); | |
scherkus (not reviewing)
2012/08/15 23:43:16
unix_hacker
acolwell GONE FROM CHROMIUM
2012/08/16 00:54:18
Done.
| |
139 | |
140 // Inform |webmediaplayer_| whether the video content is opaque. | 140 // Inform |webmediaplayer_| whether the video content is opaque. |
141 void SetOpaqueTask(bool opaque); | 141 void SetOpaqueTask(bool opaque); |
142 | 142 |
143 void DemuxerOpenedTask(const scoped_refptr<media::ChunkDemuxer>& demuxer); | 143 void DemuxerOpenedTask(const scoped_refptr<media::ChunkDemuxer>& demuxer); |
144 void DemuxerClosedTask(); | 144 void DemuxerClosedTask(); |
145 | 145 |
146 // Notify |webmediaplayer_| that a key has been added. | 146 // Notify |webmediaplayer_| that a key has been added. |
147 void KeyAddedTask(const std::string& key_system, | 147 void KeyAddedTask(const std::string& key_system, |
148 const std::string& session_id); | 148 const std::string& session_id); |
149 | 149 |
(...skipping 28 matching lines...) Expand all Loading... | |
178 int outstanding_repaints_; | 178 int outstanding_repaints_; |
179 | 179 |
180 scoped_refptr<media::ChunkDemuxer> chunk_demuxer_; | 180 scoped_refptr<media::ChunkDemuxer> chunk_demuxer_; |
181 | 181 |
182 DISALLOW_IMPLICIT_CONSTRUCTORS(WebMediaPlayerProxy); | 182 DISALLOW_IMPLICIT_CONSTRUCTORS(WebMediaPlayerProxy); |
183 }; | 183 }; |
184 | 184 |
185 } // namespace webkit_media | 185 } // namespace webkit_media |
186 | 186 |
187 #endif // WEBKIT_MEDIA_WEBMEDIAPLAYER_PROXY_H_ | 187 #endif // WEBKIT_MEDIA_WEBMEDIAPLAYER_PROXY_H_ |
OLD | NEW |