Fix rtree bench

R=caryclark@google.com

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

git-svn-id: http://skia.googlecode.com/svn/trunk@11041 2bbb7eff-a529-9590-31e7-b0007b416f81
This commit is contained in:
sglez@google.com 2013-08-30 18:38:53 +00:00
parent f714d513a6
commit 3e3cdadefd
2 changed files with 5 additions and 5 deletions

View File

@ -168,16 +168,16 @@ static inline SkIRect make_XYordered_rects(SkMWCRandom& rand, int index, int num
SkIRect out;
out.fLeft = index % GRID_WIDTH;
out.fTop = index / GRID_WIDTH;
out.fRight = 1 + rand.nextU() % (GENERATE_EXTENTS / 3);
out.fBottom = 1 + rand.nextU() % (GENERATE_EXTENTS / 3);
out.fRight = fLeft + 1 + rand.nextU() % (GENERATE_EXTENTS / 3);
out.fBottom = fTop + 1 + rand.nextU() % (GENERATE_EXTENTS / 3);
return out;
}
static inline SkIRect make_YXordered_rects(SkMWCRandom& rand, int index, int numRects) {
SkIRect out;
out.fLeft = index / GRID_WIDTH;
out.fTop = index % GRID_WIDTH;
out.fRight = 1 + rand.nextU() % (GENERATE_EXTENTS / 3);
out.fBottom = 1 + rand.nextU() % (GENERATE_EXTENTS / 3);
out.fRight = fLeft + 1 + rand.nextU() % (GENERATE_EXTENTS / 3);
out.fBottom = fTop + 1 + rand.nextU() % (GENERATE_EXTENTS / 3);
return out;
}

View File

@ -17,7 +17,7 @@
#include "SkTArray.h"
#include "TimerData.h"
static const int kNumNormalRecordings = SkBENCHLOOP(0);
static const int kNumNormalRecordings = SkBENCHLOOP(10);
static const int kNumRTreeRecordings = SkBENCHLOOP(10);
static const int kNumPlaybacks = SkBENCHLOOP(1);
static const size_t kNumBaseBenchmarks = 3;