#include "base/synchronization/waitable_event.h"
#include "content/common/gpu/client/gpu_channel_host.h"
#include "ipc/ipc_channel_handle.h"
+#include "ipc/message_filter.h"
namespace content {
virtual scoped_refptr<base::MessageLoopProxy> GetIOLoopProxy() OVERRIDE;
virtual scoped_ptr<base::SharedMemory> AllocateSharedMemory(
size_t size) OVERRIDE;
- virtual int32 CreateViewCommandBuffer(
+ virtual bool CreateViewCommandBuffer(
int32 surface_id,
- const GPUCreateCommandBufferConfig& init_params) OVERRIDE;
+ const GPUCreateCommandBufferConfig& init_params,
+ int32 route_id) OVERRIDE;
virtual void CreateImage(
gfx::PluginWindowHandle window,
int32 image_id,
virtual scoped_ptr<gfx::GpuMemoryBuffer> AllocateGpuMemoryBuffer(
size_t width,
size_t height,
- unsigned internalformat) OVERRIDE;
+ unsigned internalformat,
+ unsigned usage) OVERRIDE;
// Specify a task runner and callback to be used for a set of messages. The
// callback will be set up on the current GpuProcessHost, identified by
base::WaitableEvent event;
int gpu_host_id;
int32 route_id;
+ bool succeeded;
};
class EstablishRequest : public base::RefCountedThreadSafe<EstablishRequest> {
CreateRequest* request,
int32 surface_id,
const GPUCreateCommandBufferConfig& init_params);
- static void CommandBufferCreatedOnIO(CreateRequest* request, int32 route_id);
+ static void CommandBufferCreatedOnIO(CreateRequest* request, bool succeeded);
void CreateImageOnIO(
gfx::PluginWindowHandle window,
int32 image_id,
static void OnImageCreated(
const CreateImageCallback& callback, const gfx::Size size);
void DeleteImageOnIO(int32 image_id, int32 sync_point);
- static void AddFilterOnIO(
- int gpu_host_id,
- scoped_refptr<IPC::ChannelProxy::MessageFilter> filter);
+ static void AddFilterOnIO(int gpu_host_id,
+ scoped_refptr<IPC::MessageFilter> filter);
const int gpu_client_id_;
scoped_ptr<base::WaitableEvent> shutdown_event_;