diff options
Diffstat (limited to 'src/gpu/GrQuad.h')
-rw-r--r-- | src/gpu/GrQuad.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gpu/GrQuad.h b/src/gpu/GrQuad.h index 3a202c61cb..3ea170c422 100644 --- a/src/gpu/GrQuad.h +++ b/src/gpu/GrQuad.h @@ -13,7 +13,8 @@ #include "SkMatrixPriv.h" /** - * GrQuad is a collection of 4 points which can be used to represent an arbitrary quadrilateral + * GrQuad is a collection of 4 points which can be used to represent an arbitrary quadrilateral. The + * points make a triangle strip with CCW triangles (top-left, bottom-left, top-right, bottom-right). */ class GrQuad { public: @@ -28,7 +29,7 @@ public: } void set(const SkRect& rect) { - fPoints->setRectFan(rect.fLeft, rect.fTop, rect.fRight, rect.fBottom); + fPoints->setRectTriStrip(rect.fLeft, rect.fTop, rect.fRight, rect.fBottom, sizeof(SkPoint)); } void map(const SkMatrix& matrix) { @@ -36,7 +37,7 @@ public: } void setFromMappedRect(const SkRect& rect, const SkMatrix& matrix) { - SkMatrixPriv::SetMappedRectFan(matrix, rect, fPoints); + SkMatrixPriv::SetMappedRectTriStrip(matrix, rect, fPoints); } const GrQuad& operator=(const GrQuad& that) { |