Push much of the SkColorSpace_Base interface up to SkColorSpace
Some pieces still remain, but the next step looks less mechanical,
so I wanted to land this piece independently.
Bug: skia:
Change-Id: Ie63afcfa08af2f6e4996911fa2225c43441dbfb2
Reviewed-on: https://skia-review.googlesource.com/84120
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Brian Osman <brianosman@google.com>
diff --git a/src/image/SkImage_Lazy.cpp b/src/image/SkImage_Lazy.cpp
index b18b17a..c5a2b8d 100644
--- a/src/image/SkImage_Lazy.cpp
+++ b/src/image/SkImage_Lazy.cpp
@@ -390,7 +390,7 @@
return fInfo.makeColorSpace(nullptr);
case kLinearF16_CachedFormat:
return fInfo.makeColorType(kRGBA_F16_SkColorType)
- .makeColorSpace(as_CSB(fInfo.colorSpace())->makeLinearGamma());
+ .makeColorSpace(fInfo.colorSpace()->makeLinearGamma());
case kSRGB8888_CachedFormat:
// If the transfer function is nearly (but not exactly) sRGB, we don't want the codec
// to bother trans-coding. It would be slow, and do more harm than good visually,
@@ -399,7 +399,7 @@
return fInfo.makeColorType(kRGBA_8888_SkColorType);
} else {
return fInfo.makeColorType(kRGBA_8888_SkColorType)
- .makeColorSpace(as_CSB(fInfo.colorSpace())->makeSRGBGamma());
+ .makeColorSpace(fInfo.colorSpace()->makeSRGBGamma());
}
case kSBGR8888_CachedFormat:
// See note above about not-quite-sRGB transfer functions.
@@ -407,7 +407,7 @@
return fInfo.makeColorType(kBGRA_8888_SkColorType);
} else {
return fInfo.makeColorType(kBGRA_8888_SkColorType)
- .makeColorSpace(as_CSB(fInfo.colorSpace())->makeSRGBGamma());
+ .makeColorSpace(fInfo.colorSpace()->makeSRGBGamma());
}
default:
SkDEBUGFAIL("Invalid cached format");