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

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

Issue 1864373002: Remove unused features for in-process GL contexts. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: inproclost: callback Created 4 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
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/layer_tree_pixel_test.h" 5 #include "cc/test/layer_tree_pixel_test.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 scoped_ptr<PixelTestSoftwareOutputDevice> software_output_device( 47 scoped_ptr<PixelTestSoftwareOutputDevice> software_output_device(
48 new PixelTestSoftwareOutputDevice); 48 new PixelTestSoftwareOutputDevice);
49 software_output_device->set_surface_expansion_size( 49 software_output_device->set_surface_expansion_size(
50 surface_expansion_size); 50 surface_expansion_size);
51 output_surface = make_scoped_ptr( 51 output_surface = make_scoped_ptr(
52 new PixelTestOutputSurface(std::move(software_output_device))); 52 new PixelTestOutputSurface(std::move(software_output_device)));
53 break; 53 break;
54 } 54 }
55 case PIXEL_TEST_GL: { 55 case PIXEL_TEST_GL: {
56 bool flipped_output_surface = false; 56 bool flipped_output_surface = false;
57 scoped_refptr<TestInProcessContextProvider> compositor(
58 new TestInProcessContextProvider(nullptr));
59 scoped_refptr<TestInProcessContextProvider> worker(
60 new TestInProcessContextProvider(compositor.get()));
57 output_surface = make_scoped_ptr(new PixelTestOutputSurface( 61 output_surface = make_scoped_ptr(new PixelTestOutputSurface(
58 new TestInProcessContextProvider, new TestInProcessContextProvider, 62 std::move(compositor), std::move(worker), flipped_output_surface));
59 flipped_output_surface));
60 break; 63 break;
61 } 64 }
62 } 65 }
63 66
64 output_surface->set_surface_expansion_size(surface_expansion_size); 67 output_surface->set_surface_expansion_size(surface_expansion_size);
65 return std::move(output_surface); 68 return std::move(output_surface);
66 } 69 }
67 70
68 void LayerTreePixelTest::WillCommitCompleteOnThread(LayerTreeHostImpl* impl) { 71 void LayerTreePixelTest::WillCommitCompleteOnThread(LayerTreeHostImpl* impl) {
69 if (impl->sync_tree()->source_frame_number() != 0) 72 if (impl->sync_tree()->source_frame_number() != 0)
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
268 return bitmap; 271 return bitmap;
269 } 272 }
270 273
271 void LayerTreePixelTest::Finish() { 274 void LayerTreePixelTest::Finish() {
272 scoped_ptr<gpu::GLInProcessContext> context = CreateTestInProcessContext(); 275 scoped_ptr<gpu::GLInProcessContext> context = CreateTestInProcessContext();
273 GLES2Interface* gl = context->GetImplementation(); 276 GLES2Interface* gl = context->GetImplementation();
274 gl->Finish(); 277 gl->Finish();
275 } 278 }
276 279
277 } // namespace cc 280 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698