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

Side by Side Diff: cc/output/render_surface_filters.h

Issue 317663005: Scale the ALPHA_THRESHOLD filter's region based on the device scale factor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Use SkMatrix when creating AlphaFilter Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 5
6 #ifndef CC_OUTPUT_RENDER_SURFACE_FILTERS_H_ 6 #ifndef CC_OUTPUT_RENDER_SURFACE_FILTERS_H_
7 #define CC_OUTPUT_RENDER_SURFACE_FILTERS_H_ 7 #define CC_OUTPUT_RENDER_SURFACE_FILTERS_H_
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "cc/base/cc_export.h" 10 #include "cc/base/cc_export.h"
11 #include "skia/ext/refptr.h" 11 #include "skia/ext/refptr.h"
12 12
13 class GrContext; 13 class GrContext;
14 class SkBitmap; 14 class SkBitmap;
15 class SkImageFilter; 15 class SkImageFilter;
16 16
17 namespace gfx { 17 namespace gfx {
18 class SizeF; 18 class SizeF;
19 class Vector2dF;
19 } 20 }
20 21
21 namespace cc { 22 namespace cc {
22 23
23 class FilterOperations; 24 class FilterOperations;
24 25
25 class CC_EXPORT RenderSurfaceFilters { 26 class CC_EXPORT RenderSurfaceFilters {
26 public: 27 public:
27 static SkBitmap Apply(const FilterOperations& filters, 28 static SkBitmap Apply(const FilterOperations& filters,
28 unsigned texture_id, 29 unsigned texture_id,
29 const gfx::SizeF& size, 30 const gfx::SizeF& size,
30 GrContext* gr_context); 31 GrContext* gr_context);
31 static FilterOperations Optimize(const FilterOperations& filters); 32 static FilterOperations Optimize(const FilterOperations& filters);
32 33
33 static skia::RefPtr<SkImageFilter> BuildImageFilter( 34 static skia::RefPtr<SkImageFilter> BuildImageFilter(
34 const FilterOperations& filters, 35 const FilterOperations& filters,
36 const gfx::Vector2dF& scale,
35 const gfx::SizeF& size); 37 const gfx::SizeF& size);
36 38
37 private: 39 private:
38 DISALLOW_IMPLICIT_CONSTRUCTORS(RenderSurfaceFilters); 40 DISALLOW_IMPLICIT_CONSTRUCTORS(RenderSurfaceFilters);
39 }; 41 };
40 42
41 } // namespace cc 43 } // namespace cc
42 44
43 #endif // CC_OUTPUT_RENDER_SURFACE_FILTERS_H_ 45 #endif // CC_OUTPUT_RENDER_SURFACE_FILTERS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698