Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Classes | Functions
FillPathTest.cpp File Reference
#include "include/core/SkColor.h"
#include "include/core/SkPath.h"
#include "include/core/SkPathTypes.h"
#include "include/core/SkRect.h"
#include "include/core/SkScalar.h"
#include "include/core/SkTypes.h"
#include "src/core/SkBlitter.h"
#include "src/core/SkScan.h"
#include "tests/Test.h"
#include <cstdint>

Go to the source code of this file.

Classes

struct  FakeBlitter
 

Functions

 DEF_TEST (FillPathInverse, reporter)
 

Function Documentation

◆ DEF_TEST()

DEF_TEST ( FillPathInverse  ,
reporter   
)

Definition at line 38 of file FillPathTest.cpp.

38 {
39 FakeBlitter blitter;
42 int height = 100;
43 int width = 200;
44 int expected_lines = 5;
45 clip.setLTRB(0, height - expected_lines, width, height);
46 path.moveTo(0.0f, 0.0f)
48 SkIntToScalar(width), 0.0f)
49 .close()
51 SkScan::FillPath(path, clip, &blitter);
52
53 REPORTER_ASSERT(reporter, blitter.m_blitCount == expected_lines);
54}
reporter
static SkPath clip(const SkPath &path, const SkHalfPlane &plane)
Definition SkPath.cpp:3824
#define SkIntToScalar(x)
Definition SkScalar.h:57
#define REPORTER_ASSERT(r, cond,...)
Definition Test.h:286
static void FillPath(const SkPath &, const SkIRect &, SkBlitter *)
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path
Definition switches.h:57
int32_t height
int32_t width