Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(671)

Unified Diff: src/gpu/effects/GrConvexPolyEffect.cpp

Issue 1176953002: move SkPath direction-as-computed into SkPathPriv (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/gpu/effects/GrConvexPolyEffect.cpp
diff --git a/src/gpu/effects/GrConvexPolyEffect.cpp b/src/gpu/effects/GrConvexPolyEffect.cpp
index 0cef3fa8d62c9bd7adacfe5bca04ae0d596e34d1..004827904477d46c0d042f10c767a9e7660d23c3 100644
--- a/src/gpu/effects/GrConvexPolyEffect.cpp
+++ b/src/gpu/effects/GrConvexPolyEffect.cpp
@@ -7,7 +7,7 @@
#include "GrConvexPolyEffect.h"
#include "GrInvariantOutput.h"
-#include "SkPath.h"
+#include "SkPathPriv.h"
#include "gl/GrGLProcessor.h"
#include "gl/GrGLSL.h"
#include "gl/builders/GrGLProgramBuilder.h"
@@ -279,8 +279,8 @@ GrFragmentProcessor* GrConvexPolyEffect::Create(GrPrimitiveEdgeType type, const
SkPoint pts[kMaxEdges];
SkScalar edges[3 * kMaxEdges];
- SkPath::Direction dir;
- SkAssertResult(path.cheapComputeDirection(&dir));
+ SkPathPriv::FirstDirection dir;
+ SkAssertResult(SkPathPriv::CheapComputeFirstDirection(path, &dir));
SkVector t;
if (NULL == offset) {
@@ -295,7 +295,7 @@ GrFragmentProcessor* GrConvexPolyEffect::Create(GrPrimitiveEdgeType type, const
if (pts[lastPt] != pts[i]) {
SkVector v = pts[i] - pts[lastPt];
v.normalize();
- if (SkPath::kCCW_Direction == dir) {
+ if (SkPathPriv::kCCW_FirstDirection == dir) {
edges[3 * n] = v.fY;
edges[3 * n + 1] = -v.fX;
} else {

Powered by Google App Engine
This is Rietveld 408576698