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

Side by Side Diff: bench/GLInstancedArraysBench.cpp

Issue 1237563005: Small fix for visualbench (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: tweaks Created 5 years, 5 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 | bench/GLVertexAttributesBench.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 "Benchmark.h" 8 #include "Benchmark.h"
9 #include "SkCanvas.h" 9 #include "SkCanvas.h"
10 #include "SkImageEncoder.h" 10 #include "SkImageEncoder.h"
(...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after
370 370
371 void GLCpuPosInstancedArraysBench::teardown(const GrGLInterface* gl) { 371 void GLCpuPosInstancedArraysBench::teardown(const GrGLInterface* gl) {
372 GR_GL_CALL(gl, BindBuffer(GR_GL_ARRAY_BUFFER, 0)); 372 GR_GL_CALL(gl, BindBuffer(GR_GL_ARRAY_BUFFER, 0));
373 GR_GL_CALL(gl, BindVertexArray(0)); 373 GR_GL_CALL(gl, BindVertexArray(0));
374 GR_GL_CALL(gl, BindTexture(GR_GL_TEXTURE_2D, 0)); 374 GR_GL_CALL(gl, BindTexture(GR_GL_TEXTURE_2D, 0));
375 GR_GL_CALL(gl, BindFramebuffer(GR_GL_FRAMEBUFFER, 0)); 375 GR_GL_CALL(gl, BindFramebuffer(GR_GL_FRAMEBUFFER, 0));
376 GR_GL_CALL(gl, DeleteTextures(1, &fTexture)); 376 GR_GL_CALL(gl, DeleteTextures(1, &fTexture));
377 GR_GL_CALL(gl, DeleteProgram(fProgram)); 377 GR_GL_CALL(gl, DeleteProgram(fProgram));
378 GR_GL_CALL(gl, DeleteBuffers(fBuffers.count(), fBuffers.begin())); 378 GR_GL_CALL(gl, DeleteBuffers(fBuffers.count(), fBuffers.begin()));
379 GR_GL_CALL(gl, DeleteVertexArrays(1, &fVAO)); 379 GR_GL_CALL(gl, DeleteVertexArrays(1, &fVAO));
380 fBuffers.reset();
380 } 381 }
381 382
382 /////////////////////////////////////////////////////////////////////////////// 383 ///////////////////////////////////////////////////////////////////////////////
383 384
384 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseInstance_VboSetup, 0) ) 385 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseInstance_VboSetup, 0) )
385 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 0) ) 386 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 0) )
386 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 0) ) 387 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 0) )
387 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 1) ) 388 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 1) )
388 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 1) ) 389 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 1) )
389 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 2) ) 390 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 2) )
390 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 2) ) 391 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 2) )
391 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 4) ) 392 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 4) )
392 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 4) ) 393 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 4) )
393 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 8) ) 394 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseOne_VboSetup, 8) )
394 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 8) ) 395 DEF_BENCH( return new GLCpuPosInstancedArraysBench(GLCpuPosInstancedArraysBench: :kUseTwo_VboSetup, 8) )
395 396
396 #endif 397 #endif
OLDNEW
« no previous file with comments | « no previous file | bench/GLVertexAttributesBench.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698