2 * Copyright 2021 Google LLC
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
8 #ifndef GrOpsTypes_DEFINED
9 #define GrOpsTypes_DEFINED
11 #include "include/core/SkMatrix.h"
12 #include "include/core/SkRect.h"
13 #include "include/private/SkColorData.h"
14 #include "include/private/gpu/ganesh/GrTypesPriv.h"
15 #include "src/gpu/ganesh/GrSurfaceProxyView.h"
17 /** Used by SDC::drawQuadSet and FillRectOp */
18 struct GrQuadSetEntry {
20 SkPMColor4f fColor; // Overrides any color on the GrPaint
21 SkMatrix fLocalMatrix;
22 GrQuadAAFlags fAAFlags;
25 /** Used by SDC::drawTextureSet and TextureOp */
26 struct GrTextureSetEntry {
27 GrSurfaceProxyView fProxyView;
28 SkAlphaType fSrcAlphaType;
31 const SkPoint* fDstClipQuad; // Must be null, or point to an array of 4 points
32 const SkMatrix* fPreViewMatrix; // If not null, entry's CTM is 'viewMatrix' * fPreViewMatrix
33 SkPMColor4f fColor; // {a,a,a,a} for rgb textures, {r,g,b,a} for alpha-only textures
34 GrQuadAAFlags fAAFlags;