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

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

Issue 1300123002: Use calloc to allocate data that will be uploaded to vertex/index buffers in Chrome (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Address comment Created 5 years, 4 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/GrGLBufferImpl.cpp ('k') | no next file » | 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 2012 Google Inc. 2 * Copyright 2012 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 "GrGLCaps.h" 9 #include "GrGLCaps.h"
10 10
(...skipping 453 matching lines...) Expand 10 before | Expand all | Expand 10 after
464 if (kPowerVR54x_GrGLRenderer == ctxInfo.renderer() || 464 if (kPowerVR54x_GrGLRenderer == ctxInfo.renderer() ||
465 kPowerVRRogue_GrGLRenderer == ctxInfo.renderer() || 465 kPowerVRRogue_GrGLRenderer == ctxInfo.renderer() ||
466 kAdreno3xx_GrGLRenderer == ctxInfo.renderer()) { 466 kAdreno3xx_GrGLRenderer == ctxInfo.renderer()) {
467 fUseDrawInsteadOfClear = true; 467 fUseDrawInsteadOfClear = true;
468 } 468 }
469 469
470 if (kAdreno4xx_GrGLRenderer == ctxInfo.renderer()) { 470 if (kAdreno4xx_GrGLRenderer == ctxInfo.renderer()) {
471 fUseDrawInsteadOfPartialRenderTargetWrite = true; 471 fUseDrawInsteadOfPartialRenderTargetWrite = true;
472 } 472 }
473 473
474 if (kChromium_GrGLDriver == ctxInfo.driver()) {
475 fMustClearUploadedBufferData = true;
476 }
477
474 if (kGL_GrGLStandard == standard) { 478 if (kGL_GrGLStandard == standard) {
475 // ARB allows mixed size FBO attachments, EXT does not. 479 // ARB allows mixed size FBO attachments, EXT does not.
476 if (ctxInfo.version() >= GR_GL_VER(3, 0) || 480 if (ctxInfo.version() >= GR_GL_VER(3, 0) ||
477 ctxInfo.hasExtension("GL_ARB_framebuffer_object")) { 481 ctxInfo.hasExtension("GL_ARB_framebuffer_object")) {
478 fOversizedStencilSupport = true; 482 fOversizedStencilSupport = true;
479 } else { 483 } else {
480 SkASSERT(ctxInfo.hasExtension("GL_EXT_framebuffer_object")); 484 SkASSERT(ctxInfo.hasExtension("GL_EXT_framebuffer_object"));
481 } 485 }
482 } else { 486 } else {
483 // ES 3.0 supports mixed size FBO attachments, 2.0 does not. 487 // ES 3.0 supports mixed size FBO attachments, 2.0 does not.
(...skipping 744 matching lines...) Expand 10 before | Expand all | Expand 10 after
1228 for (int p = 0; p < kGrSLPrecisionCount; ++p) { 1232 for (int p = 0; p < kGrSLPrecisionCount; ++p) {
1229 glslCaps->fFloatPrecisions[kGeometry_GrShaderType][p] = 1233 glslCaps->fFloatPrecisions[kGeometry_GrShaderType][p] =
1230 glslCaps->fFloatPrecisions[kVerte x_GrShaderType][p]; 1234 glslCaps->fFloatPrecisions[kVerte x_GrShaderType][p];
1231 } 1235 }
1232 } 1236 }
1233 } 1237 }
1234 1238
1235 1239
1236 1240
1237 1241
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGLBufferImpl.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698