diff options
author | 2015-01-15 08:30:25 -0800 | |
---|---|---|
committer | 2015-01-15 08:30:25 -0800 | |
commit | 709d2c3e5062c5b57f91273bfc11a751f5b2bb88 (patch) | |
tree | b997d8e2f4fcd0c289017586540c876a1cef9c96 /dm/DMUtil.h | |
parent | 8eadff1e8c9cdb8f941c893a4763c03f5f083c62 (diff) |
Sketch DM refactor.
BUG=skia:3255
I think this supports everything DM used to, but has completely refactored how
it works to fit the design in the bug.
Configs like "tiles-gpu" are automatically wired up.
I wouldn't suggest looking at this as a diff. There's just a bunch of deleted
files, a few new files, and one new file that shares a name with a deleted file
(DM.cpp).
NOTREECHECKS=true
Review URL: https://codereview.chromium.org/788243008
Diffstat (limited to 'dm/DMUtil.h')
-rw-r--r-- | dm/DMUtil.h | 43 |
1 files changed, 0 insertions, 43 deletions
diff --git a/dm/DMUtil.h b/dm/DMUtil.h deleted file mode 100644 index dfb7f92022..0000000000 --- a/dm/DMUtil.h +++ /dev/null @@ -1,43 +0,0 @@ -#ifndef DMUtil_DEFINED -#define DMUtil_DEFINED - -#include "SkBitmap.h" -#include "SkCanvas.h" -#include "SkString.h" -#include "gm.h" - -class SkBBHFactory; - -// Small free functions used in more than one place in DM. - -namespace DM { - -// UnderJoin("a", "b") -> "a_b" -SkString UnderJoin(const char* a, const char* b); - -// "foo_bar.skp" -> "foo-bar_skp" -SkString FileToTaskName(SkString); - -// Draw gm to picture. -SkPicture* RecordPicture(skiagm::GM* gm, SkBBHFactory* factory = NULL); - -// Allocate an empty bitmap with this size and depth. -void AllocatePixels(SkColorType, int w, int h, SkBitmap* bitmap); -// Allocate an empty bitmap the same size and depth as reference. -void AllocatePixels(const SkBitmap& reference, SkBitmap* bitmap); - -// Draw picture to bitmap. -void DrawPicture(const SkPicture& picture, SkBitmap* bitmap); - -// What is the maximum component difference in these bitmaps? -unsigned MaxComponentDifference(const SkBitmap& a, const SkBitmap& b); - -// Are these identical bitmaps? -bool BitmapsEqual(const SkBitmap& a, const SkBitmap& b); - -// Hook to modify canvas using global flag values (e.g. --matrix). -void CanvasPreflight(SkCanvas*); - -} // namespace DM - -#endif // DMUtil_DEFINED |