| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "gpu/command_buffer/service/gpu_tracer.h" | 5 #include "gpu/command_buffer/service/gpu_tracer.h" |
| 6 | 6 |
| 7 #include <deque> | 7 #include <deque> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
| 11 #include "base/memory/weak_ptr.h" | 11 #include "base/memory/weak_ptr.h" |
| 12 #include "base/strings/string_util.h" | 12 #include "base/strings/string_util.h" |
| 13 #include "base/threading/thread.h" | 13 #include "base/threading/thread.h" |
| 14 #include "base/time.h" | 14 #include "base/time/time.h" |
| 15 #include "ui/gl/gl_bindings.h" | 15 #include "ui/gl/gl_bindings.h" |
| 16 | 16 |
| 17 namespace gpu { | 17 namespace gpu { |
| 18 namespace gles2 { | 18 namespace gles2 { |
| 19 namespace { | 19 namespace { |
| 20 | 20 |
| 21 class Outputter; | 21 class Outputter; |
| 22 | 22 |
| 23 static const unsigned int kProcessInterval = 16; | 23 static const unsigned int kProcessInterval = 16; |
| 24 static Outputter* g_outputter_thread = NULL; | 24 static Outputter* g_outputter_thread = NULL; |
| (...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 338 } // namespace | 338 } // namespace |
| 339 | 339 |
| 340 scoped_ptr<GPUTracer> GPUTracer::Create() { | 340 scoped_ptr<GPUTracer> GPUTracer::Create() { |
| 341 if (gfx::g_driver_gl.ext.b_GL_ARB_timer_query) | 341 if (gfx::g_driver_gl.ext.b_GL_ARB_timer_query) |
| 342 return scoped_ptr<GPUTracer>(new GPUTracerARBTimerQuery()); | 342 return scoped_ptr<GPUTracer>(new GPUTracerARBTimerQuery()); |
| 343 return scoped_ptr<GPUTracer>(new GPUTracerImpl()); | 343 return scoped_ptr<GPUTracer>(new GPUTracerImpl()); |
| 344 } | 344 } |
| 345 | 345 |
| 346 } // namespace gles2 | 346 } // namespace gles2 |
| 347 } // namespace gpu | 347 } // namespace gpu |
| OLD | NEW |