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

Side by Side Diff: src/gpu/gl/GrGLIndexBuffer.cpp

Issue 846303002: Make uncached textures uncached from the get go. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Add comment Created 5 years, 11 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 | « src/gpu/gl/GrGLGpu.cpp ('k') | src/gpu/gl/GrGLPath.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 #include "GrGLIndexBuffer.h" 8 #include "GrGLIndexBuffer.h"
9 #include "GrGLGpu.h" 9 #include "GrGLGpu.h"
10 10
11 GrGLIndexBuffer::GrGLIndexBuffer(GrGLGpu* gpu, const Desc& desc) 11 GrGLIndexBuffer::GrGLIndexBuffer(GrGLGpu* gpu, const Desc& desc)
12 : INHERITED(gpu, desc.fIsWrapped, desc.fSizeInBytes, desc.fDynamic, 0 == des c.fID) 12 : INHERITED(gpu, desc.fSizeInBytes, desc.fDynamic, 0 == desc.fID)
13 , fImpl(gpu, desc, GR_GL_ELEMENT_ARRAY_BUFFER) { 13 , fImpl(gpu, desc, GR_GL_ELEMENT_ARRAY_BUFFER) {
14 this->registerWithCache(); 14 this->registerWithCache();
15 } 15 }
16 16
17 void GrGLIndexBuffer::onRelease() { 17 void GrGLIndexBuffer::onRelease() {
18 if (!this->wasDestroyed()) { 18 if (!this->wasDestroyed()) {
19 fImpl.release(this->getGpuGL()); 19 fImpl.release(this->getGpuGL());
20 } 20 }
21 21
22 INHERITED::onRelease(); 22 INHERITED::onRelease();
(...skipping 18 matching lines...) Expand all
41 } 41 }
42 } 42 }
43 43
44 bool GrGLIndexBuffer::onUpdateData(const void* src, size_t srcSizeInBytes) { 44 bool GrGLIndexBuffer::onUpdateData(const void* src, size_t srcSizeInBytes) {
45 if (!this->wasDestroyed()) { 45 if (!this->wasDestroyed()) {
46 return fImpl.updateData(this->getGpuGL(), src, srcSizeInBytes); 46 return fImpl.updateData(this->getGpuGL(), src, srcSizeInBytes);
47 } else { 47 } else {
48 return false; 48 return false;
49 } 49 }
50 } 50 }
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLGpu.cpp ('k') | src/gpu/gl/GrGLPath.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698