From 432789972c1e1f8a66165c75a250dba1853efa08 Mon Sep 17 00:00:00 2001 From: piotaixr Date: Tue, 23 Sep 2014 14:10:50 -0700 Subject: SkCanvas::drawImage is the new way for drawing a SkImage to a Canvas BUG=skia:2947 R=junov@chromium.org, reed@google.com, bsalomon@google.com Author: piotaixr@chromium.org Review URL: https://codereview.chromium.org/583453002 --- samplecode/SampleTextureDomain.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'samplecode/SampleTextureDomain.cpp') diff --git a/samplecode/SampleTextureDomain.cpp b/samplecode/SampleTextureDomain.cpp index 926c5596b0..af511c7b03 100644 --- a/samplecode/SampleTextureDomain.cpp +++ b/samplecode/SampleTextureDomain.cpp @@ -71,7 +71,7 @@ protected: srcRect.setXYWH(1, 1, 3, 3); dstRect.setXYWH(405, 5, 305, 305); - image->draw(canvas, &srcRect, dstRect, &paint); + canvas->drawImageRect(image, &srcRect, dstRect, &paint); // Test that bitmap blurring using a subrect // renders correctly @@ -83,7 +83,7 @@ protected: SkBlurMaskFilter::kHighQuality_BlurFlag | SkBlurMaskFilter::kIgnoreTransform_BlurFlag); paint.setMaskFilter(mf)->unref(); - image->draw(canvas, &srcRect, dstRect, &paint); + canvas->drawImageRect(image, &srcRect, dstRect, &paint); // Blur and a rotation + NULL src rect // This should not trigger the texture domain code -- cgit v1.2.3