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

Unified Diff: src/core/SkBitmapProcState.cpp

Issue 1658563002: Remove SK_SUPPORT_LEGACY_SAMPLER_BIAS (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Created 4 years, 11 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkBitmapProcState.cpp
diff --git a/src/core/SkBitmapProcState.cpp b/src/core/SkBitmapProcState.cpp
index d9d47a270f5fa0f4b50876552b645a8a65300845..35d6cb4aecdaf6829131b3d99ec23f89c57dd755 100644
--- a/src/core/SkBitmapProcState.cpp
+++ b/src/core/SkBitmapProcState.cpp
@@ -587,12 +587,7 @@ static void DoNothing_shaderproc(const void*, int x, int y,
bool SkBitmapProcState::setupForTranslate() {
SkPoint pt;
-
-#ifdef SK_SUPPORT_LEGACY_SAMPLER_BIAS
- fInvProc(fInvMatrix, SK_ScalarHalf, SK_ScalarHalf, &pt);
-#else
const SkBitmapProcStateAutoMapper mapper(*this, 0, 0, &pt);
-#endif
/*
* if the translate is larger than our ints, we can get random results, or
@@ -604,16 +599,11 @@ bool SkBitmapProcState::setupForTranslate() {
return false;
}
-#ifdef SK_SUPPORT_LEGACY_SAMPLER_BIAS
- fFilterOneX = SkScalarFloorToInt(pt.fX);
- fFilterOneY = SkScalarFloorToInt(pt.fY);
-#else
// Since we know we're not filtered, we re-purpose these fields allow
// us to go from device -> src coordinates w/ just an integer add,
// rather than running through the inverse-matrix
fFilterOneX = SkFractionalIntToInt(mapper.x());
fFilterOneY = SkFractionalIntToInt(mapper.y());
-#endif
return true;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698