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

Side by Side Diff: include/core/SkPaint.h

Issue 1329853005: Make SkGraphics::Term a no-op, stop calling it. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: remove deprecation Created 5 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
« no previous file with comments | « include/core/SkGraphics.h ('k') | include/views/SkEvent.h » ('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 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
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 SkPaint_DEFINED 8 #ifndef SkPaint_DEFINED
9 #define SkPaint_DEFINED 9 #define SkPaint_DEFINED
10 10
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after
282 */ 282 */
283 void setDevKernText(bool devKernText); 283 void setDevKernText(bool devKernText);
284 284
285 /** 285 /**
286 * Return the filter level. This affects the quality (and performance) of 286 * Return the filter level. This affects the quality (and performance) of
287 * drawing scaled images. 287 * drawing scaled images.
288 */ 288 */
289 SkFilterQuality getFilterQuality() const { 289 SkFilterQuality getFilterQuality() const {
290 return (SkFilterQuality)fBitfields.fFilterQuality; 290 return (SkFilterQuality)fBitfields.fFilterQuality;
291 } 291 }
292 292
293 /** 293 /**
294 * Set the filter quality. This affects the quality (and performance) of 294 * Set the filter quality. This affects the quality (and performance) of
295 * drawing scaled images. 295 * drawing scaled images.
296 */ 296 */
297 void setFilterQuality(SkFilterQuality quality); 297 void setFilterQuality(SkFilterQuality quality);
298 298
299 /** Styles apply to rect, oval, path, and text. 299 /** Styles apply to rect, oval, path, and text.
300 Bitmaps are always drawn in "fill", and lines are always drawn in 300 Bitmaps are always drawn in "fill", and lines are always drawn in
301 "stroke". 301 "stroke".
302 302
(...skipping 736 matching lines...) Expand 10 before | Expand all | Expand 10 after
1039 void (*proc)(SkTypeface*, const SkDescriptor*, void*), 1039 void (*proc)(SkTypeface*, const SkDescriptor*, void*),
1040 void* context, bool ignoreGamma) const; 1040 void* context, bool ignoreGamma) const;
1041 1041
1042 /* 1042 /*
1043 * The luminance color is used to determine which Gamma Canonical color to m ap to. This is 1043 * The luminance color is used to determine which Gamma Canonical color to m ap to. This is
1044 * really only used by backends which want to cache glyph masks, and need so me way to know if 1044 * really only used by backends which want to cache glyph masks, and need so me way to know if
1045 * they need to generate new masks based off a given color. 1045 * they need to generate new masks based off a given color.
1046 */ 1046 */
1047 SkColor computeLuminanceColor() const; 1047 SkColor computeLuminanceColor() const;
1048 1048
1049 static void Term();
1050
1051 enum { 1049 enum {
1052 /* This is the size we use when we ask for a glyph's path. We then 1050 /* This is the size we use when we ask for a glyph's path. We then
1053 * post-transform it as we draw to match the request. 1051 * post-transform it as we draw to match the request.
1054 * This is done to try to re-use cache entries for the path. 1052 * This is done to try to re-use cache entries for the path.
1055 * 1053 *
1056 * This value is somewhat arbitrary. In theory, it could be 1, since 1054 * This value is somewhat arbitrary. In theory, it could be 1, since
1057 * we store paths as floats. However, we get the path from the font 1055 * we store paths as floats. However, we get the path from the font
1058 * scaler, and it may represent its paths as fixed-point (or 26.6), 1056 * scaler, and it may represent its paths as fixed-point (or 26.6),
1059 * so we shouldn't ask for something too big (might overflow 16.16) 1057 * so we shouldn't ask for something too big (might overflow 16.16)
1060 * or too small (underflow 26.6). 1058 * or too small (underflow 26.6).
(...skipping 22 matching lines...) Expand all
1083 static SkScalar MaxCacheSize2() { 1081 static SkScalar MaxCacheSize2() {
1084 static const SkScalar kMaxSize = SkIntToScalar(kMaxSizeForGlyphCache); 1082 static const SkScalar kMaxSize = SkIntToScalar(kMaxSizeForGlyphCache);
1085 static const SkScalar kMag2Max = kMaxSize * kMaxSize; 1083 static const SkScalar kMag2Max = kMaxSize * kMaxSize;
1086 return kMag2Max; 1084 return kMag2Max;
1087 } 1085 }
1088 1086
1089 friend class SkAutoGlyphCache; 1087 friend class SkAutoGlyphCache;
1090 friend class SkAutoGlyphCacheNoGamma; 1088 friend class SkAutoGlyphCacheNoGamma;
1091 friend class SkCanvas; 1089 friend class SkCanvas;
1092 friend class SkDraw; 1090 friend class SkDraw;
1093 friend class SkGraphics; // So Term() can be called.
1094 friend class SkPDFDevice; 1091 friend class SkPDFDevice;
1095 friend class GrBitmapTextContext; 1092 friend class GrBitmapTextContext;
1096 friend class GrAtlasTextContext; 1093 friend class GrAtlasTextContext;
1097 friend class GrDistanceFieldTextContext; 1094 friend class GrDistanceFieldTextContext;
1098 friend class GrStencilAndCoverTextContext; 1095 friend class GrStencilAndCoverTextContext;
1099 friend class GrPathRendering; 1096 friend class GrPathRendering;
1100 friend class GrTextContext; 1097 friend class GrTextContext;
1101 friend class GrGLPathRendering; 1098 friend class GrGLPathRendering;
1102 friend class SkScalerContext; 1099 friend class SkScalerContext;
1103 friend class SkTextToPathIter; 1100 friend class SkTextToPathIter;
1104 friend class SkCanonicalizePaint; 1101 friend class SkCanonicalizePaint;
1105 }; 1102 };
1106 1103
1107 #endif 1104 #endif
OLDNEW
« no previous file with comments | « include/core/SkGraphics.h ('k') | include/views/SkEvent.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698