skia2/dm/DMUtil.cpp
mtklein@google.com d36522d12d dm is like gm, but faster and with fewer features.
This is sort of the near-minimal proof-of-concept skeleton.

  - It can run existing GMs.
  - It supports most configs (just not PDF).
  - --replay is the only "fancy" feature it currently supports

Hopefully you will be disturbed by its speed.

BUG=
R=epoger@google.com

Review URL: https://codereview.chromium.org/22839016

git-svn-id: http://skia.googlecode.com/svn/trunk@11802 2bbb7eff-a529-9590-31e7-b0007b416f81
2013-10-16 13:02:15 +00:00

24 lines
479 B
C++

#include "DMUtil.h"
namespace DM {
SkString underJoin(const char* a, const char* b) {
SkString s;
s.appendf("%s_%s", a, b);
return s;
}
SkString png(SkString s) {
s.appendf(".png");
return s;
}
bool meetsExpectations(const skiagm::Expectations& expectations,
const skiagm::GmResultDigest& digest) {
return expectations.ignoreFailure()
|| expectations.empty()
|| expectations.match(digest);
}
} // namespace DM