Flutter Engine
The Flutter Engine
|
#include "include/core/SkPath.h"
#include "include/core/SkArc.h"
#include "include/core/SkPathBuilder.h"
#include "include/core/SkRRect.h"
#include "include/core/SkStream.h"
#include "include/core/SkString.h"
#include "include/private/SkPathRef.h"
#include "include/private/base/SkFloatingPoint.h"
#include "include/private/base/SkMalloc.h"
#include "include/private/base/SkSpan_impl.h"
#include "include/private/base/SkTArray.h"
#include "include/private/base/SkTDArray.h"
#include "include/private/base/SkTo.h"
#include "src/base/SkFloatBits.h"
#include "src/base/SkTLazy.h"
#include "src/base/SkVx.h"
#include "src/core/SkCubicClipper.h"
#include "src/core/SkEdgeClipper.h"
#include "src/core/SkGeometry.h"
#include "src/core/SkMatrixPriv.h"
#include "src/core/SkPathEnums.h"
#include "src/core/SkPathMakers.h"
#include "src/core/SkPathPriv.h"
#include "src/core/SkPointPriv.h"
#include "src/core/SkStringUtils.h"
#include <algorithm>
#include <cmath>
#include <cstring>
#include <iterator>
#include <limits.h>
#include <utility>
Go to the source code of this file.
Classes | |
struct | SkPath_Storage_Equivalent |
class | SkAutoDisableDirectionCheck |
class | SkAutoPathBoundsUpdate |
struct | Convexicator |
class | ContourIter |
struct | SkHalfPlane |
Macros | |
#define | INITIAL_LASTMOVETOINDEX_VALUE ~0 |
#define | kValueNeverReturnedBySign 2 |
Enumerations | |
enum | DirChange { kUnknown_DirChange , kLeft_DirChange , kRight_DirChange , kStraight_DirChange , kBackwards_DirChange , kInvalid_DirChange } |
Functions | |
static float | poly_eval (float A, float B, float C, float t) |
static float | poly_eval (float A, float B, float C, float D, float t) |
static void | joinNoEmptyChecks (SkRect *dst, const SkRect &src) |
static bool | is_degenerate (const SkPath &path) |
bool | operator== (const SkPath &a, const SkPath &b) |
static bool | check_edge_against_rect (const SkPoint &p0, const SkPoint &p1, const SkRect &rect, SkPathFirstDirection dir) |
static int | rect_make_dir (SkScalar dx, SkScalar dy) |
static void | assert_known_direction (SkPathDirection dir) |
static bool | arc_is_lone_point (const SkRect &oval, SkScalar startAngle, SkScalar sweepAngle, SkPoint *pt) |
static void | angles_to_unit_vectors (SkScalar startAngle, SkScalar sweepAngle, SkVector *startV, SkVector *stopV, SkRotationDirection *dir) |
static int | build_arc_conics (const SkRect &oval, const SkVector &start, const SkVector &stop, SkRotationDirection dir, SkConic conics[SkConic::kMaxConicsForArc], SkPoint *singlePt) |
static void | subdivide_cubic_to (SkPath *path, const SkPoint pts[4], int level=2) |
static void | append_params (SkString *str, const char label[], const SkPoint pts[], int count, SkScalarAsStringType strType, SkScalar conicWeight=-12345) |
static int | sign (SkScalar x) |
static SkScalar | cross_prod (const SkPoint &p0, const SkPoint &p1, const SkPoint &p2) |
static int | find_max_y (const SkPoint pts[], int count) |
static int | find_diff_pt (const SkPoint pts[], int index, int n, int inc) |
static int | find_min_max_x_at_y (const SkPoint pts[], int index, int n, int *maxIndexPtr) |
static SkPathFirstDirection | crossToDir (SkScalar cross) |
static bool | between (SkScalar a, SkScalar b, SkScalar c) |
static SkScalar | eval_cubic_pts (SkScalar c0, SkScalar c1, SkScalar c2, SkScalar c3, SkScalar t) |
template<size_t N> | |
static void | find_minmax (const SkPoint pts[], SkScalar *minPtr, SkScalar *maxPtr) |
static bool | checkOnCurve (SkScalar x, SkScalar y, const SkPoint &start, const SkPoint &end) |
static int | winding_mono_cubic (const SkPoint pts[], SkScalar x, SkScalar y, int *onCurveCount) |
static int | winding_cubic (const SkPoint pts[], SkScalar x, SkScalar y, int *onCurveCount) |
static double | conic_eval_numerator (const SkScalar src[], SkScalar w, SkScalar t) |
static double | conic_eval_denominator (SkScalar w, SkScalar t) |
static int | winding_mono_conic (const SkConic &conic, SkScalar x, SkScalar y, int *onCurveCount) |
static bool | is_mono_quad (SkScalar y0, SkScalar y1, SkScalar y2) |
static int | winding_conic (const SkPoint pts[], SkScalar x, SkScalar y, SkScalar weight, int *onCurveCount) |
static int | winding_mono_quad (const SkPoint pts[], SkScalar x, SkScalar y, int *onCurveCount) |
static int | winding_quad (const SkPoint pts[], SkScalar x, SkScalar y, int *onCurveCount) |
static int | winding_line (const SkPoint pts[], SkScalar x, SkScalar y, int *onCurveCount) |
static void | tangent_cubic (const SkPoint pts[], SkScalar x, SkScalar y, SkTDArray< SkVector > *tangents) |
static void | tangent_conic (const SkPoint pts[], SkScalar x, SkScalar y, SkScalar w, SkTDArray< SkVector > *tangents) |
static void | tangent_quad (const SkPoint pts[], SkScalar x, SkScalar y, SkTDArray< SkVector > *tangents) |
static void | tangent_line (const SkPoint pts[], SkScalar x, SkScalar y, SkTDArray< SkVector > *tangents) |
static bool | contains_inclusive (const SkRect &r, SkScalar x, SkScalar y) |
static int | compute_quad_extremas (const SkPoint src[3], SkPoint extremas[3]) |
static int | compute_conic_extremas (const SkPoint src[3], SkScalar w, SkPoint extremas[3]) |
static int | compute_cubic_extremas (const SkPoint src[4], SkPoint extremas[5]) |
SkPathVerbAnalysis | sk_path_analyze_verbs (const uint8_t vbs[], int verbCount) |
static SkPath | clip (const SkPath &path, const SkHalfPlane &plane) |
#define INITIAL_LASTMOVETOINDEX_VALUE ~0 |
Definition at line 154 of file SkPath.cpp.
#define kValueNeverReturnedBySign 2 |
Definition at line 2206 of file SkPath.cpp.
enum DirChange |
Enumerator | |
---|---|
kUnknown_DirChange | |
kLeft_DirChange | |
kRight_DirChange | |
kStraight_DirChange | |
kBackwards_DirChange | |
kInvalid_DirChange |
Definition at line 2208 of file SkPath.cpp.
|
static |
Definition at line 940 of file SkPath.cpp.
|
static |
Definition at line 2005 of file SkPath.cpp.
|
static |
Definition at line 917 of file SkPath.cpp.
|
static |
Definition at line 860 of file SkPath.cpp.
Definition at line 2716 of file SkPath.cpp.
|
static |
If this returns 0, then the caller should just line-to the singlePt, else it should ignore singlePt and append the specified number of conics.
Definition at line 978 of file SkPath.cpp.
|
inlinestatic |
Definition at line 265 of file SkPath.cpp.
|
static |
Definition at line 2743 of file SkPath.cpp.
|
static |
Definition at line 3892 of file SkPath.cpp.
Definition at line 3421 of file SkPath.cpp.
Definition at line 3434 of file SkPath.cpp.
Definition at line 3409 of file SkPath.cpp.
Definition at line 2818 of file SkPath.cpp.
Definition at line 2807 of file SkPath.cpp.
Definition at line 3114 of file SkPath.cpp.
Definition at line 2537 of file SkPath.cpp.
|
static |
Definition at line 2615 of file SkPath.cpp.
Definition at line 2573 of file SkPath.cpp.
Definition at line 2559 of file SkPath.cpp.
Starting at index, and moving forward (incrementing), find the xmin and xmax of the contiguous points that have the same Y.
Definition at line 2591 of file SkPath.cpp.
|
static |
Definition at line 2731 of file SkPath.cpp.
|
static |
Definition at line 73 of file SkPath.cpp.
Definition at line 2875 of file SkPath.cpp.
Path.bounds is defined to be the bounds of all the control points. If we called bounds.join(r) we would skip r if r was empty, which breaks our promise. Hence we have a custom joiner that doesn't look at emptiness
Definition at line 66 of file SkPath.cpp.
Compares a and b; returns true if SkPath::FillType, verb array, SkPoint array, and weights are equivalent.
Definition at line 212 of file SkPath.cpp.
|
static |
Definition at line 55 of file SkPath.cpp.
|
static |
Definition at line 51 of file SkPath.cpp.
Definition at line 512 of file SkPath.cpp.
Definition at line 2205 of file SkPath.cpp.
SkPathVerbAnalysis sk_path_analyze_verbs | ( | const uint8_t | vbs[], |
int | verbCount | ||
) |
Definition at line 3515 of file SkPath.cpp.
Definition at line 1698 of file SkPath.cpp.
|
static |
Definition at line 3039 of file SkPath.cpp.
|
static |
Definition at line 3011 of file SkPath.cpp.
|
static |
Definition at line 3092 of file SkPath.cpp.
|
static |
Definition at line 3066 of file SkPath.cpp.
|
static |
Definition at line 2887 of file SkPath.cpp.
Definition at line 2797 of file SkPath.cpp.
Definition at line 2971 of file SkPath.cpp.
|
static |
Definition at line 2825 of file SkPath.cpp.
|
static |
Definition at line 2751 of file SkPath.cpp.
|
static |
Definition at line 2901 of file SkPath.cpp.
Definition at line 2956 of file SkPath.cpp.