From bea0150d83d5b840a236cc2c8444371b121c99fe Mon Sep 17 00:00:00 2001 From: bsalomon Date: Thu, 16 Jul 2015 10:00:28 -0700 Subject: [PATCH] Revert of Remove rt flags that are not necessary (patchset #1 id:1 of https://codereview.chromium.org/1226123012/) Reason for revert: breaks tests, e.g. https://build.chromium.org/p/client.skia.android/builders/Test-Android-GCC-Nexus9-GPU-TegraK1-Arm64-Release/builds/752/steps/dm/logs/stdio Original issue's description: > Remove rt flags that are not necessary > > Committed: https://skia.googlesource.com/skia/+/b6b0a6ef179f4143c94ba7e0e1be6e7ce4b0a23a TBR=joshualitt@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1234503004 --- tests/FloatingPointTextureTest.cpp | 1 + tests/GLProgramsTest.cpp | 1 + tests/SurfaceTest.cpp | 1 + 3 files changed, 3 insertions(+) diff --git a/tests/FloatingPointTextureTest.cpp b/tests/FloatingPointTextureTest.cpp index d891b47..1adc744 100644 --- a/tests/FloatingPointTextureTest.cpp +++ b/tests/FloatingPointTextureTest.cpp @@ -42,6 +42,7 @@ void runFPTest(skiatest::Reporter* reporter, GrContextFactory* factory, for (int origin = 0; origin < 2; ++origin) { for (int glCtxType = 0; glCtxType < GrContextFactory::kGLContextTypeCnt; ++glCtxType) { GrSurfaceDesc desc; + desc.fFlags = kRenderTarget_GrSurfaceFlag; desc.fWidth = DEV_W; desc.fHeight = DEV_H; desc.fConfig = config; diff --git a/tests/GLProgramsTest.cpp b/tests/GLProgramsTest.cpp index 019ab38..d21ae5d 100644 --- a/tests/GLProgramsTest.cpp +++ b/tests/GLProgramsTest.cpp @@ -200,6 +200,7 @@ static void set_random_stencil(GrPipelineBuilder* pipelineBuilder, SkRandom* ran bool GrDrawTarget::programUnitTest(GrContext* context, int maxStages) { // setup dummy textures GrSurfaceDesc dummyDesc; + dummyDesc.fFlags = kRenderTarget_GrSurfaceFlag; dummyDesc.fConfig = kSkia8888_GrPixelConfig; dummyDesc.fWidth = 34; dummyDesc.fHeight = 18; diff --git a/tests/SurfaceTest.cpp b/tests/SurfaceTest.cpp index a78af9b..b1e233f 100644 --- a/tests/SurfaceTest.cpp +++ b/tests/SurfaceTest.cpp @@ -952,6 +952,7 @@ DEF_GPUTEST(SkImage_NewFromTexture, reporter, factory) { sk_memset32(storage, expected0, w * h); GrSurfaceDesc desc; + desc.fFlags = kRenderTarget_GrSurfaceFlag; // needs to be a rendertarget for readpixels(); desc.fOrigin = kDefault_GrSurfaceOrigin; desc.fWidth = w; desc.fHeight = h; -- 2.7.4