diff options
author | 2015-08-12 11:14:50 -0700 | |
---|---|---|
committer | 2015-08-12 11:14:50 -0700 | |
commit | cb02b38b2c48bfde333ce3c699dd0451e2d867fa (patch) | |
tree | fe4c1f40874588934ae4b07405dcdc9fc456bfa8 /src/gpu/GrGpu.cpp | |
parent | 6028a8476504022fe40b6870b1460b5e4a80969f (diff) |
Check for xfer barriers in GrBatch, auto-issue barriers in GrGpu
Review URL: https://codereview.chromium.org/1287973003
Diffstat (limited to 'src/gpu/GrGpu.cpp')
-rw-r--r-- | src/gpu/GrGpu.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gpu/GrGpu.cpp b/src/gpu/GrGpu.cpp index 64016cf441..9c468e7f42 100644 --- a/src/gpu/GrGpu.cpp +++ b/src/gpu/GrGpu.cpp @@ -14,6 +14,7 @@ #include "GrGpuResourcePriv.h" #include "GrIndexBuffer.h" #include "GrPathRendering.h" +#include "GrPipeline.h" #include "GrResourceCache.h" #include "GrRenderTargetPriv.h" #include "GrStencilAttachment.h" @@ -381,6 +382,10 @@ void GrGpu::removeGpuTraceMarker(const GrGpuTraceMarker* marker) { void GrGpu::draw(const DrawArgs& args, const GrVertices& vertices) { this->handleDirtyContext(); + if (GrXferBarrierType barrierType = args.fPipeline->xferBarrierType(*this->caps())) { + this->xferBarrier(args.fPipeline->getRenderTarget(), barrierType); + } + GrVertices::Iterator iter; const GrNonInstancedVertices* verts = iter.init(vertices); do { |