Flutter Engine
The Flutter Engine
Public Member Functions | Protected Types | Protected Attributes | List of all members
MapPointsMatrixBench Class Reference
Inheritance diagram for MapPointsMatrixBench:
MatrixBench Benchmark SkRefCnt SkRefCntBase

Public Member Functions

 MapPointsMatrixBench (const char name[], const SkMatrix &m)
 
void performTest () override
 
- Public Member Functions inherited from MatrixBench
 MatrixBench (const char name[])
 
bool isSuitableFor (Backend backend) override
 
virtual void performTest ()=0
 
- Public Member Functions inherited from Benchmark
 Benchmark ()
 
const char * getName ()
 
const char * getUniqueName ()
 
SkISize getSize ()
 
virtual bool isSuitableFor (Backend backend)
 
virtual void modifyGrContextOptions (GrContextOptions *)
 
virtual bool shouldLoop () const
 
void delayedSetup ()
 
void perCanvasPreDraw (SkCanvas *)
 
void perCanvasPostDraw (SkCanvas *)
 
void preDraw (SkCanvas *)
 
void postDraw (SkCanvas *)
 
void draw (int loops, SkCanvas *)
 
virtual void getGpuStats (SkCanvas *, skia_private::TArray< SkString > *keys, skia_private::TArray< double > *values)
 
virtual bool getDMSAAStats (GrRecordingContext *)
 
int getUnits () const
 
- Public Member Functions inherited from SkRefCntBase
 SkRefCntBase ()
 
virtual ~SkRefCntBase ()
 
bool unique () const
 
void ref () const
 
void unref () const
 

Protected Types

enum  { N = 32 }
 

Protected Attributes

SkMatrix fM
 
SkPoint fSrc [N]
 
SkPoint fDst [N]
 

Additional Inherited Members

- Public Types inherited from Benchmark
enum class  Backend {
  kNonRendering , kRaster , kGanesh , kGraphite ,
  kPDF , kHWUI
}
 
- Protected Member Functions inherited from MatrixBench
virtual int mulLoopCount () const
 
const char * onGetName () override
 
void onDraw (int loops, SkCanvas *) override
 
- Protected Member Functions inherited from Benchmark
void setUnits (int units)
 
virtual void setupPaint (SkPaint *paint)
 
virtual const char * onGetName ()=0
 
virtual const char * onGetUniqueName ()
 
virtual void onDelayedSetup ()
 
virtual void onPerCanvasPreDraw (SkCanvas *)
 
virtual void onPerCanvasPostDraw (SkCanvas *)
 
virtual void onPreDraw (SkCanvas *)
 
virtual void onPostDraw (SkCanvas *)
 
virtual void onDraw (int loops, SkCanvas *)=0
 
virtual SkISize onGetSize ()
 

Detailed Description

Definition at line 202 of file MatrixBench.cpp.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
protected
Enumerator

Definition at line 205 of file MatrixBench.cpp.

205 {
206 N = 32
207 };

Constructor & Destructor Documentation

◆ MapPointsMatrixBench()

MapPointsMatrixBench::MapPointsMatrixBench ( const char  name[],
const SkMatrix m 
)
inline

Definition at line 210 of file MatrixBench.cpp.

211 : MatrixBench(name), fM(m)
212 {
213 SkRandom rand;
214 for (int i = 0; i < N; ++i) {
215 fSrc[i].set(rand.nextSScalar1(), rand.nextSScalar1());
216 }
217 }
MatrixBench(const char name[])
Definition: MatrixBench.cpp:16
SkScalar nextSScalar1()
Definition: SkRandom.h:113
DEF_SWITCHES_START aot vmservice shared library name
Definition: switches.h:32
void set(float x, float y)
Definition: SkPoint_impl.h:200

Member Function Documentation

◆ performTest()

void MapPointsMatrixBench::performTest ( )
inlineoverridevirtual

Implements MatrixBench.

Definition at line 219 of file MatrixBench.cpp.

219 {
220 for (int i = 0; i < 1000000; ++i) {
222 }
223 }
void mapPoints(SkPoint dst[], const SkPoint src[], int count) const
Definition: SkMatrix.cpp:770

Member Data Documentation

◆ fDst

SkPoint MapPointsMatrixBench::fDst[N]
protected

Definition at line 208 of file MatrixBench.cpp.

◆ fM

SkMatrix MapPointsMatrixBench::fM
protected

Definition at line 204 of file MatrixBench.cpp.

◆ fSrc

SkPoint MapPointsMatrixBench::fSrc[N]
protected

Definition at line 208 of file MatrixBench.cpp.


The documentation for this class was generated from the following file: