return NULL;
}
-static bool windingIsActive(int winding, int oppWinding, int spanWinding,
+static bool windingIsActive(int winding, int oppWinding, int spanWinding,
bool windingIsOp, ShapeOp op) {
bool active = windingIsActive(winding, spanWinding);
if (!active) {
} else {
contourWinding = sumWinding;
oppContourWinding = 0;
- SkASSERT(0);
+ SkASSERT(0);
// FIXME: need to get oppContourWinding by building sort wheel and
// retrieving sumWinding of uphill opposite span, calling inner contour check
// if need be
int spanWinding = current->spanSign(index, endIndex);
SkTDArray<Span*> chaseArray;
do {
- bool active = windingIsActive(winding, oppWinding, spanWinding,
+ bool active = windingIsActive(winding, oppWinding, spanWinding,
current->operand(), op);
#if DEBUG_WINDING
SkDebugf("%s active=%s winding=%d oppWinding=%d spanWinding=%d\n",
kIntersect_Op,
kUnion_Op,
kXor_Op,
- kShapeOp_Count
+ kShapeOp_Count
};
enum ShapeOpMask {
SkPath::Verb verb() const {
return fVerb;
}
-
+
int windSum(int tIndex) const {
return fTs[tIndex].fWindSum;
}
int index = SkMin32(start, end);
return windValue(index);
}
-
+
SkScalar xAtT(const Span* span) const {
return xyAtT(span).fX;
}
last = lastSum;
wind = windSum;
}
- SkDebugf(" winding: %d->%d (max=%d) ", last, wind,
+ SkDebugf(" winding: %d->%d (max=%d) ", last, wind,
useInnerWinding(last, wind) ? wind : last);
SkDebugf(" done=%d tiny=%d opp=%d\n", mSpan.fDone, mSpan.fTiny, opp);
#if false && DEBUG_ANGLE
fSegments[sIndex].fixOtherTIndex();
}
}
-
+
bool operand() const {
return fOperand;
}
SkDebugf(
"----- %s max pixel mismatch for %s is %d\n",
renderModeDescriptor, name.c_str(), maxErr);
-
+
if (diff) {
diff->setConfig(SkBitmap::kARGB_8888_Config, w, h);
diff->allocPixels();
struct FailRec {
SkString fName;
int fMaxPixelError;
-
+
FailRec() : fMaxPixelError(0) {}
FailRec(const SkString& name) : fName(name), fMaxPixelError(0) {}
};
int cx = mask.fBounds.centerX();
int cy = mask.fBounds.centerY();
SkMask m;
-
+
// top-left
m.fBounds = mask.fBounds;
m.fBounds.fRight = cx;
extractMaskSubset(mask, &m);
m.fBounds.offsetTo(outerR.left(), outerR.top());
blitClippedMask(blitter, m, m.fBounds, clipR);
-
+
// top-right
m.fBounds = mask.fBounds;
m.fBounds.fLeft = cx + 1;
extractMaskSubset(mask, &m);
m.fBounds.offsetTo(outerR.right() - m.fBounds.width(), outerR.top());
blitClippedMask(blitter, m, m.fBounds, clipR);
-
+
// bottom-left
m.fBounds = mask.fBounds;
m.fBounds.fRight = cx;
extractMaskSubset(mask, &m);
m.fBounds.offsetTo(outerR.left(), outerR.bottom() - m.fBounds.height());
blitClippedMask(blitter, m, m.fBounds, clipR);
-
+
// bottom-right
m.fBounds = mask.fBounds;
m.fBounds.fLeft = cx + 1;
// if we get here, we need to (possibly) resolve the clip and blitter
SkAAClipBlitterWrapper wrapper(clip, blitter);
blitter = wrapper.getBlitter();
-
+
SkRegion::Cliperator clipper(wrapper.getRgn(), outerR);
-
+
if (!clipper.done() && (!bounder || bounder->doIRect(outerR))) {
const SkIRect& cr = clipper.rect();
do {
const SkIRect& clipBounds,
SkMask* ninePatchMask,
SkIRect* outerRect) SK_OVERRIDE;
-
+
private:
SkScalar fRadius;
SkBlurMaskFilter::BlurStyle fBlurStyle;
d = a;
d.preConcat(b);
REPORTER_ASSERT(reporter, d == c);
-
+
c.mapScalars(src, dst); c.mapScalars(src + 4, dst + 4);
for (i = 0; i < 3; ++i) {
REPORTER_ASSERT(reporter, 10 == dst[i]);
REPORTER_ASSERT(reporter, 12 == dst[i + 4]);
}
-
+
c.setConcat(b, a);
d = a;