#pragma once
#include "src/pathops/SkPathOpsPoint.h"
namespace pk {
struct SkDLine {
SkDPoint fPts[2];
const SkDPoint& operator[](int n) const { PkASSERT(n >= 0 && n < 2); return fPts[n]; }
SkDPoint& operator[](int n) { PkASSERT(n >= 0 && n < 2); return fPts[n]; }
const SkDLine& set(const SkPoint pts[2]) {
fPts[0] = pts[0];
fPts[1] = pts[1];
return *this;
}
double exactPoint(const SkDPoint& xy) const;
static double ExactPointH(const SkDPoint& xy, double left, double right, double y);
static double ExactPointV(const SkDPoint& xy, double top, double bottom, double x);
double nearPoint(const SkDPoint& xy, bool* unequal) const;
bool nearRay(const SkDPoint& xy) const;
static double NearPointH(const SkDPoint& xy, double left, double right, double y);
static double NearPointV(const SkDPoint& xy, double top, double bottom, double x);
SkDPoint ptAtT(double t) const;
void dump() const;
void dumpID(int ) const;
void dumpInner() const;
};
}