OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CONTENT_BROWSER_GPU_SHADER_CACHE_FACTORY_H_ |
| 6 #define CONTENT_BROWSER_GPU_SHADER_CACHE_FACTORY_H_ |
| 7 |
| 8 #include "content/browser/gpu/shader_disk_cache.h" |
| 9 #include "content/common/content_export.h" |
| 10 |
| 11 namespace content { |
| 12 |
| 13 // Initializes the ShaderCacheFactory singleton instance. The singleton |
| 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 |
| 16 // the disk cache. |
| 17 CONTENT_EXPORT void InitShaderCacheFactorySingleton( |
| 18 scoped_refptr<base::SingleThreadTaskRunner> task_runner, |
| 19 scoped_refptr<base::SingleThreadTaskRunner> cache_task_runner); |
| 20 |
| 21 // Returns an instance previously created by InitShaderCacheFactorySingleton(). |
| 22 // This can return nullptr if an instance has not yet been created. |
| 23 CONTENT_EXPORT ShaderCacheFactory* GetShaderCacheFactorySingleton(); |
| 24 |
| 25 } // namespace content |
| 26 |
| 27 #endif // CONTENT_BROWSER_GPU_SHADER_CACHE_FACTORY_H_ |
OLD | NEW |