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

Side by Side Diff: ui/gfx/skia_util.h

Issue 265713007: views: Update event-related API to use PointF/RectF instead of Point/Rect. Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 (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 UI_GFX_SKIA_UTIL_H_ 5 #ifndef UI_GFX_SKIA_UTIL_H_
6 #define UI_GFX_SKIA_UTIL_H_ 6 #define UI_GFX_SKIA_UTIL_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 10 matching lines...) Expand all
21 21
22 class ImageSkiaRep; 22 class ImageSkiaRep;
23 class Rect; 23 class Rect;
24 class RectF; 24 class RectF;
25 class ShadowValue; 25 class ShadowValue;
26 class Transform; 26 class Transform;
27 27
28 // Convert between Skia and gfx rect types. 28 // Convert between Skia and gfx rect types.
29 GFX_EXPORT SkRect RectToSkRect(const Rect& rect); 29 GFX_EXPORT SkRect RectToSkRect(const Rect& rect);
30 GFX_EXPORT SkIRect RectToSkIRect(const Rect& rect); 30 GFX_EXPORT SkIRect RectToSkIRect(const Rect& rect);
31 GFX_EXPORT SkIRect RectToSkIRect(const RectF& rect);
31 GFX_EXPORT Rect SkIRectToRect(const SkIRect& rect); 32 GFX_EXPORT Rect SkIRectToRect(const SkIRect& rect);
32 GFX_EXPORT SkRect RectFToSkRect(const RectF& rect); 33 GFX_EXPORT SkRect RectFToSkRect(const RectF& rect);
33 GFX_EXPORT RectF SkRectToRectF(const SkRect& rect); 34 GFX_EXPORT RectF SkRectToRectF(const SkRect& rect);
34 35
35 GFX_EXPORT void TransformToFlattenedSkMatrix(const gfx::Transform& transform, 36 GFX_EXPORT void TransformToFlattenedSkMatrix(const gfx::Transform& transform,
36 SkMatrix* flattened); 37 SkMatrix* flattened);
37 38
38 // Creates a bitmap shader for the image rep with the image rep's scale factor. 39 // Creates a bitmap shader for the image rep with the image rep's scale factor.
39 // Sets the created shader's local matrix such that it displays the image rep at 40 // Sets the created shader's local matrix such that it displays the image rep at
40 // the correct scale factor. 41 // the correct scale factor.
(...skipping 24 matching lines...) Expand all
65 const SkBitmap& bitmap2); 66 const SkBitmap& bitmap2);
66 67
67 // Converts Skia ARGB format pixels in |skia| to RGBA. 68 // Converts Skia ARGB format pixels in |skia| to RGBA.
68 GFX_EXPORT void ConvertSkiaToRGBA(const unsigned char* skia, 69 GFX_EXPORT void ConvertSkiaToRGBA(const unsigned char* skia,
69 int pixel_width, 70 int pixel_width,
70 unsigned char* rgba); 71 unsigned char* rgba);
71 72
72 } // namespace gfx 73 } // namespace gfx
73 74
74 #endif // UI_GFX_SKIA_UTIL_H_ 75 #endif // UI_GFX_SKIA_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698