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

Public Member Functions

 PixmapOrientBench ()
 
- 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 Member Functions

void onDelayedSetup () override
 
const char * onGetName () override
 
bool isSuitableFor (Backend backend) 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 ()
 

Additional Inherited Members

- Public Types inherited from Benchmark
enum class  Backend {
  kNonRendering , kRaster , kGanesh , kGraphite ,
  kPDF , kHWUI
}
 

Detailed Description

Definition at line 67 of file ReadPixBench.cpp.

Constructor & Destructor Documentation

◆ PixmapOrientBench()

PixmapOrientBench::PixmapOrientBench ( )
inline

Definition at line 69 of file ReadPixBench.cpp.

69{}

Member Function Documentation

◆ isSuitableFor()

bool PixmapOrientBench::isSuitableFor ( Backend  backend)
inlineoverrideprotectedvirtual

Reimplemented from Benchmark.

Definition at line 83 of file ReadPixBench.cpp.

83 {
85 }
const char * backend

◆ onDelayedSetup()

void PixmapOrientBench::onDelayedSetup ( )
inlineoverrideprotectedvirtual

Reimplemented from Benchmark.

Definition at line 72 of file ReadPixBench.cpp.

72 {
74 fSrc.allocPixels(info);
76 fDst.allocPixels(info.makeDimensions(info.dimensions()));
77 }
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
Definition: DM.cpp:213
constexpr SkColor SK_ColorBLACK
Definition: SkColor.h:103
void allocPixels(const SkImageInfo &info, size_t rowBytes)
Definition: SkBitmap.cpp:258
void eraseColor(SkColor4f) const
Definition: SkBitmap.cpp:442
static SkImageInfo MakeN32Premul(int width, int height)

◆ onDraw()

void PixmapOrientBench::onDraw ( int  loops,
SkCanvas  
)
inlineoverrideprotectedvirtual

Implements Benchmark.

Definition at line 87 of file ReadPixBench.cpp.

87 {
89 fSrc.peekPixels(&src);
90 fDst.peekPixels(&dst);
91 for (int i = 0; i < loops; ++i) {
93 }
94 }
@ kTopRight_SkEncodedOrigin
bool peekPixels(SkPixmap *pixmap) const
Definition: SkBitmap.cpp:635
SK_API bool Orient(const SkPixmap &dst, const SkPixmap &src, SkEncodedOrigin origin)
dst
Definition: cp.py:12

◆ onGetName()

const char * PixmapOrientBench::onGetName ( )
inlineoverrideprotectedvirtual

Implements Benchmark.

Definition at line 79 of file ReadPixBench.cpp.

79 {
80 return "orient_pixmap";
81 }

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