Flutter Engine
The Flutter Engine
Public Member Functions | Public Attributes | List of all members
SkOpRayHit Struct Reference

Public Member Functions

SkOpRayDir makeTestBase (SkOpSpan *span, double t)
 

Public Attributes

SkOpRayHitfNext
 
SkOpSpanfSpan
 
SkPoint fPt
 
double fT
 
SkDVector fSlope
 
bool fValid
 

Detailed Description

Definition at line 103 of file SkPathOpsWinding.cpp.

Member Function Documentation

◆ makeTestBase()

SkOpRayDir SkOpRayHit::makeTestBase ( SkOpSpan span,
double  t 
)
inline

Definition at line 104 of file SkPathOpsWinding.cpp.

104 {
105 fNext = nullptr;
106 fSpan = span;
107 fT = span->t() * (1 - t) + span->next()->t() * t;
108 SkOpSegment* segment = span->segment();
109 fSlope = segment->dSlopeAtT(fT);
110 fPt = segment->ptAtT(fT);
111 fValid = true;
112 return fabs(fSlope.fX) < fabs(fSlope.fY) ? SkOpRayDir::kLeft : SkOpRayDir::kTop;
113 }
SkDVector dSlopeAtT(double mid) const
Definition: SkOpSegment.h:213
SkPoint ptAtT(double mid) const
Definition: SkOpSegment.h:323
double t() const
Definition: SkOpSpan.h:375
SkOpSegment * segment() const
Definition: SkOpSpan.h:318
SkOpSpanBase * next() const
Definition: SkOpSpan.h:495
SkOpRayHit * fNext
SkOpSpan * fSpan
SkDVector fSlope

Member Data Documentation

◆ fNext

SkOpRayHit* SkOpRayHit::fNext

Definition at line 115 of file SkPathOpsWinding.cpp.

◆ fPt

SkPoint SkOpRayHit::fPt

Definition at line 117 of file SkPathOpsWinding.cpp.

◆ fSlope

SkDVector SkOpRayHit::fSlope

Definition at line 119 of file SkPathOpsWinding.cpp.

◆ fSpan

SkOpSpan* SkOpRayHit::fSpan

Definition at line 116 of file SkPathOpsWinding.cpp.

◆ fT

double SkOpRayHit::fT

Definition at line 118 of file SkPathOpsWinding.cpp.

◆ fValid

bool SkOpRayHit::fValid

Definition at line 120 of file SkPathOpsWinding.cpp.


The documentation for this struct was generated from the following file: