Chromium Code Reviews| 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 MEDIA_RENDERERS_SKCANVAS_VIDEO_RENDERER_H_ | 5 #ifndef MEDIA_RENDERERS_SKCANVAS_VIDEO_RENDERER_H_ |
| 6 #define MEDIA_RENDERERS_SKCANVAS_VIDEO_RENDERER_H_ | 6 #define MEDIA_RENDERERS_SKCANVAS_VIDEO_RENDERER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 27 matching lines...) Expand all Loading... | |
| 38 | 38 |
| 39 // Paints |video_frame| on |canvas|, scaling and rotating the result to fit | 39 // Paints |video_frame| on |canvas|, scaling and rotating the result to fit |
| 40 // dimensions specified by |dest_rect|. | 40 // dimensions specified by |dest_rect|. |
| 41 // If the format of |video_frame| is PIXEL_FORMAT_NATIVE_TEXTURE, |context_3d| | 41 // If the format of |video_frame| is PIXEL_FORMAT_NATIVE_TEXTURE, |context_3d| |
| 42 // must be provided. | 42 // must be provided. |
| 43 // | 43 // |
| 44 // Black will be painted on |canvas| if |video_frame| is null. | 44 // Black will be painted on |canvas| if |video_frame| is null. |
| 45 void Paint(const scoped_refptr<VideoFrame>& video_frame, | 45 void Paint(const scoped_refptr<VideoFrame>& video_frame, |
| 46 cc::PaintCanvas* canvas, | 46 cc::PaintCanvas* canvas, |
| 47 const gfx::RectF& dest_rect, | 47 const gfx::RectF& dest_rect, |
| 48 SkPaint& paint, | 48 SkPaint& flags, |
|
watk
2017/02/13 19:38:09
Should this be changed to PaintFlags?
enne (OOO)
2017/02/13 19:43:30
Oops, sorry. /o\
| |
| 49 VideoRotation video_rotation, | 49 VideoRotation video_rotation, |
| 50 const Context3D& context_3d); | 50 const Context3D& context_3d); |
| 51 | 51 |
| 52 // Copy |video_frame| on |canvas|. | 52 // Copy |video_frame| on |canvas|. |
| 53 // If the format of |video_frame| is PIXEL_FORMAT_NATIVE_TEXTURE, |context_3d| | 53 // If the format of |video_frame| is PIXEL_FORMAT_NATIVE_TEXTURE, |context_3d| |
| 54 // must be provided. | 54 // must be provided. |
| 55 void Copy(const scoped_refptr<VideoFrame>& video_frame, | 55 void Copy(const scoped_refptr<VideoFrame>& video_frame, |
| 56 cc::PaintCanvas* canvas, | 56 cc::PaintCanvas* canvas, |
| 57 const Context3D& context_3d); | 57 const Context3D& context_3d); |
| 58 | 58 |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 153 | 153 |
| 154 // Used for unit test. | 154 // Used for unit test. |
| 155 SkISize last_image_dimensions_for_testing_; | 155 SkISize last_image_dimensions_for_testing_; |
| 156 | 156 |
| 157 DISALLOW_COPY_AND_ASSIGN(SkCanvasVideoRenderer); | 157 DISALLOW_COPY_AND_ASSIGN(SkCanvasVideoRenderer); |
| 158 }; | 158 }; |
| 159 | 159 |
| 160 } // namespace media | 160 } // namespace media |
| 161 | 161 |
| 162 #endif // MEDIA_RENDERERS_SKCANVAS_VIDEO_RENDERER_H_ | 162 #endif // MEDIA_RENDERERS_SKCANVAS_VIDEO_RENDERER_H_ |
| OLD | NEW |