summaryrefslogtreecommitdiffstats
path: root/content/renderer
diff options
context:
space:
mode:
Diffstat (limited to 'content/renderer')
-rw-r--r--content/renderer/gpu/gpu_channel_host.cc26
-rw-r--r--content/renderer/gpu/gpu_channel_host.h6
-rw-r--r--content/renderer/gpu/gpu_surface_proxy.cc30
-rw-r--r--content/renderer/gpu/gpu_surface_proxy.h47
4 files changed, 0 insertions, 109 deletions
diff --git a/content/renderer/gpu/gpu_channel_host.cc b/content/renderer/gpu/gpu_channel_host.cc
index 73bf14f..343f777 100644
--- a/content/renderer/gpu/gpu_channel_host.cc
+++ b/content/renderer/gpu/gpu_channel_host.cc
@@ -8,7 +8,6 @@
#include "content/common/child_process.h"
#include "content/common/gpu/gpu_messages.h"
#include "content/renderer/gpu/command_buffer_proxy.h"
-#include "content/renderer/gpu/gpu_surface_proxy.h"
#include "content/renderer/gpu/transport_texture_service.h"
#include "content/renderer/render_process.h"
#include "content/renderer/render_thread.h"
@@ -298,31 +297,6 @@ void GpuChannelHost::DestroyCommandBuffer(CommandBufferProxy* command_buffer) {
#endif
}
-GpuSurfaceProxy* GpuChannelHost::CreateOffscreenSurface(
- const gfx::Size& size) {
-#if defined(ENABLE_GPU)
- AutoLock lock(context_lock_);
- int route_id;
- if (!Send(new GpuChannelMsg_CreateOffscreenSurface(size, &route_id)))
- return NULL;
-
- scoped_ptr<GpuSurfaceProxy> surface(new GpuSurfaceProxy(this, route_id));
- AddRoute(route_id, surface->AsWeakPtr());
-
- return surface.release();
-#endif
-}
-
-void GpuChannelHost::DestroySurface(GpuSurfaceProxy* surface) {
-#if defined(ENABLE_GPU)
- AutoLock lock(context_lock_);
- Send(new GpuChannelMsg_DestroySurface(surface->route_id()));
-
- RemoveRoute(surface->route_id());
- delete surface;
-#endif
-}
-
void GpuChannelHost::AddRoute(
int route_id, base::WeakPtr<IPC::Channel::Listener> listener) {
DCHECK(MessageLoopProxy::current());
diff --git a/content/renderer/gpu/gpu_channel_host.h b/content/renderer/gpu/gpu_channel_host.h
index 4bd9fbb..96c6ae4 100644
--- a/content/renderer/gpu/gpu_channel_host.h
+++ b/content/renderer/gpu/gpu_channel_host.h
@@ -101,12 +101,6 @@ class GpuChannelHost : public IPC::Message::Sender,
// Destroy a command buffer created by this channel.
void DestroyCommandBuffer(CommandBufferProxy* command_buffer);
- // Create a surface in the GPU process. Returns null on failure.
- GpuSurfaceProxy* CreateOffscreenSurface(const gfx::Size& size);
-
- // Destroy a surface in the GPU process.
- void DestroySurface(GpuSurfaceProxy* surface);
-
TransportTextureService* transport_texture_service() {
return transport_texture_service_.get();
}
diff --git a/content/renderer/gpu/gpu_surface_proxy.cc b/content/renderer/gpu/gpu_surface_proxy.cc
deleted file mode 100644
index d023b0e..0000000
--- a/content/renderer/gpu/gpu_surface_proxy.cc
+++ /dev/null
@@ -1,30 +0,0 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "content/renderer/gpu/gpu_surface_proxy.h"
-#include "ui/gfx/size.h"
-
-GpuSurfaceProxy::GpuSurfaceProxy(
- IPC::Channel::Sender* channel,
- int route_id)
- : channel_(channel),
- route_id_(route_id) {
-}
-
-GpuSurfaceProxy::~GpuSurfaceProxy() {
-}
-
-bool GpuSurfaceProxy::OnMessageReceived(const IPC::Message& message) {
- bool handled = true;
- //IPC_BEGIN_MESSAGE_MAP(GpuSurfaceProxy, message)
- // IPC_MESSAGE_UNHANDLED(handled = false)
- //IPC_END_MESSAGE_MAP()
- DCHECK(handled);
- return handled;
-}
-
-void GpuSurfaceProxy::OnChannelError() {
- // Prevent any further messages from being sent.
- channel_ = NULL;
-}
diff --git a/content/renderer/gpu/gpu_surface_proxy.h b/content/renderer/gpu/gpu_surface_proxy.h
deleted file mode 100644
index f4f8879..0000000
--- a/content/renderer/gpu/gpu_surface_proxy.h
+++ /dev/null
@@ -1,47 +0,0 @@
-// Copyright (c) 2011 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CONTENT_RENDERER_GPU_GPU_SURFACE_PROXY_H_
-#define CONTENT_RENDERER_GPU_GPU_SURFACE_PROXY_H_
-#pragma once
-
-#if defined(ENABLE_GPU)
-
-#include "base/memory/weak_ptr.h"
-#include "ipc/ipc_channel.h"
-#include "ipc/ipc_message.h"
-
-namespace gfx {
-class Size;
-}
-
-// Client side proxy that forwards messages to a GpuSurfaceStub.
-class GpuSurfaceProxy : public IPC::Channel::Listener,
- public base::SupportsWeakPtr<GpuSurfaceProxy> {
- public:
- GpuSurfaceProxy(IPC::Channel::Sender* channel, int route_id);
- virtual ~GpuSurfaceProxy();
-
- // IPC::Channel::Listener implementation:
- virtual bool OnMessageReceived(const IPC::Message& message);
- virtual void OnChannelError();
-
- int route_id() const { return route_id_; }
-
- private:
-
- // Send an IPC message over the GPU channel. This is private to fully
- // encapsulate the channel; all callers of this function must explicitly
- // verify that the channel is still available.
- bool Send(IPC::Message* msg);
-
- IPC::Channel::Sender* channel_;
- int route_id_;
-
- DISALLOW_COPY_AND_ASSIGN(GpuSurfaceProxy);
-};
-
-#endif // ENABLE_GPU
-
-#endif // CONTENT_RENDERER_GPU_GPU_SURFACE_PROXY_H_