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

Side by Side Diff: bench/MorphologyBench.cpp

Issue 117053002: remove SK_SCALAR_IS_[FLOAT,FIXED] and assume floats (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | bench/benchmain.cpp » ('j') | src/core/SkCanvas.cpp » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2012 Google Inc. 2 * Copyright 2012 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkBenchmark.h" 8 #include "SkBenchmark.h"
9 #include "SkCanvas.h" 9 #include "SkCanvas.h"
10 #include "SkPaint.h" 10 #include "SkPaint.h"
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 paint.setImageFilter(mf)->unref(); 77 paint.setImageFilter(mf)->unref();
78 } 78 }
79 canvas->drawOval(r, paint); 79 canvas->drawOval(r, paint);
80 } 80 }
81 } 81 }
82 82
83 private: 83 private:
84 typedef SkBenchmark INHERITED; 84 typedef SkBenchmark INHERITED;
85 }; 85 };
86 86
87 // Fixed point can be 100x slower than float on these tests, causing
88 // bench to timeout.
89 #ifndef SK_SCALAR_IS_FIXED
90 DEF_BENCH( return new MorphologyBench(SMALL, kErode_MT); ) 87 DEF_BENCH( return new MorphologyBench(SMALL, kErode_MT); )
91 DEF_BENCH( return new MorphologyBench(SMALL, kDilate_MT); ) 88 DEF_BENCH( return new MorphologyBench(SMALL, kDilate_MT); )
92 89
93 DEF_BENCH( return new MorphologyBench(BIG, kErode_MT); ) 90 DEF_BENCH( return new MorphologyBench(BIG, kErode_MT); )
94 DEF_BENCH( return new MorphologyBench(BIG, kDilate_MT); ) 91 DEF_BENCH( return new MorphologyBench(BIG, kDilate_MT); )
95 92
96 DEF_BENCH( return new MorphologyBench(REAL, kErode_MT); ) 93 DEF_BENCH( return new MorphologyBench(REAL, kErode_MT); )
97 DEF_BENCH( return new MorphologyBench(REAL, kDilate_MT); ) 94 DEF_BENCH( return new MorphologyBench(REAL, kDilate_MT); )
98 95
99 DEF_BENCH( return new MorphologyBench(0, kErode_MT); ) 96 DEF_BENCH( return new MorphologyBench(0, kErode_MT); )
100 #endif
OLDNEW
« no previous file with comments | « no previous file | bench/benchmain.cpp » ('j') | src/core/SkCanvas.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698