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

Side by Side Diff: content/common/gpu/client/context_provider_command_buffer.h

Issue 780653007: Added GL_CHROMIUM_trace_marker feature as well as gpu_toplevel markers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed render host for android tracing Created 6 years 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 #ifndef CONTENT_COMMON_GPU_CLIENT_CONTEXT_PROVIDER_COMMAND_BUFFER 5 #ifndef CONTENT_COMMON_GPU_CLIENT_CONTEXT_PROVIDER_COMMAND_BUFFER
6 #define CONTENT_COMMON_GPU_CLIENT_CONTEXT_PROVIDER_COMMAND_BUFFER 6 #define CONTENT_COMMON_GPU_CLIENT_CONTEXT_PROVIDER_COMMAND_BUFFER
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "base/synchronization/lock.h" 10 #include "base/synchronization/lock.h"
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 scoped_ptr<WebGraphicsContext3DCommandBufferImpl> context3d, 57 scoped_ptr<WebGraphicsContext3DCommandBufferImpl> context3d,
58 const std::string& debug_name); 58 const std::string& debug_name);
59 ~ContextProviderCommandBuffer() override; 59 ~ContextProviderCommandBuffer() override;
60 60
61 void OnLostContext(); 61 void OnLostContext();
62 void OnMemoryAllocationChanged(const gpu::MemoryAllocation& allocation); 62 void OnMemoryAllocationChanged(const gpu::MemoryAllocation& allocation);
63 63
64 private: 64 private:
65 void InitializeCapabilities(); 65 void InitializeCapabilities();
66 66
67 // Whether gpu_toplevel category is enabled.
68 const unsigned char* gpu_trace_top_level_category_;
69
67 base::ThreadChecker main_thread_checker_; 70 base::ThreadChecker main_thread_checker_;
68 base::ThreadChecker context_thread_checker_; 71 base::ThreadChecker context_thread_checker_;
69 72
70 scoped_ptr<WebGraphicsContext3DCommandBufferImpl> context3d_; 73 scoped_ptr<WebGraphicsContext3DCommandBufferImpl> context3d_;
71 scoped_ptr<webkit::gpu::GrContextForWebGraphicsContext3D> gr_context_; 74 scoped_ptr<webkit::gpu::GrContextForWebGraphicsContext3D> gr_context_;
72 75
73 cc::ContextProvider::Capabilities capabilities_; 76 cc::ContextProvider::Capabilities capabilities_;
74 std::string debug_name_; 77 std::string debug_name_;
75 78
76 LostContextCallback lost_context_callback_; 79 LostContextCallback lost_context_callback_;
77 MemoryPolicyChangedCallback memory_policy_changed_callback_; 80 MemoryPolicyChangedCallback memory_policy_changed_callback_;
78 81
79 base::Lock main_thread_lock_; 82 base::Lock main_thread_lock_;
80 bool destroyed_; 83 bool destroyed_;
81 84
82 class LostContextCallbackProxy; 85 class LostContextCallbackProxy;
83 scoped_ptr<LostContextCallbackProxy> lost_context_callback_proxy_; 86 scoped_ptr<LostContextCallbackProxy> lost_context_callback_proxy_;
84 }; 87 };
85 88
86 } // namespace content 89 } // namespace content
87 90
88 #endif // CONTENT_COMMON_GPU_CLIENT_CONTEXT_PROVIDER_COMMAND_BUFFER 91 #endif // CONTENT_COMMON_GPU_CLIENT_CONTEXT_PROVIDER_COMMAND_BUFFER
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698