Lines Matching defs:index

480 SkPoint SkPath::getPoint(int index) const {
481 if ((unsigned)index < (unsigned)fPathRef->countPoints()) {
482 return fPathRef->atPoint(index);
527 void SkPath::setPt(int index, SkScalar x, SkScalar y) {
531 if (count <= index) {
535 ed.atPoint(index)->set(x, y);
622 // remember our index
1017 for (int index = 1; index < count; ++index) {
1018 if (first != pts[index]) {
1039 // legacy start index: 1
2477 static int find_diff_pt(const SkPoint pts[], int index, int n, int inc) {
2478 int i = index;
2481 if (i == index) { // we wrapped around, so abort
2484 if (pts[index] != pts[i]) { // found a different point, success!
2492 * Starting at index, and moving forward (incrementing), find the xmin and
2495 static int find_min_max_x_at_y(const SkPoint pts[], int index, int n,
2497 const SkScalar y = pts[index].fY;
2498 SkScalar min = pts[index].fX;
2500 int minIndex = index;
2501 int maxIndex = index;
2502 for (int i = index + 1; i < n; ++i) {
2558 int index = find_max_y(pts, n);
2559 if (pts[index].fY < ymax) {
2565 if (pts[(index + 1) % n].fY == pts[index].fY) {
2567 int minIndex = find_min_max_x_at_y(pts, index, n, &maxIndex);
2571 SkASSERT(pts[minIndex].fY == pts[index].fY);
2572 SkASSERT(pts[maxIndex].fY == pts[index].fY);
2579 // Find a next and prev index to use for the cross-product test,
2580 // but we try to find pts that form non-zero vectors from pts[index]
2588 int prev = find_diff_pt(pts, index, n, n - 1);
2589 if (prev == index) {
2593 int next = find_diff_pt(pts, index, n, 1);
2594 SkASSERT(next != index);
2595 cross = cross_prod(pts[prev], pts[index], pts[next]);
2599 if (0 == cross && pts[prev].fY == pts[index].fY && pts[next].fY == pts[index].fY) {
2601 cross = pts[index].fX - pts[next].fX;
2607 ymax = pts[index].fY;
2959 for (int index = 0; index < n; ++index) {
2960 SkScalar t = roots[index];
2983 for (int index = 0; index < n; ++index) {
2984 SkScalar t = roots[index];
3107 for (int index = 0; index < last; ++index) {
3108 const SkVector& test = tangents[index];
3113 tangents.removeShuffle(index);
3195 // Set sortFlags so that it has the low bit set if pt index 0 is on right edge and second bit