Index: gpu/command_buffer/service/in_process_command_buffer.h |
diff --git a/gpu/command_buffer/service/in_process_command_buffer.h b/gpu/command_buffer/service/in_process_command_buffer.h |
index 37b888a6d56c848887c42e68c3994966795f117c..cc9a389080af3d832e83dd82bc17e89170192370 100644 |
--- a/gpu/command_buffer/service/in_process_command_buffer.h |
+++ b/gpu/command_buffer/service/in_process_command_buffer.h |
@@ -24,6 +24,7 @@ |
#include "base/threading/thread.h" |
#include "gpu/command_buffer/client/gpu_control.h" |
#include "gpu/command_buffer/common/command_buffer.h" |
+#include "gpu/command_buffer/service/gpu_preferences.h" |
#include "gpu/gpu_export.h" |
#include "ui/gfx/gpu_memory_buffer.h" |
#include "ui/gfx/native_widget_types.h" |
@@ -140,7 +141,7 @@ class GPU_EXPORT InProcessCommandBuffer : public CommandBuffer, |
// The serializer interface to the GPU service (i.e. thread). |
class Service { |
public: |
- Service(); |
+ explicit Service(const gpu::GpuPreferences& gpu_preferences); |
virtual ~Service(); |
virtual void AddRef() const = 0; |
@@ -159,6 +160,7 @@ class GPU_EXPORT InProcessCommandBuffer : public CommandBuffer, |
virtual scoped_refptr<gles2::FramebufferCompletenessCache> |
framebuffer_completeness_cache() = 0; |
virtual SyncPointManager* sync_point_manager() = 0; |
+ const GpuPreferences& gpu_preferences(); |
scoped_refptr<gfx::GLShareGroup> share_group(); |
scoped_refptr<gles2::MailboxManager> mailbox_manager(); |
scoped_refptr<gles2::SubscriptionRefSet> subscription_ref_set(); |
@@ -166,6 +168,7 @@ class GPU_EXPORT InProcessCommandBuffer : public CommandBuffer, |
gpu::gles2::ProgramCache* program_cache(); |
private: |
+ const GpuPreferences& gpu_preferences_; |
scoped_refptr<gfx::GLShareGroup> share_group_; |
scoped_refptr<gles2::MailboxManager> mailbox_manager_; |
scoped_refptr<gles2::SubscriptionRefSet> subscription_ref_set_; |
@@ -313,6 +316,7 @@ class GPU_EXPORT GpuInProcessThread |
~GpuInProcessThread() override; |
friend class base::RefCountedThreadSafe<GpuInProcessThread>; |
+ GpuPreferences gpu_preferences_; |
SyncPointManager* sync_point_manager_; // Non-owning. |
scoped_refptr<gpu::gles2::ShaderTranslatorCache> shader_translator_cache_; |
scoped_refptr<gpu::gles2::FramebufferCompletenessCache> |