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

Side by Side Diff: src/gpu/gl/GrGLGpu.h

Issue 1137093002: Remove GrGLVertexArray from GrGpuResource hierarchy. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix nit Created 5 years, 7 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
« no previous file with comments | « no previous file | src/gpu/gl/GrGLGpu.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #ifndef GrGLGpu_DEFINED 8 #ifndef GrGLGpu_DEFINED
9 #define GrGLGpu_DEFINED 9 #define GrGLGpu_DEFINED
10 10
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after
329 329
330 GrGLIRect fHWViewport; 330 GrGLIRect fHWViewport;
331 331
332 /** 332 /**
333 * Tracks bound vertex and index buffers and vertex attrib array state. 333 * Tracks bound vertex and index buffers and vertex attrib array state.
334 */ 334 */
335 class HWGeometryState { 335 class HWGeometryState {
336 public: 336 public:
337 HWGeometryState() { fVBOVertexArray = NULL; this->invalidate(); } 337 HWGeometryState() { fVBOVertexArray = NULL; this->invalidate(); }
338 338
339 ~HWGeometryState() { SkSafeUnref(fVBOVertexArray); } 339 ~HWGeometryState() { SkDELETE(fVBOVertexArray); }
340 340
341 void invalidate() { 341 void invalidate() {
342 fBoundVertexArrayIDIsValid = false; 342 fBoundVertexArrayIDIsValid = false;
343 fBoundVertexBufferIDIsValid = false; 343 fBoundVertexBufferIDIsValid = false;
344 fDefaultVertexArrayBoundIndexBufferID = false; 344 fDefaultVertexArrayBoundIndexBufferID = false;
345 fDefaultVertexArrayBoundIndexBufferIDIsValid = false; 345 fDefaultVertexArrayBoundIndexBufferIDIsValid = false;
346 fDefaultVertexArrayAttribState.invalidate(); 346 fDefaultVertexArrayAttribState.invalidate();
347 if (fVBOVertexArray) { 347 if (fVBOVertexArray) {
348 fVBOVertexArray->invalidateCachedState(); 348 fVBOVertexArray->invalidateCachedState();
349 } 349 }
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
470 470
471 // we record what stencil format worked last time to hopefully exit early 471 // we record what stencil format worked last time to hopefully exit early
472 // from our loop that tries stencil formats and calls check fb status. 472 // from our loop that tries stencil formats and calls check fb status.
473 int fLastSuccessfulStencilFmtIdx; 473 int fLastSuccessfulStencilFmtIdx;
474 474
475 typedef GrGpu INHERITED; 475 typedef GrGpu INHERITED;
476 friend class GrGLPathRendering; // For accessing setTextureUnit. 476 friend class GrGLPathRendering; // For accessing setTextureUnit.
477 }; 477 };
478 478
479 #endif 479 #endif
OLDNEW
« no previous file with comments | « no previous file | src/gpu/gl/GrGLGpu.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698