diff options
author | 2015-05-05 08:41:50 -0700 | |
---|---|---|
committer | 2015-05-05 08:41:50 -0700 | |
commit | e46760e8b2b2fc4a11a43a3b7cc9da7166c83c46 (patch) | |
tree | 3352ef7702062da1e143d152ac4a2605d1cff84c /src/gpu/GrTargetCommands.h | |
parent | f4e0857fe9e7b606c36302a252f23a790427f899 (diff) |
Create GrCommandBuilder
BUG=skia:
Review URL: https://codereview.chromium.org/1113313003
Diffstat (limited to 'src/gpu/GrTargetCommands.h')
-rw-r--r-- | src/gpu/GrTargetCommands.h | 44 |
1 files changed, 5 insertions, 39 deletions
diff --git a/src/gpu/GrTargetCommands.h b/src/gpu/GrTargetCommands.h index 4dfad2f409..aaecac6989 100644 --- a/src/gpu/GrTargetCommands.h +++ b/src/gpu/GrTargetCommands.h @@ -24,9 +24,6 @@ class GrVertexBufferAllocPool; class GrIndexBufferAllocPool; class GrTargetCommands : ::SkNoncopyable { - struct State; - struct SetState; - public: GrTargetCommands(GrGpu* gpu, GrVertexBufferAllocPool* vertexPool, @@ -68,43 +65,9 @@ public: void reset(); void flush(GrInOrderDrawBuffer*); - Cmd* recordClearStencilClip(const SkIRect& rect, - bool insideClip, - GrRenderTarget* renderTarget); - - Cmd* recordDiscard(GrRenderTarget*); - Cmd* recordDrawBatch(State*, GrBatch*); - Cmd* recordStencilPath(const GrPipelineBuilder&, - const GrPathProcessor*, - const GrPath*, - const GrScissorState&, - const GrStencilSettings&); - Cmd* recordDrawPath(State*, - const GrPathProcessor*, - const GrPath*, - const GrStencilSettings&); - Cmd* recordDrawPaths(State*, - GrInOrderDrawBuffer*, - const GrPathProcessor*, - const GrPathRange*, - const void*, - GrDrawTarget::PathIndexType, - const float transformValues[], - GrDrawTarget::PathTransformType , - int, - const GrStencilSettings&, - const GrDrawTarget::PipelineInfo&); - Cmd* recordClear(const SkIRect* rect, - GrColor, - bool canIgnoreRect, - GrRenderTarget*); - Cmd* recordCopySurface(GrSurface* dst, - GrSurface* src, - const SkIRect& srcRect, - const SkIPoint& dstPoint); - private: - friend class GrInOrderDrawBuffer; + friend class GrCommandBuilder; + friend class GrInOrderDrawBuffer; // This goes away when State becomes just a pipeline typedef GrGpu::DrawArgs DrawArgs; @@ -293,6 +256,9 @@ private: typedef void* TCmdAlign; // This wouldn't be enough align if a command used long double. typedef GrTRecorder<Cmd, TCmdAlign> CmdBuffer; + CmdBuffer* cmdBuffer() { return &fCmdBuffer; } + GrBatchTarget* batchTarget() { return &fBatchTarget; } + CmdBuffer fCmdBuffer; GrBatchTarget fBatchTarget; }; |