diff options
author | 2012-08-20 19:22:38 +0000 | |
---|---|---|
committer | 2012-08-20 19:22:38 +0000 | |
commit | 0342a85091fd430c90a142d155dc9642aa729d9e (patch) | |
tree | ad84edb6b6194b35ca77783c7147c2e62a56542f /src/gpu/GrDrawTarget.cpp | |
parent | b7961193a3ecca44cf2650d9e446ebaa10b1583d (diff) |
Remove _UPM_ GrPixelConfigs
Review URL: http://codereview.appspot.com/6460113/
git-svn-id: http://skia.googlecode.com/svn/trunk@5196 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/gpu/GrDrawTarget.cpp')
-rw-r--r-- | src/gpu/GrDrawTarget.cpp | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/src/gpu/GrDrawTarget.cpp b/src/gpu/GrDrawTarget.cpp index f0f1864a55..5b90480cba 100644 --- a/src/gpu/GrDrawTarget.cpp +++ b/src/gpu/GrDrawTarget.cpp @@ -760,29 +760,6 @@ bool GrDrawTarget::checkDraw(GrPrimitiveType type, int startVertex, if (NULL == drawState.getRenderTarget()) { return false; } - if (GrPixelConfigIsUnpremultiplied(drawState.getRenderTarget()->config())) { - if (kOne_GrBlendCoeff != drawState.getSrcBlendCoeff() || - kZero_GrBlendCoeff != drawState.getDstBlendCoeff()) { - return false; - } - } - // We don't support using unpremultiplied textures with bilerp. Alpha-multiplication is not - // distributive with respect to filtering. We'd have to alpha-mul each texel before filtering. - // Until Skia itself supports unpremultiplied configs there is no pressure to implement this. - for (int s = 0; s < GrDrawState::kNumStages; ++s) { - if (drawState.isStageEnabled(s)) { - const GrCustomStage* stage = drawState.getSampler(s).getCustomStage(); - int numTextures = stage->numTextures(); - for (int t = 0; t < numTextures; ++t) { - GrTexture* texture = stage->texture(t); - GrAssert(NULL != texture); - if (GrPixelConfigIsUnpremultiplied(texture->config()) && - drawState.getSampler(s).getTextureParams().isBilerp()) { - return false; - } - } - } - } return true; } |