diff options
author | 2011-05-20 14:13:56 +0000 | |
---|---|---|
committer | 2011-05-20 14:13:56 +0000 | |
commit | 271cffc77bd2fcb3458559e509634442517ca1e9 (patch) | |
tree | 694551c3f27e547710ad5779dd010f486ee96e25 /gpu/src/GrGpuGL.h | |
parent | 3c14d0f3d1b467dc3776669b0fc48cb463a20d41 (diff) |
Add dual source blending support for proper blending with coverage.
Review URL: http://codereview.appspot.com/4535088/
git-svn-id: http://skia.googlecode.com/svn/trunk@1390 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'gpu/src/GrGpuGL.h')
-rw-r--r-- | gpu/src/GrGpuGL.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/gpu/src/GrGpuGL.h b/gpu/src/GrGpuGL.h index 0d3e4b4fed..696b72f290 100644 --- a/gpu/src/GrGpuGL.h +++ b/gpu/src/GrGpuGL.h @@ -116,13 +116,17 @@ protected: // flushes state that is common to fixed and programmable GL // dither // line smoothing - // blend func // texture binding // sampler state (filtering, tiling) // FBO binding // line width bool flushGLStateCommon(GrPrimitiveType type); + // subclass should call this to flush the blend state + void flushBlend(GrPrimitiveType type, + GrBlendCoeff srcCoeff, + GrBlendCoeff dstCoeff); + // adjusts texture matrix to account for orientation, size, and npotness static void AdjustTextureMatrix(const GrGLTexture* texture, GrSamplerState::SampleMode mode, @@ -134,7 +138,7 @@ protected: static bool TextureMatrixIsIdentity(const GrGLTexture* texture, const GrSamplerState& sampler); - static bool BlendCoefReferencesConstant(GrBlendCoeff coeff); + static bool BlendCoeffReferencesConstant(GrBlendCoeff coeff); private: @@ -156,7 +160,6 @@ private: void flushRenderTarget(const GrIRect* bound); void flushStencil(); void flushAAState(GrPrimitiveType type); - void flushBlend(GrPrimitiveType type); void resolveRenderTarget(GrGLRenderTarget* texture); |