1 /* 2 * Copyright 2014 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 8 #ifndef DashOp_DEFINED 9 #define DashOp_DEFINED 10 11 #include "include/gpu/GrTypes.h" 12 #include "src/gpu/ops/GrOp.h" 13 14 class GrPaint; 15 class GrRecordingContext; 16 class GrStyle; 17 struct GrUserStencilSettings; 18 19 namespace skgpu::v1::DashOp { 20 21 enum class AAMode { 22 kNone, 23 kCoverage, 24 kCoverageWithMSAA, 25 }; 26 27 GrOp::Owner MakeDashLineOp(GrRecordingContext*, 28 GrPaint&&, 29 const SkMatrix& viewMatrix, 30 const SkPoint pts[2], 31 AAMode, 32 const GrStyle& style, 33 const GrUserStencilSettings*); 34 bool CanDrawDashLine(const SkPoint pts[2], const GrStyle& style, const SkMatrix& viewMatrix); 35 36 } // namespace skgpu::v1::DashOp 37 38 #endif // DashOp_DEFINED 39