Home | History | Annotate | Download | only in pathops
      1 /*
      2  * Copyright 2012 Google Inc.
      3  *
      4  * Use of this source code is governed by a BSD-style license that can be
      5  * found in the LICENSE file.
      6  */
      7 #ifndef SkPathOpsCommon_DEFINED
      8 #define SkPathOpsCommon_DEFINED
      9 
     10 #include "SkOpAngle.h"
     11 #include "SkTDArray.h"
     12 
     13 class SkOpCoincidence;
     14 class SkOpContour;
     15 class SkPathWriter;
     16 
     17 const SkOpAngle* AngleWinding(SkOpSpanBase* start, SkOpSpanBase* end, int* windingPtr,
     18                               bool* sortable);
     19 SkOpSegment* FindChase(SkTDArray<SkOpSpanBase*>* chase, SkOpSpanBase** startPtr,
     20                        SkOpSpanBase** endPtr);
     21 SkOpSpan* FindSortableTop(SkOpContourHead* );
     22 SkOpSpan* FindUndone(SkOpContourHead* );
     23 bool FixWinding(SkPath* path);
     24 bool SortContourList(SkOpContourHead** , bool evenOdd, bool oppEvenOdd);
     25 bool HandleCoincidence(SkOpContourHead* , SkOpCoincidence* );
     26 bool OpDebug(const SkPath& one, const SkPath& two, SkPathOp op, SkPath* result
     27              SkDEBUGPARAMS(bool skipAssert)
     28              SkDEBUGPARAMS(const char* testName));
     29 SkScalar ScaleFactor(const SkPath& path);
     30 void ScalePath(const SkPath& path, SkScalar scale, SkPath* scaled);
     31 
     32 #endif
     33