Move GrIPoint16 to SkIPoint16 (and remove GrPoint.h)

R=bsalomon@google.com, reed@google.com

Author: robertphillips@google.com

Review URL: https://codereview.chromium.org/309683002
diff --git a/src/gpu/GrAtlas.cpp b/src/gpu/GrAtlas.cpp
index cc98b92..331f5d9 100644
--- a/src/gpu/GrAtlas.cpp
+++ b/src/gpu/GrAtlas.cpp
@@ -48,13 +48,13 @@
     fBatchUploads = batchUploads;
 }
 
-static inline void adjust_for_offset(GrIPoint16* loc, const GrIPoint16& offset) {
+static inline void adjust_for_offset(SkIPoint16* loc, const SkIPoint16& offset) {
     loc->fX += offset.fX;
     loc->fY += offset.fY;
 }
 
 bool GrPlot::addSubImage(int width, int height, const void* image,
-                          GrIPoint16* loc) {
+                         SkIPoint16* loc) {
     float percentFull = fRects->percentFull();
     if (!fRects->addRect(width, height, loc)) {
         return false;
@@ -203,7 +203,7 @@
 
 GrPlot* GrAtlasMgr::addToAtlas(GrAtlas* atlas,
                                int width, int height, const void* image,
-                               GrIPoint16* loc) {
+                               SkIPoint16* loc) {
     // iterate through entire plot list for this atlas, see if we can find a hole
     // last one was most recently added and probably most empty
     for (int i = atlas->fPlots.count()-1; i >= 0; --i) {
diff --git a/src/gpu/GrAtlas.h b/src/gpu/GrAtlas.h
index b3affe2..47048a8 100644
--- a/src/gpu/GrAtlas.h
+++ b/src/gpu/GrAtlas.h
@@ -10,7 +10,7 @@
 #define GrAtlas_DEFINED
 
 
-#include "GrPoint.h"
+#include "SkPoint.h"
 #include "GrTexture.h"
 #include "GrDrawTarget.h"
 
@@ -35,7 +35,7 @@
 
     GrTexture* texture() const { return fTexture; }
 
-    bool addSubImage(int width, int height, const void*, GrIPoint16*);
+    bool addSubImage(int width, int height, const void*, SkIPoint16*);
 
     GrDrawTarget::DrawToken drawToken() const { return fDrawToken; }
     void setDrawToken(GrDrawTarget::DrawToken draw) { fDrawToken = draw; }
@@ -57,7 +57,7 @@
     GrTexture*              fTexture;
     GrRectanizer*           fRects;
     GrAtlasMgr*             fAtlasMgr;
-    GrIPoint16              fOffset;        // the offset of the plot in the backing texture
+    SkIPoint16              fOffset;        // the offset of the plot in the backing texture
     size_t                  fBytesPerPixel;
     SkIRect                 fDirtyRect;
     bool                    fDirty;
@@ -76,7 +76,7 @@
 
     // add subimage of width, height dimensions to atlas
     // returns the containing GrPlot and location relative to the backing texture
-    GrPlot* addToAtlas(GrAtlas*, int width, int height, const void*, GrIPoint16*);
+    GrPlot* addToAtlas(GrAtlas*, int width, int height, const void*, SkIPoint16*);
 
     // remove reference to this plot
     bool removePlot(GrAtlas* atlas, const GrPlot* plot);
diff --git a/src/gpu/GrDrawState.h b/src/gpu/GrDrawState.h
index de28600..78739ec 100644
--- a/src/gpu/GrDrawState.h
+++ b/src/gpu/GrDrawState.h
@@ -13,7 +13,6 @@
 #include "GrColor.h"
 #include "GrEffectStage.h"
 #include "GrPaint.h"
-#include "GrPoint.h"
 #include "GrRenderTarget.h"
 #include "GrStencil.h"
 #include "GrTemplates.h"
diff --git a/src/gpu/GrInOrderDrawBuffer.cpp b/src/gpu/GrInOrderDrawBuffer.cpp
index 4931f47..801d163 100644
--- a/src/gpu/GrInOrderDrawBuffer.cpp
+++ b/src/gpu/GrInOrderDrawBuffer.cpp
@@ -12,7 +12,6 @@
 #include "GrGpu.h"
 #include "GrIndexBuffer.h"
 #include "GrPath.h"
-#include "GrPoint.h"
 #include "GrRenderTarget.h"
 #include "GrTemplates.h"
 #include "GrTexture.h"
diff --git a/src/gpu/GrPathUtils.cpp b/src/gpu/GrPathUtils.cpp
index 81921e3..8e4eeb0 100644
--- a/src/gpu/GrPathUtils.cpp
+++ b/src/gpu/GrPathUtils.cpp
@@ -7,7 +7,7 @@
 
 #include "GrPathUtils.h"
 
-#include "GrPoint.h"
+#include "GrTypes.h"
 #include "SkGeometry.h"
 
 SkScalar GrPathUtils::scaleToleranceToSrc(SkScalar devTol,
diff --git a/src/gpu/GrPathUtils.h b/src/gpu/GrPathUtils.h
index d6c18ea..c15fd7a 100644
--- a/src/gpu/GrPathUtils.h
+++ b/src/gpu/GrPathUtils.h
@@ -8,7 +8,6 @@
 #ifndef GrPathUtils_DEFINED
 #define GrPathUtils_DEFINED
 
-#include "GrPoint.h"
 #include "SkRect.h"
 #include "SkPath.h"
 #include "SkTArray.h"
diff --git a/src/gpu/GrPlotMgr.h b/src/gpu/GrPlotMgr.h
index 8d55ed0..1441611 100644
--- a/src/gpu/GrPlotMgr.h
+++ b/src/gpu/GrPlotMgr.h
@@ -9,7 +9,6 @@
 #define GrPlotMgr_DEFINED
 
 #include "GrTypes.h"
-#include "GrPoint.h"
 #include "SkTypes.h"
 
 class GrPlotMgr : SkNoncopyable {
@@ -35,7 +34,7 @@
         sk_bzero(fBusy, fDim.fX * fDim.fY);
     }
 
-    bool newPlot(GrIPoint16* loc) {
+    bool newPlot(SkIPoint16* loc) {
         char* busy = fBusy;
         for (int y = 0; y < fDim.fY; y++) {
             for (int x = 0; x < fDim.fX; x++) {
@@ -68,7 +67,7 @@
     };
     char fStorage[STORAGE];
     char* fBusy;
-    GrIPoint16  fDim;
+    SkIPoint16  fDim;
 };
 
 #endif
diff --git a/src/gpu/GrRectanizer.h b/src/gpu/GrRectanizer.h
index 0f9d8fd..dc697c4 100644
--- a/src/gpu/GrRectanizer.h
+++ b/src/gpu/GrRectanizer.h
@@ -8,7 +8,9 @@
 #ifndef GrRectanizer_DEFINED
 #define GrRectanizer_DEFINED
 
-#include "GrPoint.h"
+#include "GrTypes.h"
+
+struct SkIPoint16;
 
 class GrRectanizer {
 public:
@@ -26,7 +28,7 @@
 
     // Attempt to add a rect. Return true on success; false on failure. If
     // successful the position in the atlas is returned in 'loc'.
-    virtual bool addRect(int width, int height, GrIPoint16* loc) = 0;
+    virtual bool addRect(int width, int height, SkIPoint16* loc) = 0;
     virtual float percentFull() const = 0;
 
     /**
diff --git a/src/gpu/GrRectanizer_pow2.cpp b/src/gpu/GrRectanizer_pow2.cpp
index 5da7e04..2d443ca 100644
--- a/src/gpu/GrRectanizer_pow2.cpp
+++ b/src/gpu/GrRectanizer_pow2.cpp
@@ -8,7 +8,7 @@
 
 #include "GrRectanizer_pow2.h"
 
-bool GrRectanizerPow2::addRect(int width, int height, GrIPoint16* loc) {
+bool GrRectanizerPow2::addRect(int width, int height, SkIPoint16* loc) {
     if ((unsigned)width > (unsigned)this->width() ||
         (unsigned)height > (unsigned)this->height()) {
         return false;
diff --git a/src/gpu/GrRectanizer_pow2.h b/src/gpu/GrRectanizer_pow2.h
index e9d9d02..7bf2b86 100644
--- a/src/gpu/GrRectanizer_pow2.h
+++ b/src/gpu/GrRectanizer_pow2.h
@@ -9,6 +9,7 @@
 #define GrRectanizer_pow2_DEFINED
 
 #include "GrRectanizer.h"
+#include "SkPoint.h"
 
 // This Rectanizer quantizes the incoming rects to powers of 2. Each power
 // of two can have, at most, one active row/shelf. Once a row/shelf for
@@ -29,7 +30,7 @@
         sk_bzero(fRows, sizeof(fRows));
     }
 
-    virtual bool addRect(int w, int h, GrIPoint16* loc) SK_OVERRIDE;
+    virtual bool addRect(int w, int h, SkIPoint16* loc) SK_OVERRIDE;
 
     virtual float percentFull() const SK_OVERRIDE {
         return fAreaSoFar / ((float)this->width() * this->height());
@@ -40,7 +41,7 @@
     static const int kMaxExponent = 16;
 
     struct Row {
-        GrIPoint16  fLoc;
+        SkIPoint16  fLoc;
         // fRowHeight is actually known by this struct's position in fRows
         // but it is used to signal if there exists an open row of this height
         int         fRowHeight;
diff --git a/src/gpu/GrRectanizer_skyline.cpp b/src/gpu/GrRectanizer_skyline.cpp
index 200fa83..b759cb2 100755
--- a/src/gpu/GrRectanizer_skyline.cpp
+++ b/src/gpu/GrRectanizer_skyline.cpp
@@ -7,8 +7,9 @@
  */
 
 #include "GrRectanizer_skyline.h"
+#include "SkPoint.h"
 
-bool GrRectanizerSkyline::addRect(int width, int height, GrIPoint16* loc) {
+bool GrRectanizerSkyline::addRect(int width, int height, SkIPoint16* loc) {
     if ((unsigned)width > (unsigned)this->width() ||
         (unsigned)height > (unsigned)this->height()) {
         return false;
diff --git a/src/gpu/GrRectanizer_skyline.h b/src/gpu/GrRectanizer_skyline.h
index 01c433d..2062667 100644
--- a/src/gpu/GrRectanizer_skyline.h
+++ b/src/gpu/GrRectanizer_skyline.h
@@ -30,7 +30,7 @@
         seg->fWidth = this->width();
     }
 
-    virtual bool addRect(int w, int h, GrIPoint16* loc) SK_OVERRIDE;
+    virtual bool addRect(int w, int h, SkIPoint16* loc) SK_OVERRIDE;
 
     virtual float percentFull() const SK_OVERRIDE{
         return fAreaSoFar / ((float)this->width() * this->height());
diff --git a/src/gpu/GrTextContext.h b/src/gpu/GrTextContext.h
index 4cede1d..c139e22 100644
--- a/src/gpu/GrTextContext.h
+++ b/src/gpu/GrTextContext.h
@@ -8,7 +8,6 @@
 #ifndef GrTextContext_DEFINED
 #define GrTextContext_DEFINED
 
-#include "GrPoint.h"
 #include "GrGlyph.h"
 #include "GrPaint.h"
 #include "SkDeviceProperties.h"
diff --git a/src/gpu/GrTextStrike.h b/src/gpu/GrTextStrike.h
index f71b82c..955eb7f 100644
--- a/src/gpu/GrTextStrike.h
+++ b/src/gpu/GrTextStrike.h
@@ -14,7 +14,6 @@
 #include "GrAllocPool.h"
 #include "GrFontScaler.h"
 #include "GrTHashTable.h"
-#include "GrPoint.h"
 #include "GrGlyph.h"
 #include "GrDrawTarget.h"
 #include "GrAtlas.h"