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

Side by Side Diff: src/gpu/GrInOrderDrawBuffer.cpp

Issue 876673002: Hairline batch (Closed) Base URL: https://skia.googlesource.com/skia.git@2_defer
Patch Set: update Created 5 years, 10 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "GrInOrderDrawBuffer.h" 8 #include "GrInOrderDrawBuffer.h"
9 9
10 #include "GrBufferAllocPool.h" 10 #include "GrBufferAllocPool.h"
(...skipping 455 matching lines...) Expand 10 before | Expand all | Expand 10 after
466 SkString traceString; 466 SkString traceString;
467 if (cmd_has_trace_marker(iter->fType)) { 467 if (cmd_has_trace_marker(iter->fType)) {
468 traceString = fGpuCmdMarkers[currCmdMarker].toString(); 468 traceString = fGpuCmdMarkers[currCmdMarker].toString();
469 newMarker.fMarker = traceString.c_str(); 469 newMarker.fMarker = traceString.c_str();
470 this->getGpu()->addGpuTraceMarker(&newMarker); 470 this->getGpu()->addGpuTraceMarker(&newMarker);
471 ++currCmdMarker; 471 ++currCmdMarker;
472 } 472 }
473 473
474 // TODO temporary hack 474 // TODO temporary hack
475 if (kDrawBatch_Cmd == strip_trace_bit(iter->fType)) { 475 if (kDrawBatch_Cmd == strip_trace_bit(iter->fType)) {
476 fBatchTarget.flushNext(); 476 DrawBatch* db = reinterpret_cast<DrawBatch*>(iter.get());
477 fBatchTarget.flushNext(db->fBatch->batchesGenerated());
477 continue; 478 continue;
478 } 479 }
479 480
480 bool isSetState = kSetState_Cmd == strip_trace_bit(iter->fType); 481 bool isSetState = kSetState_Cmd == strip_trace_bit(iter->fType);
481 if (isSetState) { 482 if (isSetState) {
482 SetState* ss = reinterpret_cast<SetState*>(iter.get()); 483 SetState* ss = reinterpret_cast<SetState*>(iter.get());
483 484
484 // TODO sometimes we have a prim proc, othertimes we have a GrBatch. Eventually we will 485 // TODO sometimes we have a prim proc, othertimes we have a GrBatch. Eventually we will
485 // only have GrBatch and we can delete this 486 // only have GrBatch and we can delete this
486 if (ss->fPrimitiveProcessor) { 487 if (ss->fPrimitiveProcessor) {
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
675 int vcount = vertexCount; 676 int vcount = vertexCount;
676 int icount = indexCount; 677 int icount = indexCount;
677 678
678 if (!insideGeoPush && 679 if (!insideGeoPush &&
679 !unreleasedVertexSpace && 680 !unreleasedVertexSpace &&
680 !unreleasedIndexSpace && 681 !unreleasedIndexSpace &&
681 this->geometryHints(vertexStride, &vcount, &icount)) { 682 this->geometryHints(vertexStride, &vcount, &icount)) {
682 this->flush(); 683 this->flush();
683 } 684 }
684 } 685 }
OLDNEW
« src/gpu/GrAAHairLinePathRenderer.cpp ('K') | « src/gpu/GrBatchTarget.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698