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

Side by Side Diff: gpu/ipc/client/gpu_memory_buffer_impl_io_surface.h

Issue 2119723002: Color: Add SetColorSpace member to gfx::GpuMemoryBuffer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@plumb_2
Patch Set: Add OWNERs Created 4 years, 5 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
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 GPU_IPC_CLIENT_GPU_MEMORY_BUFFER_IMPL_IO_SURFACE_H_ 5 #ifndef GPU_IPC_CLIENT_GPU_MEMORY_BUFFER_IMPL_IO_SURFACE_H_
6 #define GPU_IPC_CLIENT_GPU_MEMORY_BUFFER_IMPL_IO_SURFACE_H_ 6 #define GPU_IPC_CLIENT_GPU_MEMORY_BUFFER_IMPL_IO_SURFACE_H_
7 7
8 #include <IOSurface/IOSurface.h> 8 #include <IOSurface/IOSurface.h>
9 #include <stddef.h> 9 #include <stddef.h>
10 #include <stdint.h> 10 #include <stdint.h>
(...skipping 25 matching lines...) Expand all
36 static base::Closure AllocateForTesting(const gfx::Size& size, 36 static base::Closure AllocateForTesting(const gfx::Size& size,
37 gfx::BufferFormat format, 37 gfx::BufferFormat format,
38 gfx::BufferUsage usage, 38 gfx::BufferUsage usage,
39 gfx::GpuMemoryBufferHandle* handle); 39 gfx::GpuMemoryBufferHandle* handle);
40 40
41 // Overridden from gfx::GpuMemoryBuffer: 41 // Overridden from gfx::GpuMemoryBuffer:
42 bool Map() override; 42 bool Map() override;
43 void* memory(size_t plane) override; 43 void* memory(size_t plane) override;
44 void Unmap() override; 44 void Unmap() override;
45 int stride(size_t plane) const override; 45 int stride(size_t plane) const override;
46 void SetColorSpaceForScanout(const gfx::ColorSpace& color_space) override;
46 gfx::GpuMemoryBufferHandle GetHandle() const override; 47 gfx::GpuMemoryBufferHandle GetHandle() const override;
47 48
48 private: 49 private:
49 GpuMemoryBufferImplIOSurface(gfx::GpuMemoryBufferId id, 50 GpuMemoryBufferImplIOSurface(gfx::GpuMemoryBufferId id,
50 const gfx::Size& size, 51 const gfx::Size& size,
51 gfx::BufferFormat format, 52 gfx::BufferFormat format,
52 const DestructionCallback& callback, 53 const DestructionCallback& callback,
53 IOSurfaceRef io_surface, 54 IOSurfaceRef io_surface,
54 uint32_t lock_flags); 55 uint32_t lock_flags);
55 56
56 base::ScopedCFTypeRef<IOSurfaceRef> io_surface_; 57 base::ScopedCFTypeRef<IOSurfaceRef> io_surface_;
57 uint32_t lock_flags_; 58 uint32_t lock_flags_;
58 59
59 DISALLOW_COPY_AND_ASSIGN(GpuMemoryBufferImplIOSurface); 60 DISALLOW_COPY_AND_ASSIGN(GpuMemoryBufferImplIOSurface);
60 }; 61 };
61 62
62 } // namespace gpu 63 } // namespace gpu
63 64
64 #endif // GPU_IPC_CLIENT_GPU_MEMORY_BUFFER_IMPL_IO_SURFACE_H_ 65 #endif // GPU_IPC_CLIENT_GPU_MEMORY_BUFFER_IMPL_IO_SURFACE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698