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

Side by Side Diff: gpu/perftests/texture_upload_perftest.cc

Issue 937203002: gpu: Make gpu_perftests run and pass on mac. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 | ui/gl/gl_context_cgl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <algorithm> 5 #include <algorithm>
6 #include <vector> 6 #include <vector>
7 7
8 #include "base/containers/small_map.h" 8 #include "base/containers/small_map.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 15 matching lines...) Expand all
26 26
27 #define SHADER(Src) #Src 27 #define SHADER(Src) #Src
28 28
29 // clang-format off 29 // clang-format off
30 const char kVertexShader[] = 30 const char kVertexShader[] =
31 SHADER( 31 SHADER(
32 attribute vec2 a_position; 32 attribute vec2 a_position;
33 varying vec2 v_texCoord; 33 varying vec2 v_texCoord;
34 void main() { 34 void main() {
35 gl_Position = vec4(a_position.x, a_position.y, 0.0, 1.0); 35 gl_Position = vec4(a_position.x, a_position.y, 0.0, 1.0);
36 v_texCoord = vec2((a_position.x + 1) * 0.5, (a_position.y + 1) * 0.5); 36 v_texCoord = vec2((a_position.x + 1.0) * 0.5, (a_position.y + 1.0) * 0.5);
37 } 37 }
38 ); 38 );
39 const char kFragmentShader[] = 39 const char kFragmentShader[] =
40 SHADER( 40 SHADER(
41 uniform sampler2D a_texture; 41 uniform sampler2D a_texture;
42 varying vec2 v_texCoord; 42 varying vec2 v_texCoord;
43 void main() { 43 void main() {
44 gl_FragColor = texture2D(a_texture, v_texCoord.xy); 44 gl_FragColor = texture2D(a_texture, v_texCoord.xy);
45 } 45 }
46 ); 46 );
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
272 } 272 }
273 273
274 for (const auto& entry : aggregates) { 274 for (const auto& entry : aggregates) {
275 const auto m = entry.second.Divide(kUploadPerfTestRuns); 275 const auto m = entry.second.Divide(kUploadPerfTestRuns);
276 m.PrintResult(); 276 m.PrintResult();
277 } 277 }
278 } 278 }
279 279
280 } // namespace 280 } // namespace
281 } // namespace gpu 281 } // namespace gpu
OLDNEW
« no previous file with comments | « no previous file | ui/gl/gl_context_cgl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698