From 514b922236aa9308827e50ec32b1ee6102deff60 Mon Sep 17 00:00:00 2001 From: "senorblanco@chromium.org" Date: Fri, 18 Jan 2013 21:53:12 +0000 Subject: [PATCH] Partial revert of r7287 to green up the bots. git-svn-id: http://skia.googlecode.com/svn/trunk@7290 2bbb7eff-a529-9590-31e7-b0007b416f81 --- src/gpu/SkGpuDevice.cpp | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp index 8390164..0cf3b35 100644 --- a/src/gpu/SkGpuDevice.cpp +++ b/src/gpu/SkGpuDevice.cpp @@ -1428,8 +1428,6 @@ void SkGpuDevice::drawSprite(const SkDraw& draw, const SkBitmap& bitmap, if (filteredTexture) { grPaint.colorStage(kBitmapTextureIdx)->setEffect( GrSimpleTextureEffect::Create(filteredTexture, SkMatrix::I()))->unref(); - w = filteredTexture->width(); - h = filteredTexture->height(); texture = filteredTexture; filteredTexture->unref(); } @@ -1493,10 +1491,6 @@ void SkGpuDevice::drawDevice(const SkDraw& draw, SkDevice* device, return; } - const SkBitmap& bm = dev->accessBitmap(false); - int w = bm.width(); - int h = bm.height(); - GrTexture* devTex = grPaint.getColorStage(kBitmapTextureIdx).getEffect()->texture(0); SkASSERT(NULL != devTex); @@ -1509,12 +1503,14 @@ void SkGpuDevice::drawDevice(const SkDraw& draw, SkDevice* device, grPaint.colorStage(kBitmapTextureIdx)->setEffect( GrSimpleTextureEffect::Create(filteredTexture, SkMatrix::I()))->unref(); devTex = filteredTexture; - w = devTex->width(); - h = devTex->height(); filteredTexture->unref(); } } + const SkBitmap& bm = dev->accessBitmap(false); + int w = bm.width(); + int h = bm.height(); + GrRect dstRect = GrRect::MakeXYWH(SkIntToScalar(x), SkIntToScalar(y), SkIntToScalar(w), -- 2.7.4