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

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

Issue 12545018: Move context-related callbacks into OutputSurface (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: unit test Created 7 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 | Annotate | Revision Log
« no previous file with comments | « cc/test/fake_output_surface.cc ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/pixel_test.h" 5 #include "cc/test/pixel_test.h"
6 6
7 #include "base/path_service.h" 7 #include "base/path_service.h"
8 #include "cc/output/compositor_frame_metadata.h" 8 #include "cc/output/compositor_frame_metadata.h"
9 #include "cc/output/gl_renderer.h" 9 #include "cc/output/gl_renderer.h"
10 #include "cc/output/output_surface.h" 10 #include "cc/output/output_surface.h"
(...skipping 12 matching lines...) Expand all
23 explicit PixelTestRendererClient(gfx::Size device_viewport_size) 23 explicit PixelTestRendererClient(gfx::Size device_viewport_size)
24 : device_viewport_size_(device_viewport_size) {} 24 : device_viewport_size_(device_viewport_size) {}
25 25
26 // RendererClient implementation. 26 // RendererClient implementation.
27 virtual gfx::Size DeviceViewportSize() const OVERRIDE { 27 virtual gfx::Size DeviceViewportSize() const OVERRIDE {
28 return device_viewport_size_; 28 return device_viewport_size_;
29 } 29 }
30 virtual const LayerTreeSettings& Settings() const OVERRIDE { 30 virtual const LayerTreeSettings& Settings() const OVERRIDE {
31 return settings_; 31 return settings_;
32 } 32 }
33 virtual void DidLoseOutputSurface() OVERRIDE {}
34 virtual void OnSwapBuffersComplete() OVERRIDE {}
35 virtual void SetFullRootLayerDamage() OVERRIDE {} 33 virtual void SetFullRootLayerDamage() OVERRIDE {}
36 virtual void SetManagedMemoryPolicy( 34 virtual void SetManagedMemoryPolicy(
37 const ManagedMemoryPolicy& policy) OVERRIDE {} 35 const ManagedMemoryPolicy& policy) OVERRIDE {}
38 virtual void EnforceManagedMemoryPolicy( 36 virtual void EnforceManagedMemoryPolicy(
39 const ManagedMemoryPolicy& policy) OVERRIDE {} 37 const ManagedMemoryPolicy& policy) OVERRIDE {}
40 virtual bool HasImplThread() const OVERRIDE { return false; } 38 virtual bool HasImplThread() const OVERRIDE { return false; }
41 virtual bool ShouldClearRootRenderPass() const OVERRIDE { return true; } 39 virtual bool ShouldClearRootRenderPass() const OVERRIDE { return true; }
42 virtual CompositorFrameMetadata MakeCompositorFrameMetadata() const 40 virtual CompositorFrameMetadata MakeCompositorFrameMetadata() const
43 OVERRIDE { 41 OVERRIDE {
44 return CompositorFrameMetadata(); 42 return CompositorFrameMetadata();
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 if (!PathService::Get(cc::DIR_TEST_DATA, &test_data_dir)) 93 if (!PathService::Get(cc::DIR_TEST_DATA, &test_data_dir))
96 return false; 94 return false;
97 95
98 // To rebaseline: 96 // To rebaseline:
99 // return WritePNGFile(bitmap, test_data_dir.Append(ref_file)); 97 // return WritePNGFile(bitmap, test_data_dir.Append(ref_file));
100 98
101 return MatchesPNGFile(bitmap, test_data_dir.Append(ref_file), comparator); 99 return MatchesPNGFile(bitmap, test_data_dir.Append(ref_file), comparator);
102 } 100 }
103 101
104 } // namespace cc 102 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/fake_output_surface.cc ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698