Prefer fullscreen clears on Qualcomm/GL
Adds Qualcomm to the set of GL devices on which we prefer fullscreen
clears.
Renames fullscreenClearIsFree in GrCaps to preferFullscreenClears.
Replaces 'bool canIgnoreClip' on GrRenderTargetContext::clear with an
enum.
Bug: skia:
Change-Id: I5b30298c4d0b092c398b9fea6060f3e2bea91e46
Reviewed-on: https://skia-review.googlesource.com/83060
Reviewed-by: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
diff --git a/tests/RectangleTextureTest.cpp b/tests/RectangleTextureTest.cpp
index d3a7221..8a5cca0 100644
--- a/tests/RectangleTextureTest.cpp
+++ b/tests/RectangleTextureTest.cpp
@@ -28,7 +28,7 @@
for (auto filter : {GrSamplerState::Filter::kNearest,
GrSamplerState::Filter::kBilerp,
GrSamplerState::Filter::kMipMap}) {
- rtContext->clear(nullptr, 0xDDCCBBAA, true);
+ rtContext->clear(nullptr, 0xDDCCBBAA, GrRenderTargetContext::CanClearFullscreen::kYes);
auto fp = GrSimpleTextureEffect::Make(rectProxy, SkMatrix::I(), filter);
GrPaint paint;
paint.setPorterDuffXPFactory(SkBlendMode::kSrc);
@@ -43,7 +43,7 @@
if (GrRenderTargetContext* rtc = rectContext->asRenderTargetContext()) {
// Clear the whole thing.
GrColor color0 = GrColorPackRGBA(0xA, 0xB, 0xC, 0xD);
- rtc->clear(nullptr, color0, false);
+ rtc->clear(nullptr, color0, GrRenderTargetContext::CanClearFullscreen::kNo);
int w = rtc->width();
int h = rtc->height();
@@ -64,7 +64,7 @@
// Clear the the top to a different color.
GrColor color1 = GrColorPackRGBA(0x1, 0x2, 0x3, 0x4);
SkIRect rect = SkIRect::MakeWH(w, h/2);
- rtc->clear(&rect, color1, false);
+ rtc->clear(&rect, color1, GrRenderTargetContext::CanClearFullscreen::kNo);
uint32_t expectedColor1 = 0;
uint8_t* expectedBytes1 = SkTCast<uint8_t*>(&expectedColor1);