aboutsummaryrefslogtreecommitdiffhomepage
path: root/bench/MatrixBench.cpp
diff options
context:
space:
mode:
authorGravatar mtklein <mtklein@chromium.org>2015-07-13 06:18:39 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-07-13 06:18:39 -0700
commitf059900f75639f1b1a03f2c25333ef9aa22d58b8 (patch)
treef7c27d37b1c84ac3f7e4b15af4eb513be84a922a /bench/MatrixBench.cpp
parent4598fc3c123cd8af1dac5596f955a375186a31f3 (diff)
Fix up -Winconsistent-missing-override
(and a couple presubmit fixes) This allows us to turn back on -Werror for LLVM coverage builds, and more generally supports building with Clang 3.7. No public API changes. TBR=reed@google.com BUG=skia: Review URL: https://codereview.chromium.org/1232463006
Diffstat (limited to 'bench/MatrixBench.cpp')
-rw-r--r--bench/MatrixBench.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/bench/MatrixBench.cpp b/bench/MatrixBench.cpp
index e3e5c703e8..75736aa143 100644
--- a/bench/MatrixBench.cpp
+++ b/bench/MatrixBench.cpp
@@ -27,11 +27,11 @@ public:
protected:
virtual int mulLoopCount() const { return 1; }
- virtual const char* onGetName() {
+ const char* onGetName() override {
return fName.c_str();
}
- virtual void onDraw(const int loops, SkCanvas*) {
+ void onDraw(const int loops, SkCanvas*) override {
for (int i = 0; i < loops; i++) {
this->performTest();
}
@@ -46,7 +46,7 @@ class EqualsMatrixBench : public MatrixBench {
public:
EqualsMatrixBench() : INHERITED("equals") {}
protected:
- virtual void performTest() {
+ void performTest() override {
SkMatrix m0, m1, m2;
m0.reset();
@@ -72,7 +72,7 @@ public:
fM2.setTranslate(fSX, fSY);
}
protected:
- virtual void performTest() {
+ void performTest() override {
SkMatrix m;
m = fM0; m.preScale(fSX, fSY);
m = fM1; m.preScale(fSX, fSY);
@@ -112,7 +112,7 @@ protected:
// Putting random generation of the matrix inside performTest()
// would help us avoid anomalous runs, but takes up 25% or
// more of the function time.
- virtual void performTest() {
+ void performTest() override {
fMatrix.setAll(fArray[0], fArray[1], fArray[2],
fArray[3], fArray[4], fArray[5],
fArray[6], fArray[7], fArray[8]);
@@ -146,7 +146,7 @@ public:
DecomposeMatrixBench() : INHERITED("decompose") {}
protected:
- virtual void onPreDraw() {
+ void onPreDraw() override {
for (int i = 0; i < 10; ++i) {
SkScalar rot0 = (fRandom.nextBool()) ? fRandom.nextRangeF(-180, 180) : 0.0f;
SkScalar sx = fRandom.nextRangeF(-3000.f, 3000.f);
@@ -157,7 +157,7 @@ protected:
fMatrix[i].postRotate(rot1);
}
}
- virtual void performTest() {
+ void performTest() override {
SkPoint rotation1, scale, rotation2;
for (int i = 0; i < 10; ++i) {
(void) SkDecomposeUpper2x2(fMatrix[i], &rotation1, &scale, &rotation2);
@@ -201,7 +201,7 @@ public:
kUncachedTypeMask_Flag = 0x10,
};
protected:
- virtual void performTest() {
+ void performTest() override {
if (fFlags & kUncachedTypeMask_Flag) {
// This will invalidate the typemask without
// changing the matrix.