Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(12)

Side by Side Diff: media/renderers/skcanvas_video_renderer.h

Issue 2276033002: Pass SkPaint instead of its alpha and mode in WebMediaPlayer::paint (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: android should compile Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « media/blink/webmediaplayer_impl.cc ('k') | media/renderers/skcanvas_video_renderer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 29 matching lines...) Expand all
40 40
41 // Paints |video_frame| on |canvas|, scaling and rotating the result to fit 41 // Paints |video_frame| on |canvas|, scaling and rotating the result to fit
42 // dimensions specified by |dest_rect|. 42 // dimensions specified by |dest_rect|.
43 // If the format of |video_frame| is PIXEL_FORMAT_NATIVE_TEXTURE, |context_3d| 43 // If the format of |video_frame| is PIXEL_FORMAT_NATIVE_TEXTURE, |context_3d|
44 // must be provided. 44 // must be provided.
45 // 45 //
46 // Black will be painted on |canvas| if |video_frame| is null. 46 // Black will be painted on |canvas| if |video_frame| is null.
47 void Paint(const scoped_refptr<VideoFrame>& video_frame, 47 void Paint(const scoped_refptr<VideoFrame>& video_frame,
48 SkCanvas* canvas, 48 SkCanvas* canvas,
49 const gfx::RectF& dest_rect, 49 const gfx::RectF& dest_rect,
50 uint8_t alpha, 50 SkPaint& paint,
51 SkXfermode::Mode mode,
52 VideoRotation video_rotation, 51 VideoRotation video_rotation,
53 const Context3D& context_3d); 52 const Context3D& context_3d);
54 53
55 // Copy |video_frame| on |canvas|. 54 // Copy |video_frame| on |canvas|.
56 // If the format of |video_frame| is PIXEL_FORMAT_NATIVE_TEXTURE, |context_3d| 55 // If the format of |video_frame| is PIXEL_FORMAT_NATIVE_TEXTURE, |context_3d|
57 // must be provided. 56 // must be provided.
58 void Copy(const scoped_refptr<VideoFrame>& video_frame, 57 void Copy(const scoped_refptr<VideoFrame>& video_frame,
59 SkCanvas* canvas, 58 SkCanvas* canvas,
60 const Context3D& context_3d); 59 const Context3D& context_3d);
61 60
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 114
116 // Used for DCHECKs to ensure method calls executed in the correct thread. 115 // Used for DCHECKs to ensure method calls executed in the correct thread.
117 base::ThreadChecker thread_checker_; 116 base::ThreadChecker thread_checker_;
118 117
119 DISALLOW_COPY_AND_ASSIGN(SkCanvasVideoRenderer); 118 DISALLOW_COPY_AND_ASSIGN(SkCanvasVideoRenderer);
120 }; 119 };
121 120
122 } // namespace media 121 } // namespace media
123 122
124 #endif // MEDIA_RENDERERS_SKCANVAS_VIDEO_RENDERER_H_ 123 #endif // MEDIA_RENDERERS_SKCANVAS_VIDEO_RENDERER_H_
OLDNEW
« no previous file with comments | « media/blink/webmediaplayer_impl.cc ('k') | media/renderers/skcanvas_video_renderer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698