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

Side by Side Diff: cc/test/test_in_process_context_provider.cc

Issue 429863002: Remove GLInProcessContext::CreateContext() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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 #include "cc/test/test_in_process_context_provider.h" 5 #include "cc/test/test_in_process_context_provider.h"
6 6
7 #include "base/lazy_instance.h" 7 #include "base/lazy_instance.h"
8 #include "gpu/GLES2/gl2extchromium.h" 8 #include "gpu/GLES2/gl2extchromium.h"
9 #include "gpu/command_buffer/client/gl_in_process_context.h" 9 #include "gpu/command_buffer/client/gl_in_process_context.h"
10 #include "gpu/command_buffer/client/gles2_implementation.h" 10 #include "gpu/command_buffer/client/gles2_implementation.h"
(...skipping 16 matching lines...) Expand all
27 attribs.blue_size = 8; 27 attribs.blue_size = 8;
28 attribs.green_size = 8; 28 attribs.green_size = 8;
29 attribs.red_size = 8; 29 attribs.red_size = 8;
30 attribs.depth_size = 24; 30 attribs.depth_size = 24;
31 attribs.stencil_size = 8; 31 attribs.stencil_size = 8;
32 attribs.samples = 0; 32 attribs.samples = 0;
33 attribs.sample_buffers = 0; 33 attribs.sample_buffers = 0;
34 attribs.fail_if_major_perf_caveat = false; 34 attribs.fail_if_major_perf_caveat = false;
35 gfx::GpuPreference gpu_preference = gfx::PreferDiscreteGpu; 35 gfx::GpuPreference gpu_preference = gfx::PreferDiscreteGpu;
36 36
37 scoped_ptr<gpu::GLInProcessContext> context = make_scoped_ptr( 37 scoped_ptr<gpu::GLInProcessContext> context =
38 gpu::GLInProcessContext::CreateContext(is_offscreen, 38 make_scoped_ptr(gpu::GLInProcessContext::Create(
39 gfx::AcceleratedWidget(), 39 scoped_refptr<gpu::InProcessCommandBuffer::Service>(),
piman 2014/07/31 02:42:29 nit: NULL should work too.
hj.r.chung 2014/07/31 08:35:35 Done.
40 gfx::Size(1, 1), 40 NULL,
41 share_resources, 41 is_offscreen,
42 attribs, 42 gfx::Size(1, 1),
43 gpu_preference)); 43 NULL,
44 share_resources,
45 attribs,
46 gpu_preference));
47
44 DCHECK(context); 48 DCHECK(context);
45 return context.Pass(); 49 return context.Pass();
46 } 50 }
47 51
48 TestInProcessContextProvider::TestInProcessContextProvider() 52 TestInProcessContextProvider::TestInProcessContextProvider()
49 : context_(CreateTestInProcessContext()) {} 53 : context_(CreateTestInProcessContext()) {}
50 54
51 TestInProcessContextProvider::~TestInProcessContextProvider() { 55 TestInProcessContextProvider::~TestInProcessContextProvider() {
52 } 56 }
53 57
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
122 126
123 bool TestInProcessContextProvider::DestroyedOnMainThread() { return false; } 127 bool TestInProcessContextProvider::DestroyedOnMainThread() { return false; }
124 128
125 void TestInProcessContextProvider::SetLostContextCallback( 129 void TestInProcessContextProvider::SetLostContextCallback(
126 const LostContextCallback& lost_context_callback) {} 130 const LostContextCallback& lost_context_callback) {}
127 131
128 void TestInProcessContextProvider::SetMemoryPolicyChangedCallback( 132 void TestInProcessContextProvider::SetMemoryPolicyChangedCallback(
129 const MemoryPolicyChangedCallback& memory_policy_changed_callback) {} 133 const MemoryPolicyChangedCallback& memory_policy_changed_callback) {}
130 134
131 } // namespace cc 135 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698