| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ | 5 #ifndef CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ |
| 6 #define CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ | 6 #define CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 static BrowserGpuChannelHostFactory* instance() { return instance_; } | 26 static BrowserGpuChannelHostFactory* instance() { return instance_; } |
| 27 | 27 |
| 28 static void EnableGpuMemoryBufferFactoryUsage( | 28 static void EnableGpuMemoryBufferFactoryUsage( |
| 29 gfx::GpuMemoryBuffer::Usage usage); | 29 gfx::GpuMemoryBuffer::Usage usage); |
| 30 static bool IsGpuMemoryBufferFactoryUsageEnabled( | 30 static bool IsGpuMemoryBufferFactoryUsageEnabled( |
| 31 gfx::GpuMemoryBuffer::Usage usage); | 31 gfx::GpuMemoryBuffer::Usage usage); |
| 32 static uint32 GetImageTextureTarget(); | 32 static uint32 GetImageTextureTarget(); |
| 33 | 33 |
| 34 // Overridden from GpuChannelHostFactory: | 34 // Overridden from GpuChannelHostFactory: |
| 35 bool IsMainThread() override; | 35 bool IsMainThread() override; |
| 36 scoped_refptr<base::SingleThreadTaskRunner> GetIOThreadTaskRunner() override; | 36 scoped_refptr<base::MessageLoopProxy> GetIOLoopProxy() override; |
| 37 scoped_ptr<base::SharedMemory> AllocateSharedMemory(size_t size) override; | 37 scoped_ptr<base::SharedMemory> AllocateSharedMemory(size_t size) override; |
| 38 CreateCommandBufferResult CreateViewCommandBuffer( | 38 CreateCommandBufferResult CreateViewCommandBuffer( |
| 39 int32 surface_id, | 39 int32 surface_id, |
| 40 const GPUCreateCommandBufferConfig& init_params, | 40 const GPUCreateCommandBufferConfig& init_params, |
| 41 int32 route_id) override; | 41 int32 route_id) override; |
| 42 | 42 |
| 43 // Overridden from GpuMemoryBufferFactoryHost: | 43 // Overridden from GpuMemoryBufferFactoryHost: |
| 44 bool IsGpuMemoryBufferConfigurationSupported( | 44 bool IsGpuMemoryBufferConfigurationSupported( |
| 45 gfx::GpuMemoryBuffer::Format format, | 45 gfx::GpuMemoryBuffer::Format format, |
| 46 gfx::GpuMemoryBuffer::Usage usage) override; | 46 gfx::GpuMemoryBuffer::Usage usage) override; |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 CreateGpuMemoryBufferCallbackMap create_gpu_memory_buffer_requests_; | 104 CreateGpuMemoryBufferCallbackMap create_gpu_memory_buffer_requests_; |
| 105 | 105 |
| 106 static BrowserGpuChannelHostFactory* instance_; | 106 static BrowserGpuChannelHostFactory* instance_; |
| 107 | 107 |
| 108 DISALLOW_COPY_AND_ASSIGN(BrowserGpuChannelHostFactory); | 108 DISALLOW_COPY_AND_ASSIGN(BrowserGpuChannelHostFactory); |
| 109 }; | 109 }; |
| 110 | 110 |
| 111 } // namespace content | 111 } // namespace content |
| 112 | 112 |
| 113 #endif // CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ | 113 #endif // CONTENT_BROWSER_GPU_BROWSER_GPU_CHANNEL_HOST_FACTORY_H_ |
| OLD | NEW |