Flutter Engine
The Flutter Engine
RecordingBench.h
Go to the documentation of this file.
1/*
2 * Copyright 2014 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8#ifndef RecordingBench_DEFINED
9#define RecordingBench_DEFINED
10
11#include "bench/Benchmark.h"
13
15public:
16 PictureCentricBench(const char* name, const SkPicture*);
17
18protected:
19 const char* onGetName() override;
20 bool isSuitableFor(Backend) override;
21 SkISize onGetSize() override;
22
23protected:
26
28};
29
31public:
32 RecordingBench(const char* name, const SkPicture*, bool useBBH);
33
34protected:
35 void onDraw(int loops, SkCanvas*) override;
36
37private:
38 bool fUseBBH;
39
41};
42
44public:
45 DeserializePictureBench(const char* name, sk_sp<SkData> encodedPicture);
46
47protected:
48 const char* onGetName() override;
49 bool isSuitableFor(Backend) override;
50 SkISize onGetSize() override;
51 void onDraw(int loops, SkCanvas*) override;
52
53private:
54 SkString fName;
55 sk_sp<SkData> fEncodedPicture;
56
57 using INHERITED = Benchmark;
58};
59
60#endif//RecordingBench_DEFINED
const char * onGetName() override
SkISize onGetSize() override
DeserializePictureBench(const char *name, sk_sp< SkData > encodedPicture)
void onDraw(int loops, SkCanvas *) override
bool isSuitableFor(Backend) override
SkISize onGetSize() override
sk_sp< const SkPicture > fSrc
PictureCentricBench(const char *name, const SkPicture *)
const char * onGetName() override
bool isSuitableFor(Backend) override
RecordingBench(const char *name, const SkPicture *, bool useBBH)
void onDraw(int loops, SkCanvas *) override
DEF_SWITCHES_START aot vmservice shared library name
Definition: switches.h:32
Definition: SkSize.h:16