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

Unified Diff: include/core/SkColorPriv.h

Issue 17847010: Commented SSE blend functions and cleaned-up variable naming. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Fixed missing variable rename. Created 7 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/opts/SkBlitRow_opts_SSE2.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkColorPriv.h
diff --git a/include/core/SkColorPriv.h b/include/core/SkColorPriv.h
index 5d2df62cef11db71e283dfbd53a3ca92ac32445a..fe59b1ba935ef94eef42472c25632c499576ebf7 100644
--- a/include/core/SkColorPriv.h
+++ b/include/core/SkColorPriv.h
@@ -838,29 +838,29 @@ static inline SkPMColor SkBlendLCD16Opaque(int srcR, int srcG, int srcB,
SkBlend32(srcB, dstB, maskB));
}
-static inline void SkBlitLCD16Row(SkPMColor dst[], const uint16_t src[],
- SkColor color, int width, SkPMColor) {
- int srcA = SkColorGetA(color);
- int srcR = SkColorGetR(color);
- int srcG = SkColorGetG(color);
- int srcB = SkColorGetB(color);
+static inline void SkBlitLCD16Row(SkPMColor dst[], const uint16_t mask[],
+ SkColor src, int width, SkPMColor) {
+ int srcA = SkColorGetA(src);
+ int srcR = SkColorGetR(src);
+ int srcG = SkColorGetG(src);
+ int srcB = SkColorGetB(src);
srcA = SkAlpha255To256(srcA);
for (int i = 0; i < width; i++) {
- dst[i] = SkBlendLCD16(srcA, srcR, srcG, srcB, dst[i], src[i]);
+ dst[i] = SkBlendLCD16(srcA, srcR, srcG, srcB, dst[i], mask[i]);
}
}
-static inline void SkBlitLCD16OpaqueRow(SkPMColor dst[], const uint16_t src[],
- SkColor color, int width,
+static inline void SkBlitLCD16OpaqueRow(SkPMColor dst[], const uint16_t mask[],
+ SkColor src, int width,
SkPMColor opaqueDst) {
- int srcR = SkColorGetR(color);
- int srcG = SkColorGetG(color);
- int srcB = SkColorGetB(color);
+ int srcR = SkColorGetR(src);
+ int srcG = SkColorGetG(src);
+ int srcB = SkColorGetB(src);
for (int i = 0; i < width; i++) {
- dst[i] = SkBlendLCD16Opaque(srcR, srcG, srcB, dst[i], src[i],
+ dst[i] = SkBlendLCD16Opaque(srcR, srcG, srcB, dst[i], mask[i],
opaqueDst);
}
}
« no previous file with comments | « no previous file | src/opts/SkBlitRow_opts_SSE2.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698