Index: src/gpu/GrInOrderDrawBuffer.h |
diff --git a/src/gpu/GrInOrderDrawBuffer.h b/src/gpu/GrInOrderDrawBuffer.h |
index dcc5ab7e0bcdb080e97fbae2872e0e78e833ea0f..040a8a04557863936003ccf51a61fcc6e6a58fb7 100644 |
--- a/src/gpu/GrInOrderDrawBuffer.h |
+++ b/src/gpu/GrInOrderDrawBuffer.h |
@@ -89,6 +89,7 @@ private: |
kSetClip_Cmd = 4, |
kClear_Cmd = 5, |
kCopySurface_Cmd = 6, |
+ kDrawPath_Cmd = 7, |
}; |
class DrawRecord : public DrawInfo { |
@@ -106,6 +107,14 @@ private: |
SkPath::FillType fFill; |
}; |
+ struct DrawPath : GrNoncopyable { |
+ DrawPath(); |
+ |
+ SkAutoTUnref<const GrPath> fPath; |
+ SkStrokeRec fStroke; |
+ SkPath::FillType fFill; |
+ }; |
+ |
struct Clear : GrNoncopyable { |
Clear() : fRenderTarget(NULL) {} |
~Clear() { SkSafeUnref(fRenderTarget); } |
@@ -129,6 +138,7 @@ private: |
const SkRect* localRect, |
const SkMatrix* localMatrix) SK_OVERRIDE; |
virtual void onStencilPath(const GrPath*, const SkStrokeRec& stroke, SkPath::FillType) SK_OVERRIDE; |
+ virtual void onDrawPath(const GrPath*, const SkStrokeRec& stroke, SkPath::FillType) SK_OVERRIDE; |
virtual bool onReserveVertexSpace(size_t vertexSize, |
int vertexCount, |
void** vertices) SK_OVERRIDE; |
@@ -171,6 +181,7 @@ private: |
void recordClip(); |
DrawRecord* recordDraw(const DrawInfo&); |
StencilPath* recordStencilPath(); |
+ DrawPath* recordDrawPath(); |
bsalomon
2013/09/13 20:25:28
space
Kimmo Kinnunen
2013/09/18 07:52:38
Done.
|
Clear* recordClear(); |
CopySurface* recordCopySurface(); |
@@ -179,6 +190,7 @@ private: |
kCmdPreallocCnt = 32, |
kDrawPreallocCnt = 8, |
kStencilPathPreallocCnt = 8, |
+ kDrawPathPreallocCnt = 8, |
bsalomon
2013/09/13 20:25:28
space
Kimmo Kinnunen
2013/09/18 07:52:38
Done.
|
kStatePreallocCnt = 8, |
kClipPreallocCnt = 8, |
kClearPreallocCnt = 4, |
@@ -189,6 +201,7 @@ private: |
SkSTArray<kCmdPreallocCnt, uint8_t, true> fCmds; |
GrSTAllocator<kDrawPreallocCnt, DrawRecord> fDraws; |
GrSTAllocator<kStatePreallocCnt, StencilPath> fStencilPaths; |
+ GrSTAllocator<kStatePreallocCnt, DrawPath> fDrawPaths; |
GrSTAllocator<kStatePreallocCnt, GrDrawState::DeferredState> fStates; |
GrSTAllocator<kClearPreallocCnt, Clear> fClears; |
GrSTAllocator<kCopySurfacePreallocCnt, CopySurface> fCopySurfaces; |