OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2010 Google Inc. | 3 * Copyright 2010 Google Inc. |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 | 9 |
10 | 10 |
(...skipping 582 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
593 * Number of bits of stencil per-pixel. | 593 * Number of bits of stencil per-pixel. |
594 */ | 594 */ |
595 int fStencilBits; | 595 int fStencilBits; |
596 /** | 596 /** |
597 * Handle to the 3D API object. | 597 * Handle to the 3D API object. |
598 * OpenGL: FBO ID | 598 * OpenGL: FBO ID |
599 */ | 599 */ |
600 GrBackendObject fRenderTargetHandle; | 600 GrBackendObject fRenderTargetHandle; |
601 }; | 601 }; |
602 | 602 |
| 603 /** |
| 604 * The GrContext's cache of backend context state can be partially invalidated. |
| 605 * These enums are specific to the GL backend and we'd add a new set for an alte
rnative backend. |
| 606 */ |
| 607 enum GrGLBackendState { |
| 608 kRenderTarget_GrGLBackendState = 1 << 0, |
| 609 kTextureBinding_GrGLBackendState = 1 << 1, |
| 610 // View state stands for scissor and viewport |
| 611 kView_GrGLBackendState = 1 << 2, |
| 612 kBlend_GrGLBackendState = 1 << 3, |
| 613 kAA_GrGLBackendState = 1 << 4, |
| 614 kVertex_GrGLBackendState = 1 << 5, |
| 615 kStencil_GrGLBackendState = 1 << 6, |
| 616 kPixelStore_GrGLBackendState = 1 << 7, |
| 617 kProgram_GrGLBackendState = 1 << 8, |
| 618 kPathStencil_GrGLBackendState = 1 << 9, |
| 619 kMisc_GrGLBackendState = 1 << 10, |
| 620 kALL_GrGLBackendState = 0xffff |
| 621 }; |
| 622 |
| 623 /** |
| 624 * This value translates to reseting all the context state for any backend. |
| 625 */ |
| 626 static const uint32_t kAll_GrBackendState = 0xffffffff; |
| 627 |
603 /////////////////////////////////////////////////////////////////////////////// | 628 /////////////////////////////////////////////////////////////////////////////// |
604 | 629 |
605 #endif | 630 #endif |
OLD | NEW |