| Index: gpu/ipc/service/gpu_channel_manager.h
|
| diff --git a/content/common/gpu/gpu_channel_manager.h b/gpu/ipc/service/gpu_channel_manager.h
|
| similarity index 80%
|
| rename from content/common/gpu/gpu_channel_manager.h
|
| rename to gpu/ipc/service/gpu_channel_manager.h
|
| index 875656f47b697e82be97ce436e0e9609a6c3198b..288e3b982ed7c0554d8ff0585deb9c083cbbe69e 100644
|
| --- a/content/common/gpu/gpu_channel_manager.h
|
| +++ b/gpu/ipc/service/gpu_channel_manager.h
|
| @@ -2,8 +2,8 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| -#ifndef CONTENT_COMMON_GPU_GPU_CHANNEL_MANAGER_H_
|
| -#define CONTENT_COMMON_GPU_GPU_CHANNEL_MANAGER_H_
|
| +#ifndef GPU_IPC_SERVICE_GPU_CHANNEL_MANAGER_H_
|
| +#define GPU_IPC_SERVICE_GPU_CHANNEL_MANAGER_H_
|
|
|
| #include <stdint.h>
|
|
|
| @@ -17,9 +17,9 @@
|
| #include "base/memory/scoped_ptr.h"
|
| #include "base/memory/weak_ptr.h"
|
| #include "build/build_config.h"
|
| -#include "content/common/content_export.h"
|
| -#include "content/common/gpu/gpu_memory_manager.h"
|
| #include "gpu/command_buffer/common/constants.h"
|
| +#include "gpu/gpu_export.h"
|
| +#include "gpu/ipc/service/gpu_memory_manager.h"
|
| #include "ui/gfx/gpu_memory_buffer.h"
|
| #include "ui/gfx/native_widget_types.h"
|
| #include "ui/gl/gl_surface.h"
|
| @@ -57,7 +57,7 @@ namespace IPC {
|
| struct ChannelHandle;
|
| }
|
|
|
| -namespace content {
|
| +namespace gpu {
|
| class GpuChannel;
|
| class GpuChannelManagerDelegate;
|
| class GpuMemoryBufferFactory;
|
| @@ -66,20 +66,20 @@ class GpuWatchdog;
|
| // A GpuChannelManager is a thread responsible for issuing rendering commands
|
| // managing the lifetimes of GPU channels and forwarding IPC requests from the
|
| // browser process to them based on the corresponding renderer ID.
|
| -class CONTENT_EXPORT GpuChannelManager {
|
| +class GPU_EXPORT GpuChannelManager {
|
| public:
|
| #if defined(OS_MACOSX)
|
| typedef base::Callback<
|
| void(int32_t, const base::TimeTicks&, const base::TimeDelta&)>
|
| BufferPresentedCallback;
|
| #endif
|
| - GpuChannelManager(const gpu::GpuPreferences& gpu_preferences,
|
| + GpuChannelManager(const GpuPreferences& gpu_preferences,
|
| GpuChannelManagerDelegate* delegate,
|
| GpuWatchdog* watchdog,
|
| base::SingleThreadTaskRunner* task_runner,
|
| base::SingleThreadTaskRunner* io_task_runner,
|
| base::WaitableEvent* shutdown_event,
|
| - gpu::SyncPointManager* sync_point_manager,
|
| + SyncPointManager* sync_point_manager,
|
| GpuMemoryBufferFactory* gpu_memory_buffer_factory);
|
| virtual ~GpuChannelManager();
|
|
|
| @@ -94,10 +94,10 @@ class CONTENT_EXPORT GpuChannelManager {
|
| void PopulateShaderCache(const std::string& shader);
|
| void DestroyGpuMemoryBuffer(gfx::GpuMemoryBufferId id,
|
| int client_id,
|
| - const gpu::SyncToken& sync_token);
|
| + const SyncToken& sync_token);
|
| void UpdateValueState(int client_id,
|
| unsigned int target,
|
| - const gpu::ValueState& state);
|
| + const ValueState& state);
|
| #if defined(OS_ANDROID)
|
| void WakeUpGpu();
|
| #endif
|
| @@ -117,12 +117,12 @@ class CONTENT_EXPORT GpuChannelManager {
|
| const base::TimeDelta& vsync_interval);
|
| #endif
|
|
|
| - const gpu::GpuPreferences& gpu_preferences() const {
|
| + const GpuPreferences& gpu_preferences() const {
|
| return gpu_preferences_;
|
| }
|
| - gpu::gles2::ProgramCache* program_cache();
|
| - gpu::gles2::ShaderTranslatorCache* shader_translator_cache();
|
| - gpu::gles2::FramebufferCompletenessCache* framebuffer_completeness_cache();
|
| + gles2::ProgramCache* program_cache();
|
| + gles2::ShaderTranslatorCache* shader_translator_cache();
|
| + gles2::FramebufferCompletenessCache* framebuffer_completeness_cache();
|
|
|
| GpuMemoryManager* gpu_memory_manager() { return &gpu_memory_manager_; }
|
|
|
| @@ -154,15 +154,15 @@ class CONTENT_EXPORT GpuChannelManager {
|
| bool allow_view_command_buffers,
|
| bool allow_real_time_streams);
|
|
|
| - gpu::SyncPointManager* sync_point_manager() const {
|
| + SyncPointManager* sync_point_manager() const {
|
| return sync_point_manager_;
|
| }
|
|
|
| gfx::GLShareGroup* share_group() const { return share_group_.get(); }
|
| - gpu::gles2::MailboxManager* mailbox_manager() const {
|
| + gles2::MailboxManager* mailbox_manager() const {
|
| return mailbox_manager_.get();
|
| }
|
| - gpu::PreemptionFlag* preemption_flag() const {
|
| + PreemptionFlag* preemption_flag() const {
|
| return preemption_flag_.get();
|
| }
|
|
|
| @@ -183,7 +183,7 @@ class CONTENT_EXPORT GpuChannelManager {
|
| void DoWakeUpGpu();
|
| #endif
|
|
|
| - const gpu::GpuPreferences& gpu_preferences_;
|
| + const GpuPreferences& gpu_preferences_;
|
|
|
| GpuChannelManagerDelegate* const delegate_;
|
| #if defined(OS_MACOSX)
|
| @@ -196,15 +196,15 @@ class CONTENT_EXPORT GpuChannelManager {
|
| base::WaitableEvent* shutdown_event_;
|
|
|
| scoped_refptr<gfx::GLShareGroup> share_group_;
|
| - scoped_refptr<gpu::gles2::MailboxManager> mailbox_manager_;
|
| - scoped_refptr<gpu::PreemptionFlag> preemption_flag_;
|
| + scoped_refptr<gles2::MailboxManager> mailbox_manager_;
|
| + scoped_refptr<PreemptionFlag> preemption_flag_;
|
| GpuMemoryManager gpu_memory_manager_;
|
| // SyncPointManager guaranteed to outlive running MessageLoop.
|
| - gpu::SyncPointManager* sync_point_manager_;
|
| - scoped_ptr<gpu::SyncPointClient> sync_point_client_waiter_;
|
| - scoped_ptr<gpu::gles2::ProgramCache> program_cache_;
|
| - scoped_refptr<gpu::gles2::ShaderTranslatorCache> shader_translator_cache_;
|
| - scoped_refptr<gpu::gles2::FramebufferCompletenessCache>
|
| + SyncPointManager* sync_point_manager_;
|
| + scoped_ptr<SyncPointClient> sync_point_client_waiter_;
|
| + scoped_ptr<gles2::ProgramCache> program_cache_;
|
| + scoped_refptr<gles2::ShaderTranslatorCache> shader_translator_cache_;
|
| + scoped_refptr<gles2::FramebufferCompletenessCache>
|
| framebuffer_completeness_cache_;
|
| scoped_refptr<gfx::GLSurface> default_offscreen_surface_;
|
| GpuMemoryBufferFactory* const gpu_memory_buffer_factory_;
|
| @@ -223,6 +223,6 @@ class CONTENT_EXPORT GpuChannelManager {
|
| DISALLOW_COPY_AND_ASSIGN(GpuChannelManager);
|
| };
|
|
|
| -} // namespace content
|
| +} // namespace gpu
|
|
|
| -#endif // CONTENT_COMMON_GPU_GPU_CHANNEL_MANAGER_H_
|
| +#endif // GPU_IPC_SERVICE_GPU_CHANNEL_MANAGER_H_
|
|
|