#include "content/common/input_messages.h"
#include "content/common/gpu/gpu_messages.h"
#include "content/common/cursors/webcursor_efl.h"
+#include "content/gpu/shared_mailbox_manager.h"
#include "content/public/browser/render_widget_host_view_frame_subscriber.h"
#include "content/public/browser/screen_orientation_dispatcher_host.h"
#include "content/public/browser/web_contents_delegate.h"
void RenderWidgetHostViewEfl::GetTextureFromMailbox(gpu::Mailbox* mailbox,
gfx::Size surface_size) {
- gpu::gles2::MailboxManager* manager = GLSharedContextEfl::GetMailboxManager();
+ gpu::gles2::MailboxManager* manager = SharedMailboxManager::GetMailboxManager();
gpu::gles2::Texture* texture = manager->ConsumeTexture(*mailbox);
if (texture != NULL) {
surface_size_ = surface_size;
if (evas_gl_initialized_) {
std::swap(ack.gl_frame_data->mailbox, pending_mailbox_);
gpu::gles2::MailboxManager* manager =
- GLSharedContextEfl::GetMailboxManager();
+ SharedMailboxManager::GetMailboxManager();
gpu::gles2::Texture* texture =
manager->ConsumeTexture(pending_mailbox_);
'sources': [
'gpu/gpu_thread_override_efl.cc',
'gpu/in_process_gpu_thread_efl.cc',
+ 'gpu/shared_mailbox_manager.h',
+ 'gpu/shared_mailbox_manager.cc',
],
'sources/': [
[ 'exclude', 'gpu/in_process_gpu_thread.cc$' ],
#include "content/common/gpu/gpu_messages.h"
#include "content/gpu/gpu_process.h"
+#include "content/gpu/shared_mailbox_manager.h"
#include "ui/gl/gl_shared_context_efl.h"
#include "gpu/command_buffer/service/mailbox_manager.h"
#include "ipc/ipc_channel.h"
gpu_channel_manager_->share_group_ =
GLSharedContextEfl::GetShareGroup();
gpu_channel_manager_->mailbox_manager_ =
- GLSharedContextEfl::GetMailboxManager();
+ SharedMailboxManager::GetMailboxManager();
}
};
--- /dev/null
+// Copyright 2015 Samsung Electronics. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "shared_mailbox_manager.h"
+
+#include "gpu/command_buffer/service/mailbox_manager_impl.h"
+
+namespace content {
+
+// static
+gpu::gles2::MailboxManager* SharedMailboxManager::GetMailboxManager() {
+ static scoped_refptr<gpu::gles2::MailboxManager> mailbox_manager_ =
+ new gpu::gles2::MailboxManagerImpl();
+ return mailbox_manager_.get();
+}
+
+}
--- /dev/null
+// Copyright 2015 Samsung Electronics. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+namespace gpu {
+namespace gles2 {
+ class MailboxManager;
+}
+}
+
+namespace content {
+ struct SharedMailboxManager {
+ static gpu::gles2::MailboxManager* GetMailboxManager();
+ };
+}
return share_group_.get();
}
-// static
-gpu::gles2::MailboxManager* GLSharedContextEfl::GetMailboxManager() {
- static scoped_refptr<gpu::gles2::MailboxManager> mailbox_manager_ =
- new gpu::gles2::MailboxManagerImpl();
- return mailbox_manager_.get();
-}
-
#if defined(TIZEN_DISABLE_GPU_THREAD)
void GLSharedContextEfl::SetDelegate(GLSharedContextDelegate* delegate) {
g_private_part->delegate_ = delegate;
class GLContext;
class GLShareGroup;
}
-namespace gpu {
-namespace gles2 {
- class MailboxManager;
-}
-}
#if defined(TIZEN_DISABLE_GPU_THREAD)
class GLSharedContextDelegate {
static gfx::GLContext* GetInstance();
static Evas_GL_Context* GetEvasGLContext();
static gfx::GLShareGroup* GetShareGroup();
- static gpu::gles2::MailboxManager* GetMailboxManager();
#if defined(TIZEN_DISABLE_GPU_THREAD)
static void SetDelegate(GLSharedContextDelegate*);
#endif