Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(238)

Unified Diff: src/gpu/GrDrawTarget.cpp

Issue 216503004: SK_SUPPORT_LEGACY_GRTYPES to hide duplicate types from SkTypes.h (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/gpu/GrDrawTarget.cpp
diff --git a/src/gpu/GrDrawTarget.cpp b/src/gpu/GrDrawTarget.cpp
index 8d3ded2d65c82f33307041a013787c048b562365..a9e7b890ca5d9a5d4f3c2e4c912f503013f2c01d 100644
--- a/src/gpu/GrDrawTarget.cpp
+++ b/src/gpu/GrDrawTarget.cpp
@@ -651,7 +651,7 @@ void GrDrawTarget::drawIndexedInstances(GrPrimitiveType type,
}
while (instanceCount) {
- info.fInstanceCount = GrMin(instanceCount, maxInstancesPerDraw);
+ info.fInstanceCount = SkTMin(instanceCount, maxInstancesPerDraw);
info.fVertexCount = info.fInstanceCount * verticesPerInstance;
info.fIndexCount = info.fInstanceCount * indicesPerInstance;
@@ -674,7 +674,7 @@ namespace {
// position + (optional) texture coord
extern const GrVertexAttrib gBWRectPosUVAttribs[] = {
{kVec2f_GrVertexAttribType, 0, kPosition_GrVertexAttribBinding},
- {kVec2f_GrVertexAttribType, sizeof(GrPoint), kLocalCoord_GrVertexAttribBinding}
+ {kVec2f_GrVertexAttribType, sizeof(SkPoint), kLocalCoord_GrVertexAttribBinding}
};
void set_vertex_attributes(GrDrawState* drawState, bool hasUVs) {
@@ -708,8 +708,8 @@ void GrDrawTarget::onDrawRect(const SkRect& rect,
size_t vsize = this->drawState()->getVertexSize();
geo.positions()->setRectFan(rect.fLeft, rect.fTop, rect.fRight, rect.fBottom, vsize);
if (NULL != localRect) {
- GrPoint* coords = GrTCast<GrPoint*>(GrTCast<intptr_t>(geo.vertices()) +
- sizeof(GrPoint));
+ SkPoint* coords = GrTCast<SkPoint*>(GrTCast<intptr_t>(geo.vertices()) +
+ sizeof(SkPoint));
coords->setRectFan(localRect->fLeft, localRect->fTop,
localRect->fRight, localRect->fBottom,
vsize);

Powered by Google App Engine
This is Rietveld 408576698