| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2010 Google Inc. | 2 * Copyright 2010 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 "GrDrawTarget.h" | 8 #include "GrDrawTarget.h" |
| 9 | 9 |
| 10 #include "GrAuditTrail.h" | 10 #include "GrAuditTrail.h" |
| (...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 void GrDrawTarget::dump() const { | 107 void GrDrawTarget::dump() const { |
| 108 SkDebugf("--------------------------------------------------------------\n")
; | 108 SkDebugf("--------------------------------------------------------------\n")
; |
| 109 SkDebugf("node: %d -> RT: %d\n", fDebugID, fRenderTarget ? fRenderTarget->ge
tUniqueID() : -1); | 109 SkDebugf("node: %d -> RT: %d\n", fDebugID, fRenderTarget ? fRenderTarget->ge
tUniqueID() : -1); |
| 110 SkDebugf("relies On (%d): ", fDependencies.count()); | 110 SkDebugf("relies On (%d): ", fDependencies.count()); |
| 111 for (int i = 0; i < fDependencies.count(); ++i) { | 111 for (int i = 0; i < fDependencies.count(); ++i) { |
| 112 SkDebugf("%d, ", fDependencies[i]->fDebugID); | 112 SkDebugf("%d, ", fDependencies[i]->fDebugID); |
| 113 } | 113 } |
| 114 SkDebugf("\n"); | 114 SkDebugf("\n"); |
| 115 SkDebugf("batches (%d):\n", fBatches.count()); | 115 SkDebugf("batches (%d):\n", fBatches.count()); |
| 116 for (int i = 0; i < fBatches.count(); ++i) { | 116 for (int i = 0; i < fBatches.count(); ++i) { |
| 117 #if 0 | |
| 118 SkDebugf("*******************************\n"); | 117 SkDebugf("*******************************\n"); |
| 119 #endif | 118 if (!fBatches[i]) { |
| 120 if (fBatches[i]) { | |
| 121 SkDebugf("%d: <combined forward>\n", i); | 119 SkDebugf("%d: <combined forward>\n", i); |
| 122 } else { | 120 } else { |
| 123 SkDebugf("%d: %s\n", i, fBatches[i]->name()); | 121 SkDebugf("%d: %s\n", i, fBatches[i]->name()); |
| 124 #if 0 | |
| 125 SkString str = fBatches[i]->dumpInfo(); | 122 SkString str = fBatches[i]->dumpInfo(); |
| 126 SkDebugf("%s\n", str.c_str()); | 123 SkDebugf("%s\n", str.c_str()); |
| 127 #endif | |
| 128 } | 124 } |
| 129 } | 125 } |
| 130 } | 126 } |
| 131 #endif | 127 #endif |
| 132 | 128 |
| 133 bool GrDrawTarget::setupDstReadIfNecessary(const GrPipelineBuilder& pipelineBuil
der, | 129 bool GrDrawTarget::setupDstReadIfNecessary(const GrPipelineBuilder& pipelineBuil
der, |
| 134 GrRenderTarget* rt, | 130 GrRenderTarget* rt, |
| 135 const GrClip& clip, | 131 const GrClip& clip, |
| 136 const GrPipelineOptimizations& optimi
zations, | 132 const GrPipelineOptimizations& optimi
zations, |
| 137 GrXferProcessor::DstTexture* dstTextu
re, | 133 GrXferProcessor::DstTexture* dstTextu
re, |
| (...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 555 } | 551 } |
| 556 } | 552 } |
| 557 | 553 |
| 558 /////////////////////////////////////////////////////////////////////////////// | 554 /////////////////////////////////////////////////////////////////////////////// |
| 559 | 555 |
| 560 void GrDrawTarget::clearStencilClip(const SkIRect& rect, bool insideClip, GrRend
erTarget* rt) { | 556 void GrDrawTarget::clearStencilClip(const SkIRect& rect, bool insideClip, GrRend
erTarget* rt) { |
| 561 GrBatch* batch = new GrClearStencilClipBatch(rect, insideClip, rt); | 557 GrBatch* batch = new GrClearStencilClipBatch(rect, insideClip, rt); |
| 562 this->recordBatch(batch); | 558 this->recordBatch(batch); |
| 563 batch->unref(); | 559 batch->unref(); |
| 564 } | 560 } |
| OLD | NEW |