| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_OZONE_H_ |
| 6 #define CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_OZONE_H_ |
| 7 |
| 8 #include "content/common/gpu/client/gpu_memory_buffer_impl.h" |
| 9 |
| 10 namespace content { |
| 11 |
| 12 // Provides implementation of a GPU memory buffer based on a surface texture id. |
| 13 class GpuMemoryBufferImplOzone : public GpuMemoryBufferImpl { |
| 14 public: |
| 15 GpuMemoryBufferImplOzone(gfx::Size size, |
| 16 unsigned internalformat, |
| 17 gfx::GpuMemoryBuffer::Usage usage); |
| 18 virtual ~GpuMemoryBufferImplOzone(); |
| 19 |
| 20 bool Initialize(gfx::GpuMemoryBufferHandle handle); |
| 21 |
| 22 static bool IsFormatSupported(unsigned internalformat); |
| 23 |
| 24 // Overridden from gfx::GpuMemoryBuffer: |
| 25 virtual void* Map() OVERRIDE; |
| 26 virtual void Unmap() OVERRIDE; |
| 27 virtual gfx::GpuMemoryBufferHandle GetHandle() const OVERRIDE; |
| 28 virtual uint32 GetStride() const OVERRIDE; |
| 29 |
| 30 private: |
| 31 DISALLOW_COPY_AND_ASSIGN(GpuMemoryBufferImplOzone); |
| 32 }; |
| 33 |
| 34 } // namespace content |
| 35 |
| 36 #endif // CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_OZONE_H_ |
| OLD | NEW |