Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(134)

Unified Diff: src/core/SkCanvas.cpp

Issue 201973003: remove SK_SUPPORT_LEGACY_WRITEPIXELSCONFIG -- dead code (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/core/SkBitmapDevice.cpp ('k') | src/core/SkDevice.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkCanvas.cpp
diff --git a/src/core/SkCanvas.cpp b/src/core/SkCanvas.cpp
index d637405445dfc5d9f56497f088df9c03dea2f58e..17e03c2373232bc2721c26f5bee1f246a3acbd1c 100644
--- a/src/core/SkCanvas.cpp
+++ b/src/core/SkCanvas.cpp
@@ -700,20 +700,6 @@ bool SkCanvas::readPixels(const SkIRect& srcRect, SkBitmap* bitmap) {
}
}
-#ifdef SK_SUPPORT_LEGACY_WRITEPIXELSCONFIG
-void SkCanvas::writePixels(const SkBitmap& bitmap, int x, int y,
- Config8888 config8888) {
- SkBaseDevice* device = this->getDevice();
- if (device) {
- if (SkIRect::Intersects(SkIRect::MakeSize(this->getDeviceSize()),
- SkIRect::MakeXYWH(x, y, bitmap.width(), bitmap.height()))) {
- device->accessBitmap(true);
- device->writePixels(bitmap, x, y, config8888);
- }
- }
-}
-#endif
-
bool SkCanvas::writePixels(const SkBitmap& bitmap, int x, int y) {
if (bitmap.getTexture()) {
return false;
@@ -766,7 +752,7 @@ bool SkCanvas::writePixels(const SkImageInfo& origInfo, const void* pixels, size
pixels = ((const char*)pixels - y * rowBytes - x * info.bytesPerPixel());
// The device can assert that the requested area is always contained in its bounds
- return device->writePixelsDirect(info, pixels, rowBytes, target.x(), target.y());
+ return device->writePixels(info, pixels, rowBytes, target.x(), target.y());
}
SkCanvas* SkCanvas::canvasForDrawIter() {
« no previous file with comments | « src/core/SkBitmapDevice.cpp ('k') | src/core/SkDevice.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698