Index: bench/ColorCodecBench.cpp |
diff --git a/bench/ColorCodecBench.cpp b/bench/ColorCodecBench.cpp |
index 6aa46d609f5877bb5e624ff66c4b45bf395a26c3..fe3cdd24b5791c3a44075a0808f3ff6619fdb612 100644 |
--- a/bench/ColorCodecBench.cpp |
+++ b/bench/ColorCodecBench.cpp |
@@ -9,7 +9,7 @@ |
#include "Resources.h" |
#include "SkCodec.h" |
#include "SkCodecPriv.h" |
-#include "SkColorSpace_Base.h" |
+#include "SkColorSpace_XYZ.h" |
#include "SkColorSpaceXform.h" |
#include "SkCommandLineFlags.h" |
@@ -170,7 +170,8 @@ void ColorCodecBench::onDelayedSetup() { |
if (FLAGS_half) { |
fDstInfo = fDstInfo.makeColorType(kRGBA_F16_SkColorType); |
- fDstSpace = as_CSB(fDstSpace)->makeLinearGamma(); |
+ SkASSERT(SkColorSpace_Base::Type::kXYZ == as_CSB(fDstSpace)->type()); |
+ fDstSpace = static_cast<SkColorSpace_XYZ*>(fDstSpace.get())->makeLinearGamma(); |
} |
if (FLAGS_nonstd) { |