Remove legacy guard flags
Bug: skia: Change-Id: I3b526f2caec6766faea72cdc89550f50e17c71d2 Reviewed-on: https://skia-review.googlesource.com/125746 Reviewed-by: Cary Clark <caryclark@google.com> Reviewed-by: Florin Malita <fmalita@chromium.org> Commit-Queue: Yuqian Li <liyuqian@google.com>
This commit is contained in:
parent
884bce709a
commit
737b9a9d48
@ -13,12 +13,7 @@
|
||||
std::atomic<bool> gSkUseAnalyticAA{true};
|
||||
std::atomic<bool> gSkForceAnalyticAA{false};
|
||||
|
||||
#if defined(SK_SUPPORT_LEGACY_DELTA_AA)
|
||||
std::atomic<bool> gSkUseDeltaAA{false};
|
||||
#else
|
||||
std::atomic<bool> gSkUseDeltaAA{true};
|
||||
#endif
|
||||
|
||||
std::atomic<bool> gSkUseDeltaAA{true};
|
||||
std::atomic<bool> gSkForceDeltaAA{false};
|
||||
|
||||
static inline void blitrect(SkBlitter* blitter, const SkIRect& r) {
|
||||
|
@ -1287,12 +1287,7 @@ static inline bool edges_too_close(SkAnalyticEdge* prev, SkAnalyticEdge* next, S
|
||||
// even if prev->fX and next->fX are close and within one pixel (e.g., prev->fX == 0.1,
|
||||
// next->fX == 0.9). Adding SLACK = 1 to the formula would guarantee it to be true if two
|
||||
// edges prev and next are within one pixel.
|
||||
constexpr SkFixed SLACK =
|
||||
#ifdef SK_SUPPORT_LEGACY_AA_BEHAVIOR
|
||||
0;
|
||||
#else
|
||||
SK_Fixed1;
|
||||
#endif
|
||||
constexpr SkFixed SLACK = SK_Fixed1;
|
||||
|
||||
// Note that even if the following test failed, the edges might still be very close to each
|
||||
// other at some point within the current pixel row because of prev->fDX and next->fDX.
|
||||
@ -1480,17 +1475,10 @@ static void aaa_walk_edges(SkAnalyticEdge* prevHead, SkAnalyticEdge* nextTail,
|
||||
} else {
|
||||
SkFixed rite = currE->fX;
|
||||
currE->goY(nextY, yShift);
|
||||
#ifdef SK_SUPPORT_LEGACY_DELTA_AA
|
||||
leftE->fX = SkTMax(leftClip, leftE->fX);
|
||||
rite = SkTMin(rightClip, rite);
|
||||
currE->fX = SkTMin(rightClip, currE->fX);
|
||||
blit_trapezoid_row(blitter, y >> 16, left, rite, leftE->fX, currE->fX,
|
||||
#else
|
||||
SkFixed nextLeft = SkTMax(leftClip, leftE->fX);
|
||||
rite = SkTMin(rightClip, rite);
|
||||
SkFixed nextRite = SkTMin(rightClip, currE->fX);
|
||||
blit_trapezoid_row(blitter, y >> 16, left, rite, nextLeft, nextRite,
|
||||
#endif
|
||||
leftDY, currE->fDY, fullAlpha, maskRow, isUsingMask,
|
||||
noRealBlitter || (fullAlpha == 0xFF && (
|
||||
edges_too_close(prevRite, left, leftE->fX) ||
|
||||
|
@ -4373,7 +4373,6 @@ static void test_fuzz_crbug_662730(skiatest::Reporter* reporter) {
|
||||
test_draw_AA_path(100, 100, path);
|
||||
}
|
||||
|
||||
#if !defined(SK_SUPPORT_LEGACY_DELTA_AA)
|
||||
static void test_skbug_6947() {
|
||||
SkPath path;
|
||||
SkPoint points[] =
|
||||
@ -4433,8 +4432,6 @@ static void test_skbug_7051() {
|
||||
test_draw_AA_path(100, 100, path);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
static void test_interp(skiatest::Reporter* reporter) {
|
||||
SkPath p1, p2, out;
|
||||
REPORTER_ASSERT(reporter, p1.isInterpolatable(p2));
|
||||
|
@ -91,7 +91,7 @@ DEFINE_bool(forceAnalyticAA, false, "Force analytic anti-aliasing even if the pa
|
||||
"whether it's concave or convex, we consider a path complicated"
|
||||
"if its number of points is comparable to its resolution.");
|
||||
|
||||
#if defined(SK_SUPPORT_LEGACY_DELTA_AA) || (defined(_MSC_VER) && !defined(__clang__))
|
||||
#if (defined(_MSC_VER) && !defined(__clang__))
|
||||
constexpr bool kDefaultDeltaAA = false;
|
||||
#else
|
||||
constexpr bool kDefaultDeltaAA = true;
|
||||
|
Loading…
Reference in New Issue
Block a user