| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_GLUE_MEDIA_WEB_VIDEO_RENDERER_H_ | 5 #ifndef WEBKIT_MEDIA_WEB_VIDEO_RENDERER_H_ |
| 6 #define WEBKIT_GLUE_MEDIA_WEB_VIDEO_RENDERER_H_ | 6 #define WEBKIT_MEDIA_WEB_VIDEO_RENDERER_H_ |
| 7 | 7 |
| 8 #include "media/base/video_frame.h" | 8 #include "media/base/video_frame.h" |
| 9 #include "media/filters/video_renderer_base.h" | 9 #include "media/filters/video_renderer_base.h" |
| 10 #include "ui/gfx/rect.h" | 10 #include "ui/gfx/rect.h" |
| 11 | 11 |
| 12 class SkCanvas; | 12 class SkCanvas; |
| 13 | 13 |
| 14 namespace webkit_glue { | 14 namespace webkit_media { |
| 15 | 15 |
| 16 class WebMediaPlayerProxy; | 16 class WebMediaPlayerProxy; |
| 17 | 17 |
| 18 // A specialized version of a VideoRenderer designed to be used inside WebKit. | 18 // A specialized version of a VideoRenderer designed to be used inside WebKit. |
| 19 class WebVideoRenderer : public media::VideoRendererBase { | 19 class WebVideoRenderer : public media::VideoRendererBase { |
| 20 public: | 20 public: |
| 21 WebVideoRenderer() : media::VideoRendererBase() {} | 21 WebVideoRenderer() : media::VideoRendererBase() {} |
| 22 virtual ~WebVideoRenderer() {} | 22 virtual ~WebVideoRenderer() {} |
| 23 | 23 |
| 24 // Saves the reference to WebMediaPlayerProxy. | 24 // Saves the reference to WebMediaPlayerProxy. |
| (...skipping 10 matching lines...) Expand all Loading... |
| 35 // Paint the current front frame on the |canvas| stretching it to fit the | 35 // Paint the current front frame on the |canvas| stretching it to fit the |
| 36 // |dest_rect|. | 36 // |dest_rect|. |
| 37 // | 37 // |
| 38 // Method called on the render thread. | 38 // Method called on the render thread. |
| 39 virtual void Paint(SkCanvas* canvas, const gfx::Rect& dest_rect) = 0; | 39 virtual void Paint(SkCanvas* canvas, const gfx::Rect& dest_rect) = 0; |
| 40 | 40 |
| 41 private: | 41 private: |
| 42 DISALLOW_COPY_AND_ASSIGN(WebVideoRenderer); | 42 DISALLOW_COPY_AND_ASSIGN(WebVideoRenderer); |
| 43 }; | 43 }; |
| 44 | 44 |
| 45 } // namespace webkit_glue | 45 } // namespace webkit_media |
| 46 | 46 |
| 47 #endif // WEBKIT_GLUE_MEDIA_WEB_VIDEO_RENDERER_H_ | 47 #endif // WEBKIT_MEDIA_WEB_VIDEO_RENDERER_H_ |
| OLD | NEW |