From 9c7edb8311409a141b0dc1d5e480c68c629f1997 Mon Sep 17 00:00:00 2001 From: Leon Scroggins Date: Thu, 10 Nov 2016 18:31:58 +0000 Subject: Revert "Add integer texture support." This reverts commit 434c534bd0ec08cb355fecfb6d2110197b523e74. Reason for revert: Undefined behavior. From https://uberchromegw.corp.google.com/i/client.skia/builders/Test-Ubuntu-Clang-Golo-GPU-GT610-x86_64-Debug-ASAN/builds/1272/steps/test_skia%20on%20Ubuntu/logs/stdio ../../../tests/IntTextureTest.cpp:51:44: runtime error: left shift of negative value -1 #0 0x2257480 in test_IntTexture(skiatest::Reporter*, sk_gpu_test::ContextInfo const&) (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x2257480) #1 0x1ca1066 in skiatest::RunWithGPUTestContexts(void (*)(skiatest::Reporter*, sk_gpu_test::ContextInfo const&), bool (*)(sk_gpu_test::GrContextFactory::ContextType), skiatest::Reporter*, sk_gpu_test::GrContextFactory*) (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x1ca1066) #2 0x1ca080d in run_test(skiatest::Test) (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x1ca080d) #3 0x1c9e5e9 in dm_main() (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x1c9e5e9) #4 0x7f2d2ba8df44 in __libc_start_main /build/eglibc-oGUzwX/eglibc-2.19/csu/libc-start.c:287 #5 0x1bb3028 in _start (/b/swarm_slave/w/ir0aO1sa/out/Debug/dm+0x1bb3028) SUMMARY: AddressSanitizer: undefined-behavior ../../../tests/IntTextureTest.cpp:51:44 in step returned non-zero exit code: 1 Original change's description: > Add integer texture support. > > This allows us to create integer textures and sample them from a GrProcessor's code. > > Filtering is limited to NEAREST. > > Adds tests for reading/writing pixels, copying, and drawing. These operations are not allowed to convert to fixed/float configs. > > Vulkan support is TBD. > > > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=4348 > > Change-Id: If38d89a03285d4bd98d1f14f9638b0320977e43d > Reviewed-on: https://skia-review.googlesource.com/4348 > Commit-Queue: Brian Salomon > Reviewed-by: Chris Dalton > TBR=bsalomon@google.com,csmartdalton@google.com,reviews@skia.org NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Change-Id: I39f1a0a0dd3e6cde1143c8cc1217d2e3d5977b21 Reviewed-on: https://skia-review.googlesource.com/4663 Commit-Queue: Leon Scroggins Reviewed-by: Leon Scroggins --- src/gpu/batches/GrCopySurfaceBatch.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) (limited to 'src/gpu/batches') diff --git a/src/gpu/batches/GrCopySurfaceBatch.cpp b/src/gpu/batches/GrCopySurfaceBatch.cpp index 724609871d..a59ed38f51 100644 --- a/src/gpu/batches/GrCopySurfaceBatch.cpp +++ b/src/gpu/batches/GrCopySurfaceBatch.cpp @@ -63,12 +63,7 @@ GrBatch* GrCopySurfaceBatch::Create(GrSurface* dst, GrSurface* src, const SkIRec const SkIPoint& dstPoint) { SkASSERT(dst); SkASSERT(src); - if (GrPixelConfigIsSint(dst->config()) != GrPixelConfigIsSint(src->config())) { - return nullptr; - } - if (GrPixelConfigIsCompressed(dst->config())) { - return nullptr; - } + SkIRect clippedSrcRect; SkIPoint clippedDstPoint; // If the rect is outside the src or dst then we've already succeeded. -- cgit v1.2.3