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

Side by Side Diff: content/browser/compositor/reflector_impl_unittest.cc

Issue 1230203007: Re-land: cc: Use worker context for one-copy tile initialization. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 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 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 #include "base/run_loop.h" 5 #include "base/run_loop.h"
6 #include "base/single_thread_task_runner.h" 6 #include "base/single_thread_task_runner.h"
7 #include "cc/test/fake_output_surface_client.h" 7 #include "cc/test/fake_output_surface_client.h"
8 #include "cc/test/test_context_provider.h" 8 #include "cc/test/test_context_provider.h"
9 #include "cc/test/test_web_graphics_context_3d.h" 9 #include "cc/test/test_web_graphics_context_3d.h"
10 #include "content/browser/compositor/browser_compositor_output_surface.h" 10 #include "content/browser/compositor/browser_compositor_output_surface.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 return nullptr; 67 return nullptr;
68 #endif // defined(USE_OZONE) 68 #endif // defined(USE_OZONE)
69 } 69 }
70 70
71 class TestOutputSurface : public BrowserCompositorOutputSurface { 71 class TestOutputSurface : public BrowserCompositorOutputSurface {
72 public: 72 public:
73 TestOutputSurface( 73 TestOutputSurface(
74 const scoped_refptr<cc::ContextProvider>& context_provider, 74 const scoped_refptr<cc::ContextProvider>& context_provider,
75 const scoped_refptr<ui::CompositorVSyncManager>& vsync_manager) 75 const scoped_refptr<ui::CompositorVSyncManager>& vsync_manager)
76 : BrowserCompositorOutputSurface(context_provider, 76 : BrowserCompositorOutputSurface(context_provider,
77 nullptr,
77 vsync_manager, 78 vsync_manager,
78 CreateTestValidatorOzone().Pass()) {} 79 CreateTestValidatorOzone().Pass()) {}
79 80
80 void SetFlip(bool flip) { capabilities_.flipped_output_surface = flip; } 81 void SetFlip(bool flip) { capabilities_.flipped_output_surface = flip; }
81 82
82 void SwapBuffers(cc::CompositorFrame* frame) override {} 83 void SwapBuffers(cc::CompositorFrame* frame) override {}
83 84
84 void OnReflectorChanged() override { 85 void OnReflectorChanged() override {
85 if (!reflector_) { 86 if (!reflector_) {
86 reflector_texture_.reset(); 87 reflector_texture_.reset();
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
213 plane_2.plane_z_order = 1; 214 plane_2.plane_z_order = 1;
214 list.push_back(plane_1); 215 list.push_back(plane_1);
215 list.push_back(plane_2); 216 list.push_back(plane_2);
216 output_surface_->GetOverlayCandidateValidator()->CheckOverlaySupport(&list); 217 output_surface_->GetOverlayCandidateValidator()->CheckOverlaySupport(&list);
217 EXPECT_FALSE(list[0].overlay_handled); 218 EXPECT_FALSE(list[0].overlay_handled);
218 } 219 }
219 #endif // defined(USE_OZONE) 220 #endif // defined(USE_OZONE)
220 221
221 } // namespace 222 } // namespace
222 } // namespace content 223 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/compositor/offscreen_browser_compositor_output_surface.cc ('k') | content/browser/gpu/compositor_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698