#include "include/core/SkPath.h"
#include "include/core/SkPoint.h"
#include "include/core/SkRect.h"
#include "include/core/SkScalar.h"
#include "include/core/SkTypes.h"
#include "include/private/base/SkDebug.h"
#include "include/private/base/SkMalloc.h"
#include "include/private/base/SkMath.h"
#include "include/private/base/SkTArray.h"
#include "src/base/SkArenaAlloc.h"
#include "src/base/SkTSort.h"
#include "src/pathops/SkOpContour.h"
#include "src/pathops/SkOpSegment.h"
#include "src/pathops/SkOpSpan.h"
#include "src/pathops/SkPathOpsBounds.h"
#include "src/pathops/SkPathOpsCurve.h"
#include "src/pathops/SkPathOpsPoint.h"
#include "src/pathops/SkPathOpsTypes.h"
#include <cmath>
#include <utility>
usingnamespaceskia_private;
enum class SkOpRayDir { … };
#if DEBUG_WINDING
const char* gDebugRayDirName[] = {
"kLeft",
"kTop",
"kRight",
"kBottom"
};
#endif
static int xy_index(SkOpRayDir dir) { … }
static SkScalar pt_xy(const SkPoint& pt, SkOpRayDir dir) { … }
static SkScalar pt_yx(const SkPoint& pt, SkOpRayDir dir) { … }
static double pt_dxdy(const SkDVector& v, SkOpRayDir dir) { … }
static double pt_dydx(const SkDVector& v, SkOpRayDir dir) { … }
static SkScalar rect_side(const SkRect& r, SkOpRayDir dir) { … }
static bool sideways_overlap(const SkRect& rect, const SkPoint& pt, SkOpRayDir dir) { … }
static bool less_than(SkOpRayDir dir) { … }
static bool ccw_dxdy(const SkDVector& v, SkOpRayDir dir) { … }
struct SkOpRayHit { … };
void SkOpContour::rayCheck(const SkOpRayHit& base, SkOpRayDir dir, SkOpRayHit** hits,
SkArenaAlloc* allocator) { … }
void SkOpSegment::rayCheck(const SkOpRayHit& base, SkOpRayDir dir, SkOpRayHit** hits,
SkArenaAlloc* allocator) { … }
SkOpSpan* SkOpSegment::windingSpanAtT(double tHit) { … }
static bool hit_compare_x(const SkOpRayHit* a, const SkOpRayHit* b) { … }
static bool reverse_hit_compare_x(const SkOpRayHit* a, const SkOpRayHit* b) { … }
static bool hit_compare_y(const SkOpRayHit* a, const SkOpRayHit* b) { … }
static bool reverse_hit_compare_y(const SkOpRayHit* a, const SkOpRayHit* b) { … }
static double get_t_guess(int tTry, int* dirOffset) { … }
bool SkOpSpan::sortableTop(SkOpContour* contourHead) { … }
SkOpSpan* SkOpSegment::findSortableTop(SkOpContour* contourHead) { … }
SkOpSpan* SkOpContour::findSortableTop(SkOpContour* contourHead) { … }
SkOpSpan* FindSortableTop(SkOpContourHead* contourHead) { … }