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

Side by Side Diff: content/common/gpu/client/gpu_memory_buffer_impl_foobar.h

Issue 186123006: zero copy - NOT FOR REVIEW Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: minus ui-map-image and ui-impl-side setting, plus tiled mode Created 6 years, 9 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_FOOBAR_H_
6 #define CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_FOOBAR_H_
7
8 #include "content/common/gpu/client/gpu_memory_buffer_impl.h"
9
10 struct _drm_intel_bo;
11
12 namespace content {
13
14 // Provides implementation of a GPU memory buffer based
15 // on a foobar object.
16 class GpuMemoryBufferImplFoobar : public GpuMemoryBufferImpl {
17 public:
18 GpuMemoryBufferImplFoobar(gfx::Size size, unsigned internalformat);
19 virtual ~GpuMemoryBufferImplFoobar();
20
21 static bool IsFormatSupported(unsigned internalformat);
22
23 bool InitializeFromFoobarObject(void *foobar_object);
24
25 // Overridden from gfx::GpuMemoryBuffer:
26 virtual void Map(AccessMode mode, void** vaddr) OVERRIDE;
27 virtual void Unmap() OVERRIDE;
28 virtual gfx::GpuMemoryBufferHandle GetHandle() const OVERRIDE;
29
30 private:
31 struct _drm_intel_bo *foobar_object;
32 mutable int _prime_fd;
33 int prime_fd() const;
34 DISALLOW_COPY_AND_ASSIGN(GpuMemoryBufferImplFoobar);
35 };
36
37 } // namespace content
38
39 #endif // CONTENT_COMMON_GPU_CLIENT_GPU_MEMORY_BUFFER_IMPL_FOOBAR_H_
OLDNEW
« no previous file with comments | « content/common/gpu/client/gpu_channel_host.cc ('k') | content/common/gpu/client/gpu_memory_buffer_impl_foobar.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698