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

Side by Side Diff: src/gpu/GrTextContext.cpp

Issue 23904003: Remove GrRefCnt.h in favor of SkRefCnt.h (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: rm GrRefCnt.h Created 7 years, 3 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/gpu/GrPathRenderer.h ('k') | src/gpu/GrTextStrike.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2010 Google Inc. 2 * Copyright 2010 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 8
9 9
10 #include "GrTextContext.h" 10 #include "GrTextContext.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 60
61 int nGlyphs = fCurrVertex / 4; 61 int nGlyphs = fCurrVertex / 4;
62 fDrawTarget->setIndexSourceToBuffer(fContext->getQuadIndexBuffer()); 62 fDrawTarget->setIndexSourceToBuffer(fContext->getQuadIndexBuffer());
63 fDrawTarget->drawIndexedInstances(kTriangles_GrPrimitiveType, 63 fDrawTarget->drawIndexedInstances(kTriangles_GrPrimitiveType,
64 nGlyphs, 64 nGlyphs,
65 4, 6); 65 4, 6);
66 fDrawTarget->resetVertexSource(); 66 fDrawTarget->resetVertexSource();
67 fVertices = NULL; 67 fVertices = NULL;
68 fMaxVertices = 0; 68 fMaxVertices = 0;
69 fCurrVertex = 0; 69 fCurrVertex = 0;
70 GrSafeSetNull(fCurrTexture); 70 SkSafeSetNull(fCurrTexture);
71 } 71 }
72 } 72 }
73 73
74 GrTextContext::GrTextContext(GrContext* context, const GrPaint& paint) : fPaint( paint) { 74 GrTextContext::GrTextContext(GrContext* context, const GrPaint& paint) : fPaint( paint) {
75 fContext = context; 75 fContext = context;
76 fStrike = NULL; 76 fStrike = NULL;
77 77
78 fCurrTexture = NULL; 78 fCurrTexture = NULL;
79 fCurrVertex = 0; 79 fCurrVertex = 0;
80 80
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 SkFixedToFloat(vx + width), 248 SkFixedToFloat(vx + width),
249 SkFixedToFloat(vy + height), 249 SkFixedToFloat(vy + height),
250 2 * sizeof(SkPoint)); 250 2 * sizeof(SkPoint));
251 fVertices[2*fCurrVertex+1].setRectFan(SkFixedToFloat(texture->normalizeFixed X(tx)), 251 fVertices[2*fCurrVertex+1].setRectFan(SkFixedToFloat(texture->normalizeFixed X(tx)),
252 SkFixedToFloat(texture->normalizeFixed Y(ty)), 252 SkFixedToFloat(texture->normalizeFixed Y(ty)),
253 SkFixedToFloat(texture->normalizeFixed X(tx + width)), 253 SkFixedToFloat(texture->normalizeFixed X(tx + width)),
254 SkFixedToFloat(texture->normalizeFixed Y(ty + height)), 254 SkFixedToFloat(texture->normalizeFixed Y(ty + height)),
255 2 * sizeof(SkPoint)); 255 2 * sizeof(SkPoint));
256 fCurrVertex += 4; 256 fCurrVertex += 4;
257 } 257 }
OLDNEW
« no previous file with comments | « src/gpu/GrPathRenderer.h ('k') | src/gpu/GrTextStrike.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698