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

Side by Side Diff: src/gpu/GrAtlasTextBlob.h

Issue 1515543003: Move 'mustRegenerate' function into GrAtlasTextBlob (Closed) Base URL: https://skia.googlesource.com/skia.git@cleanuptext5
Patch Set: rebase Created 5 years 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
« no previous file with comments | « no previous file | src/gpu/GrAtlasTextBlob.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 2015 Google Inc. 2 * Copyright 2015 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 #ifndef GrAtlasTextBlob_DEFINED 8 #ifndef GrAtlasTextBlob_DEFINED
9 #define GrAtlasTextBlob_DEFINED 9 #define GrAtlasTextBlob_DEFINED
10 10
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 switch (maskFormat) { 293 switch (maskFormat) {
294 case kA8_GrMaskFormat: 294 case kA8_GrMaskFormat:
295 return kGrayTextVASize; 295 return kGrayTextVASize;
296 case kARGB_GrMaskFormat: 296 case kARGB_GrMaskFormat:
297 return kColorTextVASize; 297 return kColorTextVASize;
298 default: 298 default:
299 return kLCDTextVASize; 299 return kLCDTextVASize;
300 } 300 }
301 } 301 }
302 302
303 bool mustRegenerate(SkScalar* outTransX, SkScalar* outTransY, const SkPaint& paint,
304 GrColor color, const SkMaskFilter::BlurRec& blurRec,
305 const SkMatrix& viewMatrix, SkScalar x, SkScalar y);
306
303 // position + local coord 307 // position + local coord
304 static const size_t kColorTextVASize = sizeof(SkPoint) + sizeof(SkIPoint16); 308 static const size_t kColorTextVASize = sizeof(SkPoint) + sizeof(SkIPoint16);
305 static const size_t kGrayTextVASize = sizeof(SkPoint) + sizeof(GrColor) + si zeof(SkIPoint16); 309 static const size_t kGrayTextVASize = sizeof(SkPoint) + sizeof(GrColor) + si zeof(SkIPoint16);
306 static const size_t kLCDTextVASize = kGrayTextVASize; 310 static const size_t kLCDTextVASize = kGrayTextVASize;
307 static const int kVerticesPerGlyph = 4; 311 static const int kVerticesPerGlyph = 4;
308 312
309 #ifdef CACHE_SANITY_CHECK 313 #ifdef CACHE_SANITY_CHECK
310 static void AssertEqual(const GrAtlasTextBlob&, const GrAtlasTextBlob&); 314 static void AssertEqual(const GrAtlasTextBlob&, const GrAtlasTextBlob&);
311 size_t fSize; 315 size_t fSize;
312 #endif 316 #endif
313 }; 317 };
314 318
315 #endif 319 #endif
OLDNEW
« no previous file with comments | « no previous file | src/gpu/GrAtlasTextBlob.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698