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

Unified Diff: src/gpu/GrPath.h

Issue 1116123003: Improve caching of dashed paths in GrStencilAndCoverPathRenderer (Closed) Base URL: https://skia.googlesource.com/skia.git@dashing-nvpr-01
Patch Set: . Created 5 years, 8 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
« no previous file with comments | « no previous file | src/gpu/GrPath.cpp » ('j') | src/gpu/GrPath.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrPath.h
diff --git a/src/gpu/GrPath.h b/src/gpu/GrPath.h
index 27bbdc043982e438e120a7a6cddcf7081e52e456..50ea2102eef71b057cec8ce86edbe685e5737484 100644
--- a/src/gpu/GrPath.h
+++ b/src/gpu/GrPath.h
@@ -9,9 +9,9 @@
#define GrPath_DEFINED
#include "GrGpuResource.h"
+#include "GrStrokeInfo.h"
#include "SkPath.h"
#include "SkRect.h"
-#include "SkStrokeRec.h"
class GrPath : public GrGpuResource {
public:
@@ -20,27 +20,27 @@ public:
/**
* Initialize to a path with a fixed stroke. Stroke must not be hairline.
*/
- GrPath(GrGpu* gpu, const SkPath& skPath, const SkStrokeRec& stroke)
+ GrPath(GrGpu* gpu, const SkPath& skPath, const GrStrokeInfo& stroke)
: INHERITED(gpu, kCached_LifeCycle),
fSkPath(skPath),
fStroke(stroke),
fBounds(skPath.getBounds()) {
}
- static void ComputeKey(const SkPath& path, const SkStrokeRec& stroke, GrUniqueKey* key);
- static uint64_t ComputeStrokeKey(const SkStrokeRec&);
+ static void ComputeKey(const SkPath& path, const GrStrokeInfo& stroke, GrUniqueKey* key);
+ static uint64_t ComputeStrokeKey(const GrStrokeInfo&);
- bool isEqualTo(const SkPath& path, const SkStrokeRec& stroke) {
+ bool isEqualTo(const SkPath& path, const GrStrokeInfo& stroke) {
return fSkPath == path && fStroke == stroke;
}
const SkRect& getBounds() const { return fBounds; }
- const SkStrokeRec& getStroke() const { return fStroke; }
+ const GrStrokeInfo& getStroke() const { return fStroke; }
protected:
SkPath fSkPath;
- SkStrokeRec fStroke;
+ GrStrokeInfo fStroke;
SkRect fBounds;
private:
« no previous file with comments | « no previous file | src/gpu/GrPath.cpp » ('j') | src/gpu/GrPath.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698