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 CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ |
6 #define CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ | 6 #define CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 const std::string& session_id); | 224 const std::string& session_id); |
225 | 225 |
226 // Gets the duration value reported by the pipeline. | 226 // Gets the duration value reported by the pipeline. |
227 double GetPipelineDuration() const; | 227 double GetPipelineDuration() const; |
228 | 228 |
229 // Callbacks from |pipeline_| that are forwarded to |client_|. | 229 // Callbacks from |pipeline_| that are forwarded to |client_|. |
230 void OnDurationChanged(); | 230 void OnDurationChanged(); |
231 void OnNaturalSizeChanged(gfx::Size size); | 231 void OnNaturalSizeChanged(gfx::Size size); |
232 void OnOpacityChanged(bool opaque); | 232 void OnOpacityChanged(bool opaque); |
233 | 233 |
234 // Called by VideoRendererImpl on its internal thread with the new frame to be | |
235 // painted. | |
236 void FrameReady(const scoped_refptr<media::VideoFrame>& frame); | |
237 | |
238 // Requests that this object notifies when a decryptor is ready through the | 234 // Requests that this object notifies when a decryptor is ready through the |
239 // |decryptor_ready_cb| provided. | 235 // |decryptor_ready_cb| provided. |
240 // If |decryptor_ready_cb| is null, the existing callback will be fired with | 236 // If |decryptor_ready_cb| is null, the existing callback will be fired with |
241 // NULL immediately and reset. | 237 // NULL immediately and reset. |
242 void SetDecryptorReadyCB(const media::DecryptorReadyCB& decryptor_ready_cb); | 238 void SetDecryptorReadyCB(const media::DecryptorReadyCB& decryptor_ready_cb); |
243 | 239 |
244 blink::WebLocalFrame* frame_; | 240 blink::WebLocalFrame* frame_; |
245 | 241 |
246 // TODO(hclam): get rid of these members and read from the pipeline directly. | 242 // TODO(hclam): get rid of these members and read from the pipeline directly. |
247 blink::WebMediaPlayer::NetworkState network_state_; | 243 blink::WebMediaPlayer::NetworkState network_state_; |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
351 WebContentDecryptionModuleImpl* web_cdm_; | 347 WebContentDecryptionModuleImpl* web_cdm_; |
352 | 348 |
353 media::DecryptorReadyCB decryptor_ready_cb_; | 349 media::DecryptorReadyCB decryptor_ready_cb_; |
354 | 350 |
355 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl); | 351 DISALLOW_COPY_AND_ASSIGN(WebMediaPlayerImpl); |
356 }; | 352 }; |
357 | 353 |
358 } // namespace content | 354 } // namespace content |
359 | 355 |
360 #endif // CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ | 356 #endif // CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_IMPL_H_ |
OLD | NEW |