clean up TODO
The premise of the TODO here is somewhat wrong. There are other places where we do pass the destination color space through the ContextRec to shaders that care... just not here when chosing the top-level blitter. Change-Id: Ie32cfff5af0328c1280721246194a9eb1f0a5874 Reviewed-on: https://skia-review.googlesource.com/c/174040 Reviewed-by: Mike Klein <mtklein@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
This commit is contained in:
parent
45723ac931
commit
a8a5cee2f6
@ -842,16 +842,14 @@ SkBlitter* SkBlitter::Choose(const SkPixmap& device,
|
|||||||
return blitter;
|
return blitter;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Everything but kN32_SkColorType and kRGB_565_SkColorType should already be handled.
|
// Everything but legacy kN32_SkColorType and kRGB_565_SkColorType should already be handled.
|
||||||
|
SkASSERT(!device.colorSpace());
|
||||||
SkASSERT(device.colorType() == kN32_SkColorType ||
|
SkASSERT(device.colorType() == kN32_SkColorType ||
|
||||||
device.colorType() == kRGB_565_SkColorType);
|
device.colorType() == kRGB_565_SkColorType);
|
||||||
|
|
||||||
// And we should either have a shader, be blending with SrcOver, or both.
|
// And we should either have a shader, be blending with SrcOver, or both.
|
||||||
SkASSERT(paint->getShader() || paint->getBlendMode() == SkBlendMode::kSrcOver);
|
SkASSERT(paint->getShader() || paint->getBlendMode() == SkBlendMode::kSrcOver);
|
||||||
|
|
||||||
// TODO: remove SkColorSpace from makeContext() arguments. It's always nullptr.
|
|
||||||
SkASSERT(!device.colorSpace());
|
|
||||||
|
|
||||||
// Legacy blitters keep their shader state on a shader context.
|
// Legacy blitters keep their shader state on a shader context.
|
||||||
SkShaderBase::Context* shaderContext = nullptr;
|
SkShaderBase::Context* shaderContext = nullptr;
|
||||||
if (paint->getShader()) {
|
if (paint->getShader()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user