OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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_SHADER_CACHE_FACTORY_H_ | 5 #ifndef CONTENT_BROWSER_GPU_SHADER_CACHE_FACTORY_H_ |
6 #define CONTENT_BROWSER_GPU_SHADER_CACHE_FACTORY_H_ | 6 #define CONTENT_BROWSER_GPU_SHADER_CACHE_FACTORY_H_ |
7 | 7 |
8 #include "content/browser/gpu/shader_disk_cache.h" | |
9 #include "content/common/content_export.h" | 8 #include "content/common/content_export.h" |
| 9 #include "gpu/ipc/host/shader_disk_cache.h" |
10 | 10 |
11 namespace content { | 11 namespace content { |
12 | 12 |
13 // Initializes the ShaderCacheFactory singleton instance. The singleton | 13 // Initializes the ShaderCacheFactory singleton instance. The singleton |
14 // instance is created and used in the thread associated with |task_runner|. | 14 // instance is created and used in the thread associated with |task_runner|. |
15 // |cache_task_runner| is associated with the thread responsible for managing | 15 // |cache_task_runner| is associated with the thread responsible for managing |
16 // the disk cache. | 16 // the disk cache. |
17 CONTENT_EXPORT void InitShaderCacheFactorySingleton( | 17 CONTENT_EXPORT void InitShaderCacheFactorySingleton( |
18 scoped_refptr<base::SingleThreadTaskRunner> task_runner, | 18 scoped_refptr<base::SingleThreadTaskRunner> task_runner, |
19 scoped_refptr<base::SingleThreadTaskRunner> cache_task_runner); | 19 scoped_refptr<base::SingleThreadTaskRunner> cache_task_runner); |
20 | 20 |
21 // Returns an instance previously created by InitShaderCacheFactorySingleton(). | 21 // Returns an instance previously created by InitShaderCacheFactorySingleton(). |
22 // This can return nullptr if an instance has not yet been created. | 22 // This can return nullptr if an instance has not yet been created. |
23 CONTENT_EXPORT ShaderCacheFactory* GetShaderCacheFactorySingleton(); | 23 CONTENT_EXPORT gpu::ShaderCacheFactory* GetShaderCacheFactorySingleton(); |
24 | 24 |
25 } // namespace content | 25 } // namespace content |
26 | 26 |
27 #endif // CONTENT_BROWSER_GPU_SHADER_CACHE_FACTORY_H_ | 27 #endif // CONTENT_BROWSER_GPU_SHADER_CACHE_FACTORY_H_ |
OLD | NEW |