Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Side by Side Diff: android_webview/browser/gpu_memory_buffer_impl.h

Issue 13870010: Move GpuMemoryBuffer interface from ui/gl to gpu/command_buffer/client (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: include base/logging.h for DCHECK Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 ANDROID_WEBVIEW_BROWSER_GPU_MEMORY_BUFFER_IMPL_H_ 5 #ifndef ANDROID_WEBVIEW_BROWSER_GPU_MEMORY_BUFFER_IMPL_H_
6 #define ANDROID_WEBVIEW_BROWSER_GPU_MEMORY_BUFFER_IMPL_H_ 6 #define ANDROID_WEBVIEW_BROWSER_GPU_MEMORY_BUFFER_IMPL_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "gpu/command_buffer/client/gpu_memory_buffer.h"
10 #include "ui/gfx/size.h" 11 #include "ui/gfx/size.h"
11 #include "ui/gl/gpu_memory_buffer.h"
12 12
13 struct AwDrawGLFunctionTable; 13 struct AwDrawGLFunctionTable;
14 14
15 namespace android_webview { 15 namespace android_webview {
16 16
17 class GpuMemoryBufferImpl : public gfx::GpuMemoryBuffer { 17 class GpuMemoryBufferImpl : public gpu::GpuMemoryBuffer {
18 public: 18 public:
19 static void SetAwDrawGLFunctionTable(AwDrawGLFunctionTable* table); 19 static void SetAwDrawGLFunctionTable(AwDrawGLFunctionTable* table);
20 GpuMemoryBufferImpl(gfx::Size size); 20 GpuMemoryBufferImpl(gfx::Size size);
21 virtual ~GpuMemoryBufferImpl(); 21 virtual ~GpuMemoryBufferImpl();
22 22
23 // methods from GpuMemoryBuffer 23 // methods from GpuMemoryBuffer
24 virtual void Map(gfx::GpuMemoryBuffer::AccessMode mode, 24 virtual void Map(gpu::GpuMemoryBuffer::AccessMode mode,
25 void** vaddr) OVERRIDE; 25 void** vaddr) OVERRIDE;
26 virtual void Unmap() OVERRIDE; 26 virtual void Unmap() OVERRIDE;
27 virtual void* GetNativeBuffer() OVERRIDE; 27 virtual void* GetNativeBuffer() OVERRIDE;
28 virtual uint32 GetStride() OVERRIDE; 28 virtual uint32 GetStride() OVERRIDE;
29 29
30 private: 30 private:
31 int buffer_id_; 31 int buffer_id_;
32 gfx::Size size_; 32 gfx::Size size_;
33 33
34 DISALLOW_COPY_AND_ASSIGN(GpuMemoryBufferImpl); 34 DISALLOW_COPY_AND_ASSIGN(GpuMemoryBufferImpl);
35 }; 35 };
36 36
37 } // namespace android_webview 37 } // namespace android_webview
38 38
39 #endif // ANDROID_WEBVIEW_BROWSER_GPU_MEMORY_BUFFER_IMPL_H_ 39 #endif // ANDROID_WEBVIEW_BROWSER_GPU_MEMORY_BUFFER_IMPL_H_
OLDNEW
« no previous file with comments | « android_webview/browser/gpu_memory_buffer_factory_impl.cc ('k') | android_webview/browser/gpu_memory_buffer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698