aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar skia.committer@gmail.com <skia.committer@gmail.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-03-06 07:01:46 +0000
committerGravatar skia.committer@gmail.com <skia.committer@gmail.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2013-03-06 07:01:46 +0000
commit64334352cc3f29f52dfa07225d65eb218d2fd830 (patch)
treeac9ddb2c2eaf3995aaf806feecfb0f8c99fc97dc
parent64494e99af8f834a0343a4d1ee0aa4c2860e13a3 (diff)
Sanitizing source files in Skia_Periodic_House_Keeping
git-svn-id: http://skia.googlecode.com/svn/trunk@8003 2bbb7eff-a529-9590-31e7-b0007b416f81
-rw-r--r--experimental/Intersection/CubicIntersection.cpp10
-rw-r--r--experimental/Intersection/EdgeWalker_TestUtility.cpp2
-rw-r--r--experimental/Intersection/Simplify.cpp4
-rw-r--r--include/core/SkStream.h1
-rw-r--r--include/core/SkXfermode.h2
-rw-r--r--src/core/SkFontStream.cpp4
-rw-r--r--src/core/SkXfermode.cpp10
-rw-r--r--src/pdf/SkPDFGraphicState.cpp2
-rw-r--r--src/ports/SkFontHost_fontconfig.cpp2
9 files changed, 18 insertions, 19 deletions
diff --git a/experimental/Intersection/CubicIntersection.cpp b/experimental/Intersection/CubicIntersection.cpp
index 84692bc67f..eb8a5d67b1 100644
--- a/experimental/Intersection/CubicIntersection.cpp
+++ b/experimental/Intersection/CubicIntersection.cpp
@@ -166,7 +166,7 @@ static bool intersect3(const Cubic& cubic1, double t1s, double t1e, const Cubic&
&& to2 - offset <= tLimits2[1][1] && tLimits2[1][0] <= to2 + offset);
SkDebugf("%.*s %s 1 c1Bottom=%1.9g c1Top=%1.9g c2Bottom=%1.9g c2Top=%1.9g"
" 1-o=%1.9g 1+o=%1.9g 2-o=%1.9g 2+o=%1.9g offset=%1.9g\n",
- i.depth()*2, tab, __FUNCTION__, c1Bottom, c1Top, 0., 1.,
+ i.depth()*2, tab, __FUNCTION__, c1Bottom, c1Top, 0., 1.,
to1 - offset, to1 + offset, to2 - offset, to2 + offset, offset);
SkDebugf("%.*s %s 1 to1=%1.9g to2=%1.9g c1Min=%1.9g c1Max=%1.9g c2Min=%1.9g"
" c2Max=%1.9g\n", i.depth()*2, tab, __FUNCTION__, to1, to2, c1Min, c1Max, c2Min, c2Max);
@@ -206,7 +206,7 @@ static bool intersect3(const Cubic& cubic1, double t1s, double t1e, const Cubic&
&& to2 - offset <= tLimits2[1][1] && tLimits2[1][0] <= to2 + offset);
SkDebugf("%.*s %s 2 c1Bottom=%1.9g c1Top=%1.9g c2Bottom=%1.9g c2Top=%1.9g"
" 1-o=%1.9g 1+o=%1.9g 2-o=%1.9g 2+o=%1.9g offset=%1.9g\n",
- i.depth()*2, tab, __FUNCTION__, 0., 1., c2Bottom, c2Top,
+ i.depth()*2, tab, __FUNCTION__, 0., 1., c2Bottom, c2Top,
to1 - offset, to1 + offset, to2 - offset, to2 + offset, offset);
SkDebugf("%.*s %s 2 to1=%1.9g to2=%1.9g c1Min=%1.9g c1Max=%1.9g c2Min=%1.9g"
" c2Max=%1.9g\n", i.depth()*2, tab, __FUNCTION__, to1, to2, c1Min, c1Max, c2Min, c2Max);
@@ -230,7 +230,7 @@ static bool intersect3(const Cubic& cubic1, double t1s, double t1e, const Cubic&
&& to2 - offset <= tLimits2[1][1] && tLimits2[1][0] <= to2 + offset);
SkDebugf("%.*s %s 3 c1Bottom=%1.9g c1Top=%1.9g c2Bottom=%1.9g c2Top=%1.9g"
" 1-o=%1.9g 1+o=%1.9g 2-o=%1.9g 2+o=%1.9g offset=%1.9g\n",
- i.depth()*2, tab, __FUNCTION__, 0., 1., c2Bottom, c2Top,
+ i.depth()*2, tab, __FUNCTION__, 0., 1., c2Bottom, c2Top,
to1 - offset, to1 + offset, to2 - offset, to2 + offset, offset);
SkDebugf("%.*s %s 3 to1=%1.9g to2=%1.9g c1Min=%1.9g c1Max=%1.9g c2Min=%1.9g"
" c2Max=%1.9g\n", i.depth()*2, tab, __FUNCTION__, to1, to2, c1Min, c1Max, c2Min, c2Max);
@@ -241,7 +241,7 @@ static bool intersect3(const Cubic& cubic1, double t1s, double t1e, const Cubic&
i.used() > 0 ? i.fT[0][i.used() - 1] : -1);
#endif
}
-#else
+#else
double c1Bottom = tIdx == 0 ? 0 :
(t1Start + (t1 - t1Start) * locals.fT[0][tIdx - 1] + to1) / 2;
double c1Min = SkTMax(c1Bottom, to1 - offset);
@@ -275,7 +275,7 @@ static bool intersect3(const Cubic& cubic1, double t1s, double t1e, const Cubic&
&& to2 - offset <= 0.211327209 && 0.211327209 <= to2 + offset);
SkDebugf("%s c1Bottom=%1.9g c1Top=%1.9g c2Bottom=%1.9g c2Top=%1.9g"
" 1-o=%1.9g 1+o=%1.9g 2-o=%1.9g 2+o=%1.9g offset=%1.9g\n",
- __FUNCTION__, c1Bottom, c1Top, c2Bottom, c2Top,
+ __FUNCTION__, c1Bottom, c1Top, c2Bottom, c2Top,
to1 - offset, to1 + offset, to2 - offset, to2 + offset, offset);
SkDebugf("%s to1=%1.9g to2=%1.9g c1Min=%1.9g c1Max=%1.9g c2Min=%1.9g"
" c2Max=%1.9g\n", __FUNCTION__, to1, to2, c1Min, c1Max, c2Min, c2Max);
diff --git a/experimental/Intersection/EdgeWalker_TestUtility.cpp b/experimental/Intersection/EdgeWalker_TestUtility.cpp
index b0584c303d..163bd51917 100644
--- a/experimental/Intersection/EdgeWalker_TestUtility.cpp
+++ b/experimental/Intersection/EdgeWalker_TestUtility.cpp
@@ -4,7 +4,7 @@
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
-
+
#include "DataTypes.h"
#include "EdgeWalker_Test.h"
#include "Intersection_Tests.h"
diff --git a/experimental/Intersection/Simplify.cpp b/experimental/Intersection/Simplify.cpp
index 529550614d..4684cda7ef 100644
--- a/experimental/Intersection/Simplify.cpp
+++ b/experimental/Intersection/Simplify.cpp
@@ -4218,7 +4218,7 @@ the same winding is shared by both.
SkASSERT(&span == &span.fOther->fTs[span.fOtherIndex].fOther->
fTs[span.fOther->fTs[span.fOtherIndex].fOtherIndex]);
SkDebugf(") t=%1.9g [%d] (%1.9g,%1.9g) tEnd=%1.9g newWindSum=%d windSum=",
- span.fT, span.fOther->fTs[span.fOtherIndex].fOtherIndex, pt.fX, pt.fY,
+ span.fT, span.fOther->fTs[span.fOtherIndex].fOtherIndex, pt.fX, pt.fY,
(&span)[1].fT, winding);
if (span.fWindSum == SK_MinS32) {
SkDebugf("?");
@@ -4304,7 +4304,7 @@ the same winding is shared by both.
}
}
}
- SkDebugf("%s [%d] %s", __FUNCTION__, index,
+ SkDebugf("%s [%d] %s", __FUNCTION__, index,
angle.unsortable() ? "*** UNSORTABLE *** " : "");
#if COMPACT_DEBUG_SORT
SkDebugf("id=%d %s start=%d (%1.9g,%,1.9g) end=%d (%1.9g,%,1.9g)",
diff --git a/include/core/SkStream.h b/include/core/SkStream.h
index f525cf851c..7e3c1a370b 100644
--- a/include/core/SkStream.h
+++ b/include/core/SkStream.h
@@ -380,4 +380,3 @@ private:
typedef SkFILEStream SkURLStream;
#endif
-
diff --git a/include/core/SkXfermode.h b/include/core/SkXfermode.h
index 54946fdf87..930403f8da 100644
--- a/include/core/SkXfermode.h
+++ b/include/core/SkXfermode.h
@@ -105,7 +105,7 @@ public:
// all above modes can be expressed as pair of src/dst Coeffs
kCoeffModesCnt,
- // Following blend modes are defined in the CSS Compositing standard:
+ // Following blend modes are defined in the CSS Compositing standard:
// https://dvcs.w3.org/hg/FXTF/rawfile/tip/compositing/index.html#blending
kScreen_Mode = kCoeffModesCnt,
kOverlay_Mode,
diff --git a/src/core/SkFontStream.cpp b/src/core/SkFontStream.cpp
index ccdc1c7dd1..ab16c710ee 100644
--- a/src/core/SkFontStream.cpp
+++ b/src/core/SkFontStream.cpp
@@ -61,7 +61,7 @@ static int count_tables(SkStream* stream, int ttcIndex, size_t* offsetToDir) {
if ((unsigned)ttcIndex >= count) {
return 0;
}
-
+
if (ttcIndex > 0) { // need to read more of the shared header
stream->rewind();
size_t amount = sizeof(shared) + ttcIndex * sizeof(uint32_t);
@@ -138,7 +138,7 @@ int SkFontStream::CountTTCEntries(SkStream* stream) {
return SkEndian_SwapBE32(shared.fCollection.fNumOffsets);
} else {
return 0;
- }
+ }
}
int SkFontStream::GetTableTags(SkStream* stream, int ttcIndex,
diff --git a/src/core/SkXfermode.cpp b/src/core/SkXfermode.cpp
index ddcccec869..ba45ac3329 100644
--- a/src/core/SkXfermode.cpp
+++ b/src/core/SkXfermode.cpp
@@ -443,8 +443,8 @@ static inline int Lum(int r, int g, int b)
static inline int min2(int a, int b) { return a < b ? a : b; }
static inline int max2(int a, int b) { return a > b ? a : b; }
-#define minimum(a, b, c) min2(min2(a, b), c)
-#define maximum(a, b, c) max2(max2(a, b), c)
+#define minimum(a, b, c) min2(min2(a, b), c)
+#define maximum(a, b, c) max2(max2(a, b), c)
static inline int Sat(int r, int g, int b) {
return maximum(r, g, b) - minimum(r, g, b);
@@ -549,7 +549,7 @@ static SkPMColor hue_modeproc(SkPMColor src, SkPMColor dst) {
// kSaturation_Mode
// B(Cb, Cs) = SetLum(SetSat(Cb, Sat(Cs)), Lum(Cb))
-// Create a color with the saturation of the source color and the hue and luminosity of the backdrop color.
+// Create a color with the saturation of the source color and the hue and luminosity of the backdrop color.
static SkPMColor saturation_modeproc(SkPMColor src, SkPMColor dst) {
int sr = SkGetPackedR32(src);
int sg = SkGetPackedG32(src);
@@ -587,7 +587,7 @@ static SkPMColor saturation_modeproc(SkPMColor src, SkPMColor dst) {
// kColor_Mode
// B(Cb, Cs) = SetLum(Cs, Lum(Cb))
-// Create a color with the hue and saturation of the source color and the luminosity of the backdrop color.
+// Create a color with the hue and saturation of the source color and the luminosity of the backdrop color.
static SkPMColor color_modeproc(SkPMColor src, SkPMColor dst) {
int sr = SkGetPackedR32(src);
int sg = SkGetPackedG32(src);
@@ -623,7 +623,7 @@ static SkPMColor color_modeproc(SkPMColor src, SkPMColor dst) {
// kLuminosity_Mode
// B(Cb, Cs) = SetLum(Cb, Lum(Cs))
-// Create a color with the luminosity of the source color and the hue and saturation of the backdrop color.
+// Create a color with the luminosity of the source color and the hue and saturation of the backdrop color.
static SkPMColor luminosity_modeproc(SkPMColor src, SkPMColor dst) {
int sr = SkGetPackedR32(src);
int sg = SkGetPackedG32(src);
diff --git a/src/pdf/SkPDFGraphicState.cpp b/src/pdf/SkPDFGraphicState.cpp
index 580d7e9e1e..6ea535fd9b 100644
--- a/src/pdf/SkPDFGraphicState.cpp
+++ b/src/pdf/SkPDFGraphicState.cpp
@@ -15,7 +15,7 @@ static const char* blend_mode_from_xfermode(SkXfermode::Mode mode) {
switch (mode) {
case SkXfermode::kSrcOver_Mode: return "Normal";
// kModulate is not really like multipy but similar most of the time.
- case SkXfermode::kModulate_Mode:
+ case SkXfermode::kModulate_Mode:
case SkXfermode::kMultiply_Mode: return "Multiply";
case SkXfermode::kScreen_Mode: return "Screen";
case SkXfermode::kOverlay_Mode: return "Overlay";
diff --git a/src/ports/SkFontHost_fontconfig.cpp b/src/ports/SkFontHost_fontconfig.cpp
index 7f6997a745..786b2a29dc 100644
--- a/src/ports/SkFontHost_fontconfig.cpp
+++ b/src/ports/SkFontHost_fontconfig.cpp
@@ -271,7 +271,7 @@ SkStream* SkFontHost::OpenStream(uint32_t id) {
if (NULL == face) {
return NULL;
}
-
+
int ttcIndex;
// We should return ttcIndex from this call.
return open_stream(face, &ttcIndex);