Initial support for GL_NV_path_renering. Experimental, there are still some issues to resolve, set gyp variable skia_nv_path_rendering=1 or build flag GR_GL_USE_NV_PATH_RENDERING to enable.
http://codereview.appspot.com/6349049/
git-svn-id: http://skia.googlecode.com/svn/trunk@4390 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/src/gpu/GrClipMaskManager.cpp b/src/gpu/GrClipMaskManager.cpp
index cb543e1..30944d9 100644
--- a/src/gpu/GrClipMaskManager.cpp
+++ b/src/gpu/GrClipMaskManager.cpp
@@ -687,9 +687,9 @@
bool clearToInside;
SkRegion::Op startOp = SkRegion::kReplace_Op; // suppress warning
int start = process_initial_clip_elements(clipCopy,
- rtRect,
- &clearToInside,
- &startOp);
+ rtRect,
+ &clearToInside,
+ &startOp);
fGpu->clearStencilClip(bounds, clearToInside);
@@ -700,6 +700,14 @@
bool fillInverted;
// enabled at bottom of loop
drawState->disableState(GrGpu::kModifyStencilClip_StateBit);
+ // if the target is MSAA then we want MSAA enabled when the clip is soft
+ if (rt->isMultisampled()) {
+ if (clipCopy.getDoAA(c)) {
+ drawState->enableState(GrDrawState::kHWAntialias_StateBit);
+ } else {
+ drawState->disableState(GrDrawState::kHWAntialias_StateBit);
+ }
+ }
bool canRenderDirectToStencil; // can the clip element be drawn
// directly to the stencil buffer