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

Unified Diff: src/gpu/GrDefaultGeoProcFactory.h

Issue 1257333002: Change GrDefaultGeoProcFactory to a namespace (Closed) Base URL: https://skia.googlesource.com/skia.git@localcoordscleanup
Patch Set: Created 5 years, 5 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/GrDefaultGeoProcFactory.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrDefaultGeoProcFactory.h
diff --git a/src/gpu/GrDefaultGeoProcFactory.h b/src/gpu/GrDefaultGeoProcFactory.h
index 243685439d6eebc7843689be3587d67c5cdc5a94..bdefd4a920de446148afcbecaa57e8c77f17bd6c 100644
--- a/src/gpu/GrDefaultGeoProcFactory.h
+++ b/src/gpu/GrDefaultGeoProcFactory.h
@@ -18,8 +18,7 @@ class GrDrawState;
* used in the creation of optimized draw states because adding default GPs to the drawstate can
* interfere with batching due to updating the drawstate.
*/
-class GrDefaultGeoProcFactory {
-public:
+namespace GrDefaultGeoProcFactory {
// Structs for adding vertex attributes
struct PositionAttr {
SkPoint fPosition;
@@ -125,31 +124,31 @@ public:
const SkMatrix* fMatrix;
};
- static const GrGeometryProcessor* Create(const Color&,
- const Coverage&,
- const LocalCoords&,
- const SkMatrix& viewMatrix = SkMatrix::I());
+ const GrGeometryProcessor* Create(const Color&,
+ const Coverage&,
+ const LocalCoords&,
+ const SkMatrix& viewMatrix = SkMatrix::I());
/*
* Use this factory to create a GrGeometryProcessor that expects a device space vertex position
* attribute. The view matrix must still be provided to compute correctly transformed
* coordinates for GrFragmentProcessors. It may fail if the view matrix is not invertible.
*/
- static const GrGeometryProcessor* CreateForDeviceSpace(const Color&,
- const Coverage&,
- const LocalCoords&,
- const SkMatrix& viewMatrix);
+ const GrGeometryProcessor* CreateForDeviceSpace(const Color&,
+ const Coverage&,
+ const LocalCoords&,
+ const SkMatrix& viewMatrix);
// TODO deprecate this
- static const GrGeometryProcessor* Create(uint32_t gpTypeFlags,
- GrColor,
- bool localCoordsWillBeRead,
- bool coverageWillBeIgnored,
- const SkMatrix& viewMatrix = SkMatrix::I(),
- const SkMatrix& localMatrix = SkMatrix::I(),
- uint8_t coverage = 0xff);
-
- static size_t DefaultVertexStride() { return sizeof(PositionAttr); }
+ const GrGeometryProcessor* Create(uint32_t gpTypeFlags,
+ GrColor,
+ bool localCoordsWillBeRead,
+ bool coverageWillBeIgnored,
+ const SkMatrix& viewMatrix = SkMatrix::I(),
+ const SkMatrix& localMatrix = SkMatrix::I(),
+ uint8_t coverage = 0xff);
+
+ inline size_t DefaultVertexStride() { return sizeof(PositionAttr); }
};
#endif
« no previous file with comments | « no previous file | src/gpu/GrDefaultGeoProcFactory.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698