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

Side by Side Diff: content/test/gpu_memory_buffer_impl_test_template.h

Issue 1417753007: ui: Revert gfx::BufferUsage::SCANOUT to gfx::BufferUsage::GPU_READ_WRITE change. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 1 month 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 // This file defines tests that implementations of GpuMemoryBufferFactory should 5 // This file defines tests that implementations of GpuMemoryBufferFactory should
6 // pass in order to be conformant. 6 // pass in order to be conformant.
7 7
8 #ifndef CONTENT_TEST_GPU_MEMORY_BUFFER_IMPL_TEST_TEMPLATE_H_ 8 #ifndef CONTENT_TEST_GPU_MEMORY_BUFFER_IMPL_TEST_TEMPLATE_H_
9 #define CONTENT_TEST_GPU_MEMORY_BUFFER_IMPL_TEST_TEMPLATE_H_ 9 #define CONTENT_TEST_GPU_MEMORY_BUFFER_IMPL_TEST_TEMPLATE_H_
10 10
(...skipping 28 matching lines...) Expand all
39 } 39 }
40 }; 40 };
41 41
42 TYPED_TEST_CASE_P(GpuMemoryBufferImplTest); 42 TYPED_TEST_CASE_P(GpuMemoryBufferImplTest);
43 43
44 TYPED_TEST_P(GpuMemoryBufferImplTest, CreateFromHandle) { 44 TYPED_TEST_P(GpuMemoryBufferImplTest, CreateFromHandle) {
45 const gfx::Size kBufferSize(8, 8); 45 const gfx::Size kBufferSize(8, 8);
46 46
47 for (auto format : gfx::GetBufferFormatsForTesting()) { 47 for (auto format : gfx::GetBufferFormatsForTesting()) {
48 gfx::BufferUsage usages[] = { 48 gfx::BufferUsage usages[] = {
49 gfx::BufferUsage::GPU_READ, gfx::BufferUsage::GPU_READ_WRITE, 49 gfx::BufferUsage::GPU_READ, gfx::BufferUsage::SCANOUT,
50 gfx::BufferUsage::GPU_READ_CPU_READ_WRITE, 50 gfx::BufferUsage::GPU_READ_CPU_READ_WRITE,
51 gfx::BufferUsage::GPU_READ_CPU_READ_WRITE_PERSISTENT}; 51 gfx::BufferUsage::GPU_READ_CPU_READ_WRITE_PERSISTENT};
52 for (auto usage : usages) { 52 for (auto usage : usages) {
53 if (!TypeParam::IsConfigurationSupported(format, usage)) 53 if (!TypeParam::IsConfigurationSupported(format, usage))
54 continue; 54 continue;
55 55
56 bool destroyed = false; 56 bool destroyed = false;
57 gfx::GpuMemoryBufferHandle handle; 57 gfx::GpuMemoryBufferHandle handle;
58 GpuMemoryBufferImpl::DestructionCallback destroy_callback = 58 GpuMemoryBufferImpl::DestructionCallback destroy_callback =
59 TestFixture::AllocateGpuMemoryBuffer(kBufferSize, format, usage, 59 TestFixture::AllocateGpuMemoryBuffer(kBufferSize, format, usage,
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 // The GpuMemoryBufferImplTest test case verifies behavior that is expected 195 // The GpuMemoryBufferImplTest test case verifies behavior that is expected
196 // from a GpuMemoryBuffer implementation in order to be conformant. 196 // from a GpuMemoryBuffer implementation in order to be conformant.
197 REGISTER_TYPED_TEST_CASE_P(GpuMemoryBufferImplTest, 197 REGISTER_TYPED_TEST_CASE_P(GpuMemoryBufferImplTest,
198 CreateFromHandle, 198 CreateFromHandle,
199 Map, 199 Map,
200 PersistentMap); 200 PersistentMap);
201 201
202 } // namespace content 202 } // namespace content
203 203
204 #endif // CONTENT_TEST_GPU_MEMORY_BUFFER_IMPL_TEST_TEMPLATE_H_ 204 #endif // CONTENT_TEST_GPU_MEMORY_BUFFER_IMPL_TEST_TEMPLATE_H_
OLDNEW
« no previous file with comments | « content/test/gpu_memory_buffer_factory_test_template.h ('k') | gpu/command_buffer/service/in_process_command_buffer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698