| OLD | NEW |
| 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_BROWSER_GPU_GPU_DATA_MANAGER_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_GPU_GPU_DATA_MANAGER_IMPL_H_ |
| 6 #define CONTENT_BROWSER_GPU_GPU_DATA_MANAGER_IMPL_H_ | 6 #define CONTENT_BROWSER_GPU_GPU_DATA_MANAGER_IMPL_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <stdint.h> | 9 #include <stdint.h> |
| 10 | 10 |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 #include "content/public/common/three_d_api_types.h" | 24 #include "content/public/common/three_d_api_types.h" |
| 25 #include "gpu/config/gpu_info.h" | 25 #include "gpu/config/gpu_info.h" |
| 26 | 26 |
| 27 class GURL; | 27 class GURL; |
| 28 | 28 |
| 29 namespace base { | 29 namespace base { |
| 30 class CommandLine; | 30 class CommandLine; |
| 31 } | 31 } |
| 32 | 32 |
| 33 namespace gpu { | 33 namespace gpu { |
| 34 struct GpuPreferences; |
| 34 struct VideoMemoryUsageStats; | 35 struct VideoMemoryUsageStats; |
| 35 } | 36 } |
| 36 | 37 |
| 37 namespace content { | 38 namespace content { |
| 38 | 39 |
| 39 class GpuDataManagerImplPrivate; | 40 class GpuDataManagerImplPrivate; |
| 40 struct WebPreferences; | 41 struct WebPreferences; |
| 41 | 42 |
| 42 class CONTENT_EXPORT GpuDataManagerImpl | 43 class CONTENT_EXPORT GpuDataManagerImpl |
| 43 : public NON_EXPORTED_BASE(GpuDataManager) { | 44 : public NON_EXPORTED_BASE(GpuDataManager) { |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 106 void UpdateGpuInfo(const gpu::GPUInfo& gpu_info); | 107 void UpdateGpuInfo(const gpu::GPUInfo& gpu_info); |
| 107 | 108 |
| 108 void UpdateVideoMemoryUsageStats( | 109 void UpdateVideoMemoryUsageStats( |
| 109 const gpu::VideoMemoryUsageStats& video_memory_usage_stats); | 110 const gpu::VideoMemoryUsageStats& video_memory_usage_stats); |
| 110 | 111 |
| 111 // Insert disable-feature switches corresponding to preliminary gpu feature | 112 // Insert disable-feature switches corresponding to preliminary gpu feature |
| 112 // flags into the renderer process command line. | 113 // flags into the renderer process command line. |
| 113 void AppendRendererCommandLine(base::CommandLine* command_line) const; | 114 void AppendRendererCommandLine(base::CommandLine* command_line) const; |
| 114 | 115 |
| 115 // Insert switches into gpu process command line: kUseGL, etc. | 116 // Insert switches into gpu process command line: kUseGL, etc. |
| 116 void AppendGpuCommandLine(base::CommandLine* command_line) const; | 117 // If the gpu_preferences isn't a nullptr, the gpu_preferences will be set |
| 118 // for some GPU switches which have been replaced by GpuPreferences, and those |
| 119 // switches will not be append to the command_line anymore. |
| 120 void AppendGpuCommandLine(base::CommandLine* command_line, |
| 121 gpu::GpuPreferences* gpu_preferences) const; |
| 117 | 122 |
| 118 // Update WebPreferences for renderer based on blacklisting decisions. | 123 // Update WebPreferences for renderer based on blacklisting decisions. |
| 119 void UpdateRendererWebPrefs(WebPreferences* prefs) const; | 124 void UpdateRendererWebPrefs(WebPreferences* prefs) const; |
| 120 | 125 |
| 121 std::string GetBlacklistVersion() const; | 126 std::string GetBlacklistVersion() const; |
| 122 std::string GetDriverBugListVersion() const; | 127 std::string GetDriverBugListVersion() const; |
| 123 | 128 |
| 124 // Returns the reasons for the latest run of blacklisting decisions. | 129 // Returns the reasons for the latest run of blacklisting decisions. |
| 125 // For the structure of returned value, see documentation for | 130 // For the structure of returned value, see documentation for |
| 126 // GpuBlacklist::GetBlacklistedReasons(). | 131 // GpuBlacklist::GetBlacklistedReasons(). |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 | 219 |
| 215 mutable base::Lock lock_; | 220 mutable base::Lock lock_; |
| 216 scoped_ptr<GpuDataManagerImplPrivate> private_; | 221 scoped_ptr<GpuDataManagerImplPrivate> private_; |
| 217 | 222 |
| 218 DISALLOW_COPY_AND_ASSIGN(GpuDataManagerImpl); | 223 DISALLOW_COPY_AND_ASSIGN(GpuDataManagerImpl); |
| 219 }; | 224 }; |
| 220 | 225 |
| 221 } // namespace content | 226 } // namespace content |
| 222 | 227 |
| 223 #endif // CONTENT_BROWSER_GPU_GPU_DATA_MANAGER_IMPL_H_ | 228 #endif // CONTENT_BROWSER_GPU_GPU_DATA_MANAGER_IMPL_H_ |
| OLD | NEW |