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

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

Issue 628443002: replace OVERRIDE and FINAL with override and final in cc/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on master Created 6 years, 2 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
« no previous file with comments | « cc/test/pixel_comparator.h ('k') | cc/test/pixel_test_output_surface.h » ('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 "base/files/file_util.h" 5 #include "base/files/file_util.h"
6 #include "cc/output/gl_renderer.h" 6 #include "cc/output/gl_renderer.h"
7 #include "cc/output/software_renderer.h" 7 #include "cc/output/software_renderer.h"
8 #include "cc/quads/render_pass.h" 8 #include "cc/quads/render_pass.h"
9 #include "cc/test/pixel_comparator.h" 9 #include "cc/test/pixel_comparator.h"
10 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 55
56 void SetUpGLRenderer(bool use_skia_gpu_backend); 56 void SetUpGLRenderer(bool use_skia_gpu_backend);
57 void SetUpSoftwareRenderer(); 57 void SetUpSoftwareRenderer();
58 58
59 void ForceExpandedViewport(const gfx::Size& surface_expansion); 59 void ForceExpandedViewport(const gfx::Size& surface_expansion);
60 void ForceViewportOffset(const gfx::Vector2d& viewport_offset); 60 void ForceViewportOffset(const gfx::Vector2d& viewport_offset);
61 void ForceDeviceClip(const gfx::Rect& clip); 61 void ForceDeviceClip(const gfx::Rect& clip);
62 void EnableExternalStencilTest(); 62 void EnableExternalStencilTest();
63 63
64 // RendererClient implementation. 64 // RendererClient implementation.
65 virtual void SetFullRootLayerDamage() OVERRIDE {} 65 virtual void SetFullRootLayerDamage() override {}
66 66
67 private: 67 private:
68 void ReadbackResult(base::Closure quit_run_loop, 68 void ReadbackResult(base::Closure quit_run_loop,
69 scoped_ptr<CopyOutputResult> result); 69 scoped_ptr<CopyOutputResult> result);
70 70
71 bool PixelsMatchReference(const base::FilePath& ref_file, 71 bool PixelsMatchReference(const base::FilePath& ref_file,
72 const PixelComparator& comparator); 72 const PixelComparator& comparator);
73 73
74 scoped_ptr<gfx::DisableNullDrawGLBindings> enable_pixel_output_; 74 scoped_ptr<gfx::DisableNullDrawGLBindings> enable_pixel_output_;
75 }; 75 };
76 76
77 template<typename RendererType> 77 template<typename RendererType>
78 class RendererPixelTest : public PixelTest { 78 class RendererPixelTest : public PixelTest {
79 public: 79 public:
80 RendererType* renderer() { 80 RendererType* renderer() {
81 return static_cast<RendererType*>(renderer_.get()); 81 return static_cast<RendererType*>(renderer_.get());
82 } 82 }
83 83
84 bool UseSkiaGPUBackend() const; 84 bool UseSkiaGPUBackend() const;
85 bool ExpandedViewport() const; 85 bool ExpandedViewport() const;
86 86
87 protected: 87 protected:
88 virtual void SetUp() OVERRIDE; 88 virtual void SetUp() override;
89 }; 89 };
90 90
91 // Wrappers to differentiate renderers where the the output surface and viewport 91 // Wrappers to differentiate renderers where the the output surface and viewport
92 // have an externally determined size and offset. 92 // have an externally determined size and offset.
93 class GLRendererWithExpandedViewport : public GLRenderer { 93 class GLRendererWithExpandedViewport : public GLRenderer {
94 public: 94 public:
95 GLRendererWithExpandedViewport(RendererClient* client, 95 GLRendererWithExpandedViewport(RendererClient* client,
96 const LayerTreeSettings* settings, 96 const LayerTreeSettings* settings,
97 OutputSurface* output_surface, 97 OutputSurface* output_surface,
98 ResourceProvider* resource_provider, 98 ResourceProvider* resource_provider,
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 SoftwareRendererWithExpandedViewport>::ExpandedViewport() const { 182 SoftwareRendererWithExpandedViewport>::ExpandedViewport() const {
183 return true; 183 return true;
184 } 184 }
185 185
186 typedef RendererPixelTest<GLRenderer> GLRendererPixelTest; 186 typedef RendererPixelTest<GLRenderer> GLRendererPixelTest;
187 typedef RendererPixelTest<SoftwareRenderer> SoftwareRendererPixelTest; 187 typedef RendererPixelTest<SoftwareRenderer> SoftwareRendererPixelTest;
188 188
189 } // namespace cc 189 } // namespace cc
190 190
191 #endif // CC_TEST_PIXEL_TEST_H_ 191 #endif // CC_TEST_PIXEL_TEST_H_
OLDNEW
« no previous file with comments | « cc/test/pixel_comparator.h ('k') | cc/test/pixel_test_output_surface.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698