msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2016 Google Inc. |
| 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 | |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 8 | #include "src/gpu/ops/RegionOp.h" |
Robert Phillips | b97da53 | 2019-02-12 15:24:12 -0500 | [diff] [blame] | 9 | |
Mike Klein | c0bd9f9 | 2019-04-23 12:05:21 -0500 | [diff] [blame] | 10 | #include "include/core/SkRegion.h" |
| 11 | #include "src/core/SkMatrixPriv.h" |
| 12 | #include "src/gpu/GrCaps.h" |
| 13 | #include "src/gpu/GrDefaultGeoProcFactory.h" |
Mike Klein | c0bd9f9 | 2019-04-23 12:05:21 -0500 | [diff] [blame] | 14 | #include "src/gpu/GrOpFlushState.h" |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 15 | #include "src/gpu/GrProgramInfo.h" |
Mike Klein | c0bd9f9 | 2019-04-23 12:05:21 -0500 | [diff] [blame] | 16 | #include "src/gpu/GrResourceProvider.h" |
| 17 | #include "src/gpu/GrVertexWriter.h" |
| 18 | #include "src/gpu/ops/GrMeshDrawOp.h" |
Robert Phillips | 55f681f | 2020-02-28 08:58:15 -0500 | [diff] [blame] | 19 | #include "src/gpu/ops/GrSimpleMeshDrawOpHelperWithStencil.h" |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 20 | |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 21 | namespace { |
| 22 | |
| 23 | GrGeometryProcessor* make_gp(SkArenaAlloc* arena, |
Robert Phillips | 7cd0bfe | 2019-11-20 16:08:10 -0500 | [diff] [blame] | 24 | const SkMatrix& viewMatrix, |
| 25 | bool wideColor) { |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 26 | using namespace GrDefaultGeoProcFactory; |
Robert Phillips | 7cd0bfe | 2019-11-20 16:08:10 -0500 | [diff] [blame] | 27 | Color::Type colorType = wideColor ? Color::kPremulWideColorAttribute_Type |
| 28 | : Color::kPremulGrColorAttribute_Type; |
Brian Osman | f0aee74 | 2020-03-12 09:28:44 -0400 | [diff] [blame] | 29 | return GrDefaultGeoProcFactory::Make(arena, colorType, Coverage::kSolid_Type, |
Brian Osman | 7561dba | 2018-12-27 10:16:18 -0500 | [diff] [blame] | 30 | LocalCoords::kUsePosition_Type, viewMatrix); |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 31 | } |
| 32 | |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 33 | class RegionOpImpl final : public GrMeshDrawOp { |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 34 | private: |
Brian Salomon | 8514ebf | 2017-08-01 11:09:09 -0400 | [diff] [blame] | 35 | using Helper = GrSimpleMeshDrawOpHelperWithStencil; |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 36 | |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 37 | public: |
Brian Salomon | 25a8809 | 2016-12-01 09:36:50 -0500 | [diff] [blame] | 38 | DEFINE_OP_CLASS_ID |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 39 | |
Herb Derby | c76d409 | 2020-10-07 16:46:15 -0400 | [diff] [blame] | 40 | static GrOp::Owner Make(GrRecordingContext* context, |
| 41 | GrPaint&& paint, |
| 42 | const SkMatrix& viewMatrix, |
| 43 | const SkRegion& region, |
| 44 | GrAAType aaType, |
| 45 | const GrUserStencilSettings* stencilSettings = nullptr) { |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 46 | return Helper::FactoryHelper<RegionOpImpl>(context, std::move(paint), viewMatrix, region, |
| 47 | aaType, stencilSettings); |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 48 | } |
| 49 | |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 50 | RegionOpImpl(GrProcessorSet* processorSet, const SkPMColor4f& color, |
| 51 | const SkMatrix& viewMatrix, const SkRegion& region, GrAAType aaType, |
| 52 | const GrUserStencilSettings* stencilSettings) |
Brian Salomon | 8514ebf | 2017-08-01 11:09:09 -0400 | [diff] [blame] | 53 | : INHERITED(ClassID()) |
Herb Derby | c76d409 | 2020-10-07 16:46:15 -0400 | [diff] [blame] | 54 | , fHelper(processorSet, aaType, stencilSettings) |
Brian Salomon | 8514ebf | 2017-08-01 11:09:09 -0400 | [diff] [blame] | 55 | , fViewMatrix(viewMatrix) { |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 56 | RegionInfo& info = fRegions.push_back(); |
| 57 | info.fColor = color; |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 58 | info.fRegion = region; |
| 59 | |
| 60 | SkRect bounds = SkRect::Make(region.getBounds()); |
Greg Daniel | 5faf474 | 2019-10-01 15:14:44 -0400 | [diff] [blame] | 61 | this->setTransformedBounds(bounds, viewMatrix, HasAABloat::kNo, IsHairline::kNo); |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 62 | } |
| 63 | |
Brian Salomon | fc527d2 | 2016-12-14 21:07:01 -0500 | [diff] [blame] | 64 | const char* name() const override { return "GrRegionOp"; } |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 65 | |
Robert Phillips | 294723d | 2021-06-17 09:23:58 -0400 | [diff] [blame] | 66 | void visitProxies(const GrVisitProxyFunc& func) const override { |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 67 | if (fProgramInfo) { |
Chris Dalton | be45742 | 2020-03-16 18:05:03 -0600 | [diff] [blame] | 68 | fProgramInfo->visitFPProxies(func); |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 69 | } else { |
| 70 | fHelper.visitProxies(func); |
| 71 | } |
Robert Phillips | b493eeb | 2017-09-13 13:10:52 -0400 | [diff] [blame] | 72 | } |
| 73 | |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 74 | FixedFunctionFlags fixedFunctionFlags() const override { return fHelper.fixedFunctionFlags(); } |
| 75 | |
Chris Dalton | 57ab06c | 2021-04-22 12:57:28 -0600 | [diff] [blame] | 76 | GrProcessorSet::Analysis finalize(const GrCaps& caps, const GrAppliedClip* clip, |
| 77 | GrClampType clampType) override { |
| 78 | return fHelper.finalizeProcessors(caps, clip, clampType, GrProcessorAnalysisCoverage::kNone, |
| 79 | &fRegions[0].fColor, &fWideColor); |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 80 | } |
| 81 | |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 82 | private: |
Robert Phillips | 2669a7b | 2020-03-12 12:07:19 -0400 | [diff] [blame] | 83 | GrProgramInfo* programInfo() override { return fProgramInfo; } |
| 84 | |
Robert Phillips | 4133dc4 | 2020-03-11 15:55:55 -0400 | [diff] [blame] | 85 | void onCreateProgramInfo(const GrCaps* caps, |
| 86 | SkArenaAlloc* arena, |
Adlai Holler | e2296f7 | 2020-11-19 13:41:26 -0500 | [diff] [blame] | 87 | const GrSurfaceProxyView& writeView, |
Chris Dalton | 6aaf00f | 2021-07-13 13:26:39 -0600 | [diff] [blame] | 88 | bool usesMSAASurface, |
Robert Phillips | 4133dc4 | 2020-03-11 15:55:55 -0400 | [diff] [blame] | 89 | GrAppliedClip&& appliedClip, |
John Stiles | 52cb1d0 | 2021-06-02 11:58:05 -0400 | [diff] [blame] | 90 | const GrDstProxyView& dstProxyView, |
Greg Daniel | 42dbca5 | 2020-11-20 10:22:43 -0500 | [diff] [blame] | 91 | GrXferBarrierFlags renderPassXferBarriers, |
| 92 | GrLoadOp colorLoadOp) override { |
Brian Osman | f0aee74 | 2020-03-12 09:28:44 -0400 | [diff] [blame] | 93 | GrGeometryProcessor* gp = make_gp(arena, fViewMatrix, fWideColor); |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 94 | if (!gp) { |
| 95 | SkDebugf("Couldn't create GrGeometryProcessor\n"); |
Robert Phillips | 4133dc4 | 2020-03-11 15:55:55 -0400 | [diff] [blame] | 96 | return; |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 97 | } |
| 98 | |
Chris Dalton | 2a26c50 | 2021-08-26 10:05:11 -0600 | [diff] [blame] | 99 | fProgramInfo = fHelper.createProgramInfoWithStencil(caps, arena, writeView, usesMSAASurface, |
Robert Phillips | 4133dc4 | 2020-03-11 15:55:55 -0400 | [diff] [blame] | 100 | std::move(appliedClip), dstProxyView, |
Greg Daniel | d358cbe | 2020-09-11 09:33:54 -0400 | [diff] [blame] | 101 | gp, GrPrimitiveType::kTriangles, |
Greg Daniel | 42dbca5 | 2020-11-20 10:22:43 -0500 | [diff] [blame] | 102 | renderPassXferBarriers, colorLoadOp); |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 103 | } |
| 104 | |
Robert Phillips | 7114395 | 2021-06-17 14:55:07 -0400 | [diff] [blame] | 105 | void onPrepareDraws(GrMeshDrawTarget* target) override { |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 106 | if (!fProgramInfo) { |
Robert Phillips | 4133dc4 | 2020-03-11 15:55:55 -0400 | [diff] [blame] | 107 | this->createProgramInfo(target); |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 108 | if (!fProgramInfo) { |
| 109 | return; |
| 110 | } |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 111 | } |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 112 | |
| 113 | int numRegions = fRegions.count(); |
| 114 | int numRects = 0; |
| 115 | for (int i = 0; i < numRegions; i++) { |
| 116 | numRects += fRegions[i].fRegion.computeRegionComplexity(); |
| 117 | } |
| 118 | |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 119 | if (!numRects) { |
| 120 | return; |
| 121 | } |
Robert Phillips | e94cdd2 | 2019-11-04 14:15:58 -0500 | [diff] [blame] | 122 | |
Robert Phillips | 787fd9d | 2021-03-22 14:48:09 -0400 | [diff] [blame] | 123 | QuadHelper helper(target, fProgramInfo->geomProc().vertexStride(), numRects); |
Robert Phillips | e94cdd2 | 2019-11-04 14:15:58 -0500 | [diff] [blame] | 124 | |
Brian Osman | 4486d98 | 2018-11-15 15:56:04 -0500 | [diff] [blame] | 125 | GrVertexWriter vertices{helper.vertices()}; |
Brian Salomon | 12d2264 | 2019-01-29 14:38:50 -0500 | [diff] [blame] | 126 | if (!vertices.fPtr) { |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 127 | SkDebugf("Could not allocate vertices\n"); |
| 128 | return; |
| 129 | } |
| 130 | |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 131 | for (int i = 0; i < numRegions; i++) { |
Brian Osman | 7561dba | 2018-12-27 10:16:18 -0500 | [diff] [blame] | 132 | GrVertexColor color(fRegions[i].fColor, fWideColor); |
Brian Osman | 4486d98 | 2018-11-15 15:56:04 -0500 | [diff] [blame] | 133 | SkRegion::Iterator iter(fRegions[i].fRegion); |
| 134 | while (!iter.done()) { |
| 135 | SkRect rect = SkRect::Make(iter.rect()); |
Brian Osman | 0dd4302 | 2018-11-16 15:53:26 -0500 | [diff] [blame] | 136 | vertices.writeQuad(GrVertexWriter::TriStripFromRect(rect), color); |
Brian Osman | 4486d98 | 2018-11-15 15:56:04 -0500 | [diff] [blame] | 137 | iter.next(); |
| 138 | } |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 139 | } |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 140 | |
| 141 | fMesh = helper.mesh(); |
Chris Dalton | 07cdcfc9 | 2019-02-26 11:13:22 -0700 | [diff] [blame] | 142 | } |
| 143 | |
| 144 | void onExecute(GrOpFlushState* flushState, const SkRect& chainBounds) override { |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 145 | if (!fProgramInfo || !fMesh) { |
| 146 | return; |
| 147 | } |
Robert Phillips | 3968fcb | 2019-12-05 16:40:31 -0500 | [diff] [blame] | 148 | |
Chris Dalton | 765ed36 | 2020-03-16 17:34:44 -0600 | [diff] [blame] | 149 | flushState->bindPipelineAndScissorClip(*fProgramInfo, chainBounds); |
Robert Phillips | 787fd9d | 2021-03-22 14:48:09 -0400 | [diff] [blame] | 150 | flushState->bindTextures(fProgramInfo->geomProc(), nullptr, fProgramInfo->pipeline()); |
Chris Dalton | 765ed36 | 2020-03-16 17:34:44 -0600 | [diff] [blame] | 151 | flushState->drawMesh(*fMesh); |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 152 | } |
| 153 | |
Herb Derby | e25c300 | 2020-10-27 15:57:27 -0400 | [diff] [blame] | 154 | CombineResult onCombineIfPossible(GrOp* t, SkArenaAlloc*, const GrCaps& caps) override { |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 155 | auto that = t->cast<RegionOpImpl>(); |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 156 | if (!fHelper.isCompatible(that->fHelper, caps, this->bounds(), that->bounds())) { |
Brian Salomon | 7eae3e0 | 2018-08-07 14:02:38 +0000 | [diff] [blame] | 157 | return CombineResult::kCannotCombine; |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 158 | } |
| 159 | |
msarett | febb224 | 2016-08-26 12:49:27 -0700 | [diff] [blame] | 160 | if (fViewMatrix != that->fViewMatrix) { |
Brian Salomon | 7eae3e0 | 2018-08-07 14:02:38 +0000 | [diff] [blame] | 161 | return CombineResult::kCannotCombine; |
msarett | febb224 | 2016-08-26 12:49:27 -0700 | [diff] [blame] | 162 | } |
| 163 | |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 164 | fRegions.push_back_n(that->fRegions.count(), that->fRegions.begin()); |
Brian Osman | 7561dba | 2018-12-27 10:16:18 -0500 | [diff] [blame] | 165 | fWideColor |= that->fWideColor; |
Brian Salomon | 7eae3e0 | 2018-08-07 14:02:38 +0000 | [diff] [blame] | 166 | return CombineResult::kMerged; |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 167 | } |
| 168 | |
John Stiles | af36652 | 2020-08-13 09:57:34 -0400 | [diff] [blame] | 169 | #if GR_TEST_UTILS |
| 170 | SkString onDumpInfo() const override { |
| 171 | SkString str = SkStringPrintf("# combined: %d\n", fRegions.count()); |
| 172 | for (int i = 0; i < fRegions.count(); ++i) { |
| 173 | const RegionInfo& info = fRegions[i]; |
| 174 | str.appendf("%d: Color: 0x%08x, Region with %d rects\n", i, info.fColor.toBytes_RGBA(), |
| 175 | info.fRegion.computeRegionComplexity()); |
| 176 | } |
| 177 | str += fHelper.dumpInfo(); |
| 178 | return str; |
| 179 | } |
| 180 | #endif |
| 181 | |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 182 | struct RegionInfo { |
Brian Osman | cf86085 | 2018-10-31 14:04:39 -0400 | [diff] [blame] | 183 | SkPMColor4f fColor; |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 184 | SkRegion fRegion; |
| 185 | }; |
| 186 | |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 187 | Helper fHelper; |
msarett | febb224 | 2016-08-26 12:49:27 -0700 | [diff] [blame] | 188 | SkMatrix fViewMatrix; |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 189 | SkSTArray<1, RegionInfo, true> fRegions; |
Brian Osman | 7561dba | 2018-12-27 10:16:18 -0500 | [diff] [blame] | 190 | bool fWideColor; |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 191 | |
Chris Dalton | eb694b7 | 2020-03-16 09:25:50 -0600 | [diff] [blame] | 192 | GrSimpleMesh* fMesh = nullptr; |
Robert Phillips | d1a8af6 | 2020-03-10 12:50:49 -0400 | [diff] [blame] | 193 | GrProgramInfo* fProgramInfo = nullptr; |
| 194 | |
John Stiles | 7571f9e | 2020-09-02 22:42:33 -0400 | [diff] [blame] | 195 | using INHERITED = GrMeshDrawOp; |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 196 | }; |
| 197 | |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 198 | } // anonymous namespace |
| 199 | |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 200 | namespace skgpu::v1::RegionOp { |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 201 | |
Herb Derby | c76d409 | 2020-10-07 16:46:15 -0400 | [diff] [blame] | 202 | GrOp::Owner Make(GrRecordingContext* context, |
| 203 | GrPaint&& paint, |
| 204 | const SkMatrix& viewMatrix, |
| 205 | const SkRegion& region, |
| 206 | GrAAType aaType, |
| 207 | const GrUserStencilSettings* stencilSettings) { |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 208 | if (aaType != GrAAType::kNone && aaType != GrAAType::kMSAA) { |
| 209 | return nullptr; |
| 210 | } |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 211 | return RegionOpImpl::Make(context, std::move(paint), viewMatrix, region, aaType, |
| 212 | stencilSettings); |
msarett | cc319b9 | 2016-08-25 18:07:18 -0700 | [diff] [blame] | 213 | } |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 214 | |
| 215 | } // namespace skgpu::v1::RegionOp |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 216 | |
| 217 | #if GR_TEST_UTILS |
| 218 | |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 219 | #include "src/gpu/GrDrawOpTest.h" |
| 220 | |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 221 | GR_DRAW_OP_TEST_DEFINE(RegionOp) { |
| 222 | SkRegion region; |
| 223 | int n = random->nextULessThan(200); |
| 224 | for (int i = 0; i < n; ++i) { |
| 225 | SkIPoint center; |
| 226 | center.fX = random->nextULessThan(1000); |
| 227 | center.fY = random->nextULessThan(1000); |
| 228 | int w = random->nextRangeU(10, 1000); |
| 229 | int h = random->nextRangeU(10, 1000); |
| 230 | SkIRect rect = {center.fX - w / 2, center.fY - h / 2, center.fX + w / 2, center.fY + h / 2}; |
| 231 | SkRegion::Op op; |
| 232 | if (i == 0) { |
| 233 | op = SkRegion::kReplace_Op; |
| 234 | } else { |
| 235 | // Pick an other than replace. |
Brian Salomon | 4dea72a | 2019-12-18 10:43:10 -0500 | [diff] [blame] | 236 | static_assert(SkRegion::kLastOp == SkRegion::kReplace_Op); |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 237 | op = (SkRegion::Op)random->nextULessThan(SkRegion::kLastOp); |
| 238 | } |
| 239 | region.op(rect, op); |
| 240 | } |
| 241 | SkMatrix viewMatrix = GrTest::TestMatrix(random); |
| 242 | GrAAType aaType = GrAAType::kNone; |
Chris Dalton | 6ce447a | 2019-06-23 18:07:38 -0600 | [diff] [blame] | 243 | if (numSamples > 1 && random->nextBool()) { |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 244 | aaType = GrAAType::kMSAA; |
| 245 | } |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 246 | return RegionOpImpl::Make(context, std::move(paint), viewMatrix, region, aaType, |
| 247 | GrGetRandomStencil(random, context)); |
Brian Salomon | f036632 | 2017-07-11 15:53:05 -0400 | [diff] [blame] | 248 | } |
| 249 | |
Robert Phillips | cadd5db | 2021-08-30 11:37:18 -0400 | [diff] [blame] | 250 | #endif // GR_TEST_UTILS |