diff options
author | commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-04-11 17:15:40 +0000 |
---|---|---|
committer | commit-bot@chromium.org <commit-bot@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2014-04-11 17:15:40 +0000 |
commit | 28fcae2ec77eb16a79e155f8d788b20457f1c951 (patch) | |
tree | a79e8015d2dd76f5a2677ffcc19d2aede4c6b8bb /include | |
parent | 4bffdf2a1034b4e8ae8c1b484769154f9d382a00 (diff) |
Revert of Revert of Rename kPMColor_SkColorType to kN32_SkColorType. (https://codereview.chromium.org/234243002/)
Reason for revert:
Want to reland the original CL.
Original issue's description:
> Revert of Rename kPMColor_SkColorType to kN32_SkColorType. (https://codereview.chromium.org/227433009/)
>
> Reason for revert:
> breaking the Chrome deps roll.
> http://build.chromium.org/p/chromium.linux/builders/Linux%20GN%20%28dbg%29/builds/839/steps/compile/logs/stdio
>
> Original issue's description:
> > Rename kPMColor_SkColorType to kN32_SkColorType.
> >
> > The new name better represents what this flag means.
> >
> > BUG=skia:2384
> >
> > Committed: http://code.google.com/p/skia/source/detail?r=14117
>
> TBR=reed@google.com,scroggo@google.com
> NOTREECHECKS=true
> NOTRY=true
> BUG=skia:2384
>
> Committed: http://code.google.com/p/skia/source/detail?r=14144
R=reed@google.com, bensong@google.com
TBR=bensong@google.com, reed@google.com
NOTREECHECKS=true
NOTRY=true
BUG=skia:2384
Author: scroggo@google.com
Review URL: https://codereview.chromium.org/235523003
git-svn-id: http://skia.googlecode.com/svn/trunk@14156 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'include')
-rw-r--r-- | include/core/SkImageInfo.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/include/core/SkImageInfo.h b/include/core/SkImageInfo.h index 1c73d959af..83919549d5 100644 --- a/include/core/SkImageInfo.h +++ b/include/core/SkImageInfo.h @@ -80,12 +80,16 @@ enum SkColorType { kLastEnum_SkColorType = kIndex_8_SkColorType, #if SK_PMCOLOR_BYTE_ORDER(B,G,R,A) - kPMColor_SkColorType = kBGRA_8888_SkColorType + kN32_SkColorType = kBGRA_8888_SkColorType, #elif SK_PMCOLOR_BYTE_ORDER(R,G,B,A) - kPMColor_SkColorType = kRGBA_8888_SkColorType + kN32_SkColorType = kRGBA_8888_SkColorType, #else #error "SK_*32_SHFIT values must correspond to BGRA or RGBA byte order" #endif + +#ifdef SK_SUPPORT_LEGACY_N32_NAME + kPMColor_SkColorType = kN32_SkColorType +#endif }; static int SkColorTypeBytesPerPixel(SkColorType ct) { @@ -136,7 +140,7 @@ struct SkImageInfo { */ static SkImageInfo MakeN32(int width, int height, SkAlphaType at) { SkImageInfo info = { - width, height, kPMColor_SkColorType, at + width, height, kN32_SkColorType, at }; return info; } @@ -146,7 +150,7 @@ struct SkImageInfo { */ static SkImageInfo MakeN32Premul(int width, int height) { SkImageInfo info = { - width, height, kPMColor_SkColorType, kPremul_SkAlphaType + width, height, kN32_SkColorType, kPremul_SkAlphaType }; return info; } |