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

Unified Diff: include/core/SkCanvas.h

Issue 22978012: Split SkDevice into SkBaseDevice and SkBitmapDevice (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Updating to ToT (10994) Created 7 years, 4 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 | « include/core/SkBitmapDevice.h ('k') | include/core/SkDevice.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkCanvas.h
===================================================================
--- include/core/SkCanvas.h (revision 10994)
+++ include/core/SkCanvas.h (working copy)
@@ -22,7 +22,7 @@
#include "SkXfermode.h"
class SkBounder;
-class SkDevice;
+class SkBaseDevice;
class SkDraw;
class SkDrawFilter;
class SkMetaData;
@@ -55,7 +55,7 @@
@param device Specifies a device for the canvas to draw into.
*/
- explicit SkCanvas(SkDevice* device);
+ explicit SkCanvas(SkBaseDevice* device);
/** Deprecated - Construct a canvas with the specified bitmap to draw into.
@param bitmap Specifies a bitmap for the canvas to draw into. Its
@@ -84,7 +84,7 @@
the bitmap of the pixels that the canvas draws into. The reference count
of the returned device is not changed by this call.
*/
- SkDevice* getDevice() const;
+ SkBaseDevice* getDevice() const;
/**
* saveLayer() can create another device (which is later drawn onto
@@ -99,15 +99,15 @@
* is drawn to, but is optional here, as there is a small perf hit
* sometimes.
*/
- SkDevice* getTopDevice(bool updateMatrixClip = false) const;
+ SkBaseDevice* getTopDevice(bool updateMatrixClip = false) const;
/**
* Shortcut for getDevice()->createCompatibleDevice(...).
* If getDevice() == NULL, this method does nothing, and returns NULL.
*/
- SkDevice* createCompatibleDevice(SkBitmap::Config config,
- int width, int height,
- bool isOpaque);
+ SkBaseDevice* createCompatibleDevice(SkBitmap::Config config,
+ int width, int height,
+ bool isOpaque);
///////////////////////////////////////////////////////////////////////////
@@ -994,7 +994,7 @@
// These reflect the current device in the iterator
- SkDevice* device() const;
+ SkBaseDevice* device() const;
const SkMatrix& matrix() const;
const SkRegion& clip() const;
const SkPaint& paint() const;
@@ -1043,7 +1043,7 @@
reference count is incremented. If the canvas was already holding a
device, its reference count is decremented. The new device is returned.
*/
- virtual SkDevice* setDevice(SkDevice* device);
+ virtual SkBaseDevice* setDevice(SkBaseDevice* device);
private:
class MCRec;
@@ -1074,10 +1074,10 @@
friend class SkDrawIter; // needs setupDrawForLayerDevice()
friend class AutoDrawLooper;
- SkDevice* createLayerDevice(SkBitmap::Config, int width, int height,
- bool isOpaque);
+ SkBaseDevice* createLayerDevice(SkBitmap::Config, int width, int height,
+ bool isOpaque);
- SkDevice* init(SkDevice*);
+ SkBaseDevice* init(SkBaseDevice*);
// internal methods are not virtual, so they can safely be called by other
// canvas apis, without confusing subclasses (like SkPictureRecording)
@@ -1090,7 +1090,7 @@
void internalDrawPaint(const SkPaint& paint);
int internalSaveLayer(const SkRect* bounds, const SkPaint* paint,
SaveFlags, bool justForImageFilter);
- void internalDrawDevice(SkDevice*, int x, int y, const SkPaint*);
+ void internalDrawDevice(SkBaseDevice*, int x, int y, const SkPaint*);
// shared by save() and saveLayer()
int internalSave(SaveFlags flags);
« no previous file with comments | « include/core/SkBitmapDevice.h ('k') | include/core/SkDevice.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698