Flutter Engine
The Flutter Engine
Classes | Functions
PDFBench.cpp File Reference
#include "bench/Benchmark.h"
#include "include/core/SkBitmap.h"
#include "include/core/SkData.h"
#include "include/core/SkExecutor.h"
#include "include/core/SkImage.h"
#include "include/core/SkPath.h"
#include "include/core/SkPixmap.h"
#include "include/core/SkStream.h"
#include "include/effects/SkGradientShader.h"
#include "include/private/base/SkTo.h"
#include "src/base/SkRandom.h"
#include "src/core/SkAutoPixmapStorage.h"
#include "src/pdf/SkPDFUnion.h"
#include "src/utils/SkFloatToDecimal.h"
#include "tools/DecodeUtils.h"
#include "tools/Resources.h"
#include "tools/fonts/FontToolUtils.h"

Go to the source code of this file.

Classes

struct  PDFScalarBench
 

Functions

float next_common (SkRandom *random)
 
float next_any (SkRandom *random)
 

Function Documentation

◆ next_any()

float next_any ( SkRandom random)

Definition at line 70 of file PDFBench.cpp.

70 {
71 union { uint32_t u; float f; };
72 u = random->nextU();
73 static_assert(sizeof(float) == sizeof(uint32_t), "");
74 return f;
75}
uint32_t nextU()
Definition: SkRandom.h:42

◆ next_common()

float next_common ( SkRandom random)

Definition at line 67 of file PDFBench.cpp.

67 {
68 return random->nextRangeF(-500.0f, 1500.0f);
69}
float nextRangeF(float min, float max)
Definition: SkRandom.h:64