diff options
author | hbono@chromium.org <hbono@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-28 05:05:53 +0000 |
---|---|---|
committer | hbono@chromium.org <hbono@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-04-28 05:05:53 +0000 |
commit | 7b441021461106603e4b7769305b8fce7db17294 (patch) | |
tree | 4b182c22eb74adcdd4ede2315062b991946b1005 /skia/ext/image_operations.h | |
parent | a0669d0100750d2629de8fb552ec39512a752a69 (diff) | |
download | chromium_src-7b441021461106603e4b7769305b8fce7db17294.zip chromium_src-7b441021461106603e4b7769305b8fce7db17294.tar.gz chromium_src-7b441021461106603e4b7769305b8fce7db17294.tar.bz2 |
Reverting 14712 on behalf of glen.
TBR=glen
Review URL: http://codereview.chromium.org/100097
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14713 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'skia/ext/image_operations.h')
-rw-r--r-- | skia/ext/image_operations.h | 37 |
1 files changed, 1 insertions, 36 deletions
diff --git a/skia/ext/image_operations.h b/skia/ext/image_operations.h index 5c46b36..5188dba 100644 --- a/skia/ext/image_operations.h +++ b/skia/ext/image_operations.h @@ -7,7 +7,6 @@ #include "base/basictypes.h" #include "base/gfx/rect.h" -#include "SkColor.h" class SkBitmap; @@ -47,47 +46,13 @@ class ImageOperations { ResizeMethod method, int dest_width, int dest_height); + // Create a bitmap that is a blend of two others. The alpha argument // specifies the opacity of the second bitmap. The provided bitmaps must // use have the kARGB_8888_Config config and be of equal dimensions. static SkBitmap CreateBlendedBitmap(const SkBitmap& first, const SkBitmap& second, double alpha); - - // Create a bitmap that is the original bitmap masked out by the mask defined - // in the alpha bitmap. The images must use the kARGB_8888_Config config and - // be of equal dimensions. - static SkBitmap CreateMaskedBitmap(const SkBitmap& first, - const SkBitmap& alpha); - - // Blur a bitmap using an average-blur algorithm over the rectangle defined - // by |blur_amount|. The blur will wrap around image edges. - static SkBitmap CreateBlurredBitmap(const SkBitmap& bitmap, int blur_amount); - - // Shift a bitmap's HSL values. The shift values are in the range of 0-1, - // with the option to specify -1 for 'no change'. The shift values are - // defined as: - // hsl_shift[0] (hue): The absolute hue value for the image - 0 and 1 map - // to 0 and 360 on the hue color wheel (red). - // hsl_shift[1] (saturation): A saturation shift for the image, with the - // following key values: - // 0 = remove all color. - // 0.5 = leave unchanged. - // 1 = fully saturate the image. - // hsl_shift[2] (lightness): A lightness shift for the image, with the - // following key values: - // 0 = remove all lightness (make all pixels black). - // 0.5 = leave unchanged. - // 1 = full lightness (make all pixels white). - static SkBitmap CreateHSLShiftedBitmap(const SkBitmap& bitmap, - float hsl_shift[3]); - - // Create a bitmap that is cropped from another bitmap. This is special - // because it tiles the original bitmap, so your coordinates can extend - // outside the bounds of the original image. - static SkBitmap CreateTiledBitmap(const SkBitmap& bitmap, - int src_x, int src_y, - int dst_w, int dst_h); private: ImageOperations(); // Class for scoping only. }; |