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 | 8 |
9 #include "GrGpu.h" | 9 #include "GrGpu.h" |
10 | 10 |
(...skipping 479 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
490 return specs; | 490 return specs; |
491 } | 491 } |
492 | 492 |
493 //////////////////////////////////////////////////////////////////////////////// | 493 //////////////////////////////////////////////////////////////////////////////// |
494 | 494 |
495 bool GrGpu::draw(const GrPipeline& pipeline, | 495 bool GrGpu::draw(const GrPipeline& pipeline, |
496 const GrPrimitiveProcessor& primProc, | 496 const GrPrimitiveProcessor& primProc, |
497 const GrMesh* meshes, | 497 const GrMesh* meshes, |
498 int meshCount) { | 498 int meshCount) { |
499 if (primProc.numAttribs() > this->caps()->maxVertexAttributes()) { | 499 if (primProc.numAttribs() > this->caps()->maxVertexAttributes()) { |
| 500 fStats.incNumFailedDraws(); |
500 return false; | 501 return false; |
501 } | 502 } |
502 this->handleDirtyContext(); | 503 this->handleDirtyContext(); |
503 | 504 |
504 this->onDraw(pipeline, primProc, meshes, meshCount); | 505 this->onDraw(pipeline, primProc, meshes, meshCount); |
505 return true; | 506 return true; |
506 } | 507 } |
507 | 508 |
OLD | NEW |