From 055c7c299cb47eebd360b809ad58a0006e2e55f7 Mon Sep 17 00:00:00 2001 From: "skia.committer@gmail.com" Date: Sat, 15 Sep 2012 02:01:41 +0000 Subject: Sanitizing source files in Skia_Periodic_House_Keeping git-svn-id: http://skia.googlecode.com/svn/trunk@5561 2bbb7eff-a529-9590-31e7-b0007b416f81 --- experimental/Intersection/DataTypes.h | 2 +- experimental/Intersection/Intersections.cpp | 4 ++-- experimental/Intersection/Intersections.h | 6 +++--- experimental/Intersection/QuadraticImplicit.cpp | 2 +- experimental/Intersection/QuadraticIntersection.cpp | 2 +- experimental/Intersection/QuadraticParameterization.h | 2 +- experimental/Intersection/QuarticRoot.cpp | 14 +++++++------- experimental/Intersection/ShapeOps.cpp | 2 +- experimental/Intersection/Simplify.cpp | 16 ++++++++-------- 9 files changed, 25 insertions(+), 25 deletions(-) (limited to 'experimental') diff --git a/experimental/Intersection/DataTypes.h b/experimental/Intersection/DataTypes.h index dc61699fa0..0c51a20647 100644 --- a/experimental/Intersection/DataTypes.h +++ b/experimental/Intersection/DataTypes.h @@ -190,7 +190,7 @@ struct _Rect { bottom = pt.y; } } - + // FIXME: used by debugging only ? bool contains(const _Point& pt) { return approximately_between(left, pt.x, right) diff --git a/experimental/Intersection/Intersections.cpp b/experimental/Intersection/Intersections.cpp index 089a432e09..3f4e8cf32b 100644 --- a/experimental/Intersection/Intersections.cpp +++ b/experimental/Intersection/Intersections.cpp @@ -4,7 +4,7 @@ * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ - + #include "DataTypes.h" #include "Intersections.h" @@ -12,5 +12,5 @@ void Intersections::cleanUp() { assert(fCoincidentUsed); assert(fUsed); // find any entries in fT that could be part of the coincident range - + } diff --git a/experimental/Intersection/Intersections.h b/experimental/Intersection/Intersections.h index 464e1a8929..a09cfcda9c 100644 --- a/experimental/Intersection/Intersections.h +++ b/experimental/Intersection/Intersections.h @@ -118,7 +118,7 @@ public: fT[fSwap][index] = val; } } - + void insert(double one, double two) { assert(fUsed <= 1 || fT[0][0] < fT[0][1]); int index; @@ -141,7 +141,7 @@ public: fT[1][index] = two; ++fUsed; } - + void insertOne(double t, int side) { int used = side ? fUsed2 : fUsed; assert(used <= 1 || fT[side][0] < fT[side][1]); @@ -166,7 +166,7 @@ public: bool intersected() const { return fUsed > 0; } - + bool insertBalanced() const { return fUsed == fUsed2; } diff --git a/experimental/Intersection/QuadraticImplicit.cpp b/experimental/Intersection/QuadraticImplicit.cpp index b5efd037db..c8635d408c 100644 --- a/experimental/Intersection/QuadraticImplicit.cpp +++ b/experimental/Intersection/QuadraticImplicit.cpp @@ -14,7 +14,7 @@ /* given the implicit form 0 = Ax^2 + Bxy + Cy^2 + Dx + Ey + F * and given x = at^2 + bt + c (the parameterized form) * y = dt^2 + et + f - * then + * then * 0 = A(at^2+bt+c)(at^2+bt+c)+B(at^2+bt+c)(dt^2+et+f)+C(dt^2+et+f)(dt^2+et+f)+D(at^2+bt+c)+E(dt^2+et+f)+F */ diff --git a/experimental/Intersection/QuadraticIntersection.cpp b/experimental/Intersection/QuadraticIntersection.cpp index 28299dd866..800964d350 100644 --- a/experimental/Intersection/QuadraticIntersection.cpp +++ b/experimental/Intersection/QuadraticIntersection.cpp @@ -262,7 +262,7 @@ double coinMaxT2; static void hackToFixPartialCoincidence(const Quadratic& q1, const Quadratic& q2, Intersections& i) { // look to see if non-coincident data basically has unsortable tangents - + // look to see if a point between non-coincident data is on the curve int cIndex; for (int uIndex = 0; uIndex < i.fUsed; ) { diff --git a/experimental/Intersection/QuadraticParameterization.h b/experimental/Intersection/QuadraticParameterization.h index 5c651b61cf..ca7d072208 100644 --- a/experimental/Intersection/QuadraticParameterization.h +++ b/experimental/Intersection/QuadraticParameterization.h @@ -4,7 +4,7 @@ class QuadImplicitForm { public: QuadImplicitForm(const Quadratic& q); bool implicit_match(const QuadImplicitForm& two) const; - + double x2() const { return p[xx_coeff]; } double xy() const { return p[xy_coeff]; } double y2() const { return p[yy_coeff]; } diff --git a/experimental/Intersection/QuarticRoot.cpp b/experimental/Intersection/QuarticRoot.cpp index 509a4f0263..e0ec2b0f29 100644 --- a/experimental/Intersection/QuarticRoot.cpp +++ b/experimental/Intersection/QuarticRoot.cpp @@ -14,9 +14,9 @@ * * Jan 26, 1990 Version for Graphics Gems * Oct 11, 1990 Fixed sign problem for negative q's in SolveQuartic - * (reported by Mark Podlipec), - * Old-style function definitions, - * IsZero() as a macro + * (reported by Mark Podlipec), + * Old-style function definitions, + * IsZero() as a macro * Nov 23, 1990 Some systems do not declare acos() and cbrt() in * , though the functions exist in the library. * If large coefficients are used, EQN_EPS should be @@ -72,7 +72,7 @@ static int cubicRootsX(const double A, const double B, const double C, const double b = C * invA; const double c = D * invA; /* substitute x = y - a/3 to eliminate quadric term: - x^3 +px + q = 0 */ + x^3 +px + q = 0 */ const double a2 = a * a; const double Q = (-a2 + b * 3) / 9; const double R = (2 * a2 * a - 9 * a * b + 27 * c) / 54; @@ -84,7 +84,7 @@ static int cubicRootsX(const double A, const double B, const double C, s[0] = 0; num = 1; } else { /* one single and one double solution */ - + double u = cube_root(-R); s[0] = 2 * u; s[1] = -u; @@ -130,13 +130,13 @@ int quarticRoots(const double A, const double B, const double C, const double D, const double c = D * invA; const double d = E * invA; /* substitute x = y - a/4 to eliminate cubic term: - x^4 + px^2 + qx + r = 0 */ + x^4 + px^2 + qx + r = 0 */ const double a2 = a * a; const double p = -3 * a2 / 8 + b; const double q = a2 * a / 8 - a * b / 2 + c; const double r = -3 * a2 * a2 / 256 + a2 * b / 16 - a * c / 4 + d; if (approximately_zero(r)) { - /* no absolute term: y(y^3 + py + q) = 0 */ + /* no absolute term: y(y^3 + py + q) = 0 */ num = cubicRootsX(1, 0, p, q, s); s[num++] = 0; } else { diff --git a/experimental/Intersection/ShapeOps.cpp b/experimental/Intersection/ShapeOps.cpp index 74e1626c66..4058a16ca0 100644 --- a/experimental/Intersection/ShapeOps.cpp +++ b/experimental/Intersection/ShapeOps.cpp @@ -16,7 +16,7 @@ static bool windingIsActive(int winding, int spanWinding, int oppWinding, && (!winding || !spanWinding || winding == -spanWinding); } -static void bridgeOp(SkTDArray& contourList, const ShapeOp op, +static void bridgeOp(SkTDArray& contourList, const ShapeOp op, const int aXorMask, const int bXorMask, SkPath& simple) { bool firstContour = true; do { diff --git a/experimental/Intersection/Simplify.cpp b/experimental/Intersection/Simplify.cpp index 78c36f6510..b5403bfbb4 100644 --- a/experimental/Intersection/Simplify.cpp +++ b/experimental/Intersection/Simplify.cpp @@ -539,7 +539,7 @@ public: SkASSERT(fSide != rh.fSide); return fSide < rh.fSide; } - #if 0 // the following code is a bust. In particular, tangent length doesn't provide a sort + #if 0 // the following code is a bust. In particular, tangent length doesn't provide a sort if (y != ry) { return (fabs(y) < fabs(ry)) ^ (fSide > 0); } @@ -555,7 +555,7 @@ public: #else SkASSERT(fVerb == SkPath::kQuad_Verb); // worry about cubics later SkASSERT(rh.fVerb == SkPath::kQuad_Verb); - // FIXME: until I can think of something better, project a ray perpendicular from the + // FIXME: until I can think of something better, project a ray perpendicular from the // end of the shorter tangent through both curves and use the resulting angle to sort // FIXME: some of this setup can be moved to set() if it works, or cached if it's expensive double len = fTangent1.normalSquared(); @@ -1653,7 +1653,7 @@ public: const Span& mSpan = fTs[SkMin32(start, end)]; return mSpan.fDone; } - + Segment* findNextOp(SkTDArray& chase, bool active, int& nextStart, int& nextEnd, int& winding, int& spanWinding, ShapeOp op, const int aXorMask, const int bXorMask) { @@ -1765,7 +1765,7 @@ public: SkDebugf("%s [%d] maxWinding=%d sumWinding=%d sign=%d altFlipped=%d\n", __FUNCTION__, nextIndex, maxWinding, sumWinding, nextAngle->sign(), altFlipped); #endif - + if (!(sumWinding & xorMask) && activeOp(angleIsOp, otherNonZero, op)) { if (!active) { markDone(SkMin32(startIndex, endIndex), outerWinding); @@ -2603,7 +2603,7 @@ public: } return -1; } - + bool operand() const { return fOperand; } @@ -2710,7 +2710,7 @@ public: SkScalar xAtT(const Span* span) const { return xyAtT(span).fX; } - + const SkPoint& xyAtT(int index) const { return xyAtT(&fTs[index]); } @@ -3157,7 +3157,7 @@ public: void setOperand(bool isOp) { fOperand = isOp; } - + void setXor(bool isXor) { fXor = isXor; } @@ -3441,7 +3441,7 @@ void walk() { SkASSERT(fCurrentContour); if (verbPtr == endOfFirstHalf) { fOperand = true; - } + } } } -- cgit v1.2.3