From 7ed98df9ba14bdb58e381508eb0505c963a4b6db Mon Sep 17 00:00:00 2001 From: "skia.committer@gmail.com" Date: Thu, 31 Oct 2013 07:01:53 +0000 Subject: [PATCH] Sanitizing source files in Housekeeper-Nightly git-svn-id: http://skia.googlecode.com/svn/trunk@12043 2bbb7eff-a529-9590-31e7-b0007b416f81 --- gm/typeface.cpp | 2 +- include/core/SkPath.h | 2 +- include/gpu/GrUserConfig.h | 2 +- samplecode/SampleFatBits.cpp | 24 ++++++++++++------------ src/core/SkTypeface.cpp | 1 - src/gpu/GrDrawTargetCaps.h | 2 +- 6 files changed, 16 insertions(+), 17 deletions(-) diff --git a/gm/typeface.cpp b/gm/typeface.cpp index 9a8609abb0..9754e9788a 100644 --- a/gm/typeface.cpp +++ b/gm/typeface.cpp @@ -81,7 +81,7 @@ static void getGlyphPositions(const SkPaint& paint, const uint16_t glyphs[], SkAutoSTMalloc<128, SkScalar> widthStorage(count); SkScalar* widths = widthStorage.get(); paint.getTextWidths(glyphs, count * sizeof(uint16_t), widths); - + for (int i = 0; i < count; ++i) { pos[i].set(x, y); x += widths[i]; diff --git a/include/core/SkPath.h b/include/core/SkPath.h index 9b5dc4bf65..02e3423550 100644 --- a/include/core/SkPath.h +++ b/include/core/SkPath.h @@ -913,7 +913,7 @@ public: /** Returns a non-zero, globally unique value corresponding to the set of verbs and points in the path (but not the fill type [except on Android skbug.com/1762]). - Each time the path is modified, a different generation ID will be returned. + Each time the path is modified, a different generation ID will be returned. */ uint32_t getGenerationID() const; diff --git a/include/gpu/GrUserConfig.h b/include/gpu/GrUserConfig.h index e0ef8605e4..81294f11a1 100644 --- a/include/gpu/GrUserConfig.h +++ b/include/gpu/GrUserConfig.h @@ -26,7 +26,7 @@ //#define GR_DEFAULT_RESOURCE_CACHE_MB_LIMIT 96 /** - * This specifies the maximum number of textures the texture cache can hold + * This specifies the maximum number of textures the texture cache can hold * in vram. The value is only a default and can be overridden at runtime. */ //#define GR_DEFAULT_RESOURCE_CACHE_COUNT_LIMIT 2048 diff --git a/samplecode/SampleFatBits.cpp b/samplecode/SampleFatBits.cpp index 10ec8e5f12..cf441cd45c 100644 --- a/samplecode/SampleFatBits.cpp +++ b/samplecode/SampleFatBits.cpp @@ -81,10 +81,10 @@ public: bool getUseGPU() const { return fUseGPU; } void setUseGPU(bool ug) { fUseGPU = ug; } - + bool getTriangle() const { return fUseTriangle; } void setTriangle(bool ut) { fUseTriangle = ut; } - + void toggleRectAsOval() { fRectAsOval = !fRectAsOval; } bool getUseClip() const { return fUseClip; } @@ -343,42 +343,42 @@ void FatBits::drawRect(SkCanvas* canvas, SkPoint pts[2]) { void FatBits::drawTriangleSkeleton(SkCanvas* max, const SkPoint pts[]) { SkPaint paint; this->setupSkeletonPaint(&paint); - + SkPath path; path.moveTo(pts[0]); path.lineTo(pts[1]); path.lineTo(pts[2]); path.close(); - + max->drawPath(path, paint); } void FatBits::drawTriangle(SkCanvas* canvas, SkPoint pts[3]) { SkPaint paint; - + fInverse.mapPoints(pts, 3); - + if (fGrid) { apply_grid(pts, 3); } - + SkPath path; path.moveTo(pts[0]); path.lineTo(pts[1]); path.lineTo(pts[2]); path.close(); - + erase(fMinSurface); this->setupPaint(&paint); paint.setColor(FAT_PIXEL_COLOR); fMinSurface->getCanvas()->drawPath(path, paint); this->copyMinToMax(); - + SkCanvas* max = fMaxSurface->getCanvas(); - + fMatrix.mapPoints(pts, 3); this->drawTriangleSkeleton(max, pts); - + fMaxSurface->draw(canvas, 0, 0, NULL); } @@ -498,7 +498,7 @@ protected: int index = -1; int count = fFB.getTriangle() ? 3 : 2; SkScalar tol = 12; - + for (int i = 0; i < count; ++i) { if (fPts[i].equalsWithinTolerance(pt, tol)) { index = i; diff --git a/src/core/SkTypeface.cpp b/src/core/SkTypeface.cpp index 77a564434c..65718376ef 100644 --- a/src/core/SkTypeface.cpp +++ b/src/core/SkTypeface.cpp @@ -275,4 +275,3 @@ bool SkTypeface::onGetKerningPairAdjustments(const uint16_t glyphs[], int count, int32_t adjustments[]) const { return false; } - diff --git a/src/gpu/GrDrawTargetCaps.h b/src/gpu/GrDrawTargetCaps.h index 3c7fd6ae8c..f6a6dc8a59 100644 --- a/src/gpu/GrDrawTargetCaps.h +++ b/src/gpu/GrDrawTargetCaps.h @@ -39,7 +39,7 @@ public: bool dstReadInShaderSupport() const { return fDstReadInShaderSupport; } // Scratch textures not being reused means that those scratch textures - // that we upload to (i.e., don't have a render target) will not be + // that we upload to (i.e., don't have a render target) will not be // recycled in the texture cache. This is to prevent ghosting by drivers // (in particular for deferred architectures). bool reuseScratchTextures() const { return fReuseScratchTextures; }