Flutter Engine
The Flutter Engine
third_party
skia
tools
gpu
TestOps.h
Go to the documentation of this file.
1
/*
2
* Copyright 2019 Google LLC
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 TestRectOp_DEFINED
9
#define TestRectOp_DEFINED
10
11
#include "
include/core/SkRefCnt.h
"
12
#include "
include/gpu/GrRecordingContext.h
"
13
#include "
src/gpu/ganesh/GrRecordingContextPriv.h
"
14
#include "
src/gpu/ganesh/ops/GrOp.h
"
15
16
class
GrPaint
;
17
18
namespace
sk_gpu_test::test_ops
{
19
20
/**
21
* Fully specified device space rect op. The test Op draws a rectangle with local coords and a
22
* local matrix. It is important to test effects in the presence of GP local matrices. Our standard
23
* rect drawing code doesn't exercise this because it applies any local matrix to pre-transformed
24
* local coord vertex attributes.
25
*/
26
GrOp::Owner
MakeRect
(
GrRecordingContext
*,
27
GrPaint
&&,
28
const
SkRect
& drawRect,
29
const
SkRect
& localRect,
30
const
SkMatrix
& localM =
SkMatrix::I
());
31
32
/**
33
* A simpler version of MakeRect that takes a single color FP instead of a full paint. Uses
34
* SkBlendMode::kSrcOver.
35
*/
36
GrOp::Owner
MakeRect
(
GrRecordingContext
*,
37
std::unique_ptr<GrFragmentProcessor>,
38
const
SkRect
& drawRect,
39
const
SkRect
& localRect,
40
const
SkMatrix
& localM =
SkMatrix::I
());
41
42
/**
43
* A simpler version of MakeRect that uses the same rect as the device space rect to draw as well as
44
* the local rect. The local matrix is identity.
45
*/
46
GrOp::Owner
MakeRect
(
GrRecordingContext
*,
GrPaint
&&,
const
SkRect
&
rect
);
47
48
}
// namespace sk_gpu_test::test_ops
49
50
#endif
GrOp.h
GrRecordingContextPriv.h
GrRecordingContext.h
SkRefCnt.h
GrOp::Owner
std::unique_ptr< GrOp > Owner
Definition:
GrOp.h:72
GrPaint
Definition:
GrPaint.h:40
GrRecordingContext
Definition:
GrRecordingContext.h:42
SkMatrix
Definition:
SkMatrix.h:54
SkMatrix::I
static const SkMatrix & I()
Definition:
SkMatrix.cpp:1544
SkRecords::rect
sk_sp< SkBlender > blender SkRect rect
Definition:
SkRecords.h:350
sk_gpu_test::test_ops
Definition:
TestOps.cpp:225
sk_gpu_test::test_ops::MakeRect
GrOp::Owner MakeRect(GrRecordingContext *context, GrPaint &&paint, const SkRect &drawRect, const SkRect &localRect, const SkMatrix &localM)
Definition:
TestOps.cpp:227
SkRect
Definition:
extension.cpp:13
Generated on Sun Jun 23 2024 21:56:50 for Flutter Engine by
1.9.4