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

Side by Side Diff: bench/GLVec4ScalarBench.cpp

Issue 1316233002: Style Change: NULL->nullptr (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-27 (Thursday) 10:25:06 EDT Created 5 years, 3 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 | « bench/GLInstancedArraysBench.cpp ('k') | bench/GameBench.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 2015 Google Inc. 2 * Copyright 2015 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 "SkMatrix.h" 8 #include "SkMatrix.h"
9 #include "SkPoint.h" 9 #include "SkPoint.h"
10 #include "SkString.h" 10 #include "SkString.h"
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 GR_GL_CALL(gl, VertexAttribPointer(0, 2, GR_GL_FLOAT, GR_GL_FALSE, sizeof(Ve rtex), 239 GR_GL_CALL(gl, VertexAttribPointer(0, 2, GR_GL_FLOAT, GR_GL_FALSE, sizeof(Ve rtex),
240 (GrGLvoid*)0)); 240 (GrGLvoid*)0));
241 GR_GL_CALL(gl, VertexAttribPointer(1, 3, GR_GL_FLOAT, GR_GL_FALSE, sizeof(Ve rtex), 241 GR_GL_CALL(gl, VertexAttribPointer(1, 3, GR_GL_FLOAT, GR_GL_FALSE, sizeof(Ve rtex),
242 (GrGLvoid*)(sizeof(SkPoint)))); 242 (GrGLvoid*)(sizeof(SkPoint))));
243 GR_GL_CALL(gl, BufferData(GR_GL_ARRAY_BUFFER, sizeof(vertices), vertices, GR _GL_STATIC_DRAW)); 243 GR_GL_CALL(gl, BufferData(GR_GL_ARRAY_BUFFER, sizeof(vertices), vertices, GR _GL_STATIC_DRAW));
244 } 244 }
245 245
246 void GLVec4ScalarBench::setup(const GrGLContext* ctx) { 246 void GLVec4ScalarBench::setup(const GrGLContext* ctx) {
247 const GrGLInterface* gl = ctx->interface(); 247 const GrGLInterface* gl = ctx->interface();
248 if (!gl) { 248 if (!gl) {
249 SkFAIL("GL interface is NULL in setup()!\n"); 249 SkFAIL("GL interface is nullptr in setup()!\n");
250 } 250 }
251 fFboTextureId = SetupFramebuffer(gl, kScreenWidth, kScreenHeight); 251 fFboTextureId = SetupFramebuffer(gl, kScreenWidth, kScreenHeight);
252 252
253 fProgram = this->setupShader(ctx); 253 fProgram = this->setupShader(ctx);
254 254
255 int index = 0; 255 int index = 0;
256 SkMatrix viewMatrices[kNumTriPerDraw]; 256 SkMatrix viewMatrices[kNumTriPerDraw];
257 setup_matrices(kNumTriPerDraw, [&index, &viewMatrices](const SkMatrix& m) { 257 setup_matrices(kNumTriPerDraw, [&index, &viewMatrices](const SkMatrix& m) {
258 viewMatrices[index++] = m; 258 viewMatrices[index++] = m;
259 }); 259 });
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseScalar_CoverageSe tup, 2) ) 294 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseScalar_CoverageSe tup, 2) )
295 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseVec4_CoverageSetu p, 2) ) 295 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseVec4_CoverageSetu p, 2) )
296 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseScalar_CoverageSe tup, 4) ) 296 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseScalar_CoverageSe tup, 4) )
297 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseVec4_CoverageSetu p, 4) ) 297 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseVec4_CoverageSetu p, 4) )
298 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseScalar_CoverageSe tup, 6) ) 298 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseScalar_CoverageSe tup, 6) )
299 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseVec4_CoverageSetu p, 6) ) 299 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseVec4_CoverageSetu p, 6) )
300 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseScalar_CoverageSe tup, 8) ) 300 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseScalar_CoverageSe tup, 8) )
301 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseVec4_CoverageSetu p, 8) ) 301 DEF_BENCH( return new GLVec4ScalarBench(GLVec4ScalarBench::kUseVec4_CoverageSetu p, 8) )
302 302
303 #endif 303 #endif
OLDNEW
« no previous file with comments | « bench/GLInstancedArraysBench.cpp ('k') | bench/GameBench.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698