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

Unified Diff: src/gpu/GrInOrderDrawBuffer.cpp

Issue 18341007: Minor GrContext/GrInOrderDrawBuffer cleanup (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 6 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 | « src/gpu/GrInOrderDrawBuffer.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrInOrderDrawBuffer.cpp
===================================================================
--- src/gpu/GrInOrderDrawBuffer.cpp (revision 9893)
+++ src/gpu/GrInOrderDrawBuffer.cpp (working copy)
@@ -445,15 +445,18 @@
fClipSet = true;
}
-bool GrInOrderDrawBuffer::flush() {
+void GrInOrderDrawBuffer::flush() {
+ if (fFlushing) {
+ return;
+ }
+
GrAssert(kReserved_GeometrySrcType != this->getGeomSrc().fVertexSrc);
GrAssert(kReserved_GeometrySrcType != this->getGeomSrc().fIndexSrc);
int numCmds = fCmds.count();
if (0 == numCmds) {
- return false;
+ return;
}
- GrAssert(!fFlushing);
bsalomon 2013/07/03 18:34:21 Is this assertion no longer valid?
robertphillips 2013/07/03 18:37:45 It shouldn't ever fire since we are returning at t
GrAutoTRestore<bool> flushRestore(&fFlushing);
fFlushing = true;
@@ -533,7 +536,6 @@
fDstGpu->setDrawState(prevDrawState);
prevDrawState->unref();
this->reset();
- return true;
}
bool GrInOrderDrawBuffer::onCopySurface(GrSurface* dst,
« no previous file with comments | « src/gpu/GrInOrderDrawBuffer.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698