diff options
author | Leon Scroggins III <scroggo@google.com> | 2017-10-31 13:49:14 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-10-31 18:13:04 +0000 |
commit | f78b55cb94f4ac89b76a26d5a56d6380aa8fea6b (patch) | |
tree | 46f0d0bdae4d61a601f6b6d30982fe3d6f39cbd9 /src/core/SkColorSpace_A2B.cpp | |
parent | e7ac58c0d5d4585912b2fc26c2d692c6f3c28199 (diff) |
Simplify SkColorSpace::MakeICC
Rather than restricting the supported ICC types in MakeICC, create any
ICC type that we support, and make the client reject them as necessary
by querying the SkColorSpace::Type.
Remove ICCTypeFlag and replace uses of it with SkColorSpace::Type.
This depends on a change in Chromium
(https://chromium-review.googlesource.com/c/chromium/src/+/741843).
Without that, this change will start allowing non-CMYK images to use
CMYK profiles.
Bug: 727128
Change-Id: I085b4665e49bc80083264496d864cc4cd62ae914
Reviewed-on: https://skia-review.googlesource.com/64841
Commit-Queue: Leon Scroggins <scroggo@google.com>
Reviewed-by: Mike Klein <mtklein@chromium.org>
Diffstat (limited to 'src/core/SkColorSpace_A2B.cpp')
-rw-r--r-- | src/core/SkColorSpace_A2B.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/SkColorSpace_A2B.cpp b/src/core/SkColorSpace_A2B.cpp index 7e097ffa80..b5d8d37747 100644 --- a/src/core/SkColorSpace_A2B.cpp +++ b/src/core/SkColorSpace_A2B.cpp @@ -7,12 +7,12 @@ #include "SkColorSpace_A2B.h" -SkColorSpace_A2B::SkColorSpace_A2B(ICCTypeFlag iccType, std::vector<Element> elements, +SkColorSpace_A2B::SkColorSpace_A2B(SkColorSpace::Type iccType, std::vector<Element> elements, PCS pcs, sk_sp<SkData> profileData) : INHERITED(std::move(profileData)) , fICCType(iccType) , fElements(std::move(elements)) , fPCS(pcs) { - SkASSERT(kRGB_ICCTypeFlag == iccType || kCMYK_ICCTypeFlag == iccType); + SkASSERT(SkColorSpace::kRGB_Type == iccType || SkColorSpace::kCMYK_Type == iccType); } |