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

Side by Side Diff: cc/trees/layer_tree_host_pixeltest_blending.cc

Issue 754433003: Update from https://crrev.com/305340 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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/trees/layer_tree_host_impl_unittest.cc ('k') | cc/trees/layer_tree_host_pixeltest_masks.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/layers/image_layer.h" 5 #include "cc/layers/image_layer.h"
6 #include "cc/layers/solid_color_layer.h" 6 #include "cc/layers/solid_color_layer.h"
7 #include "cc/test/layer_tree_pixel_test.h" 7 #include "cc/test/layer_tree_pixel_test.h"
8 #include "cc/test/pixel_comparator.h" 8 #include "cc/test/pixel_comparator.h"
9 9
10 #if !defined(OS_ANDROID) 10 #if !defined(OS_ANDROID)
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 const uint32 kForceShaders = 1 << 3; 55 const uint32 kForceShaders = 1 << 3;
56 56
57 class LayerTreeHostBlendingPixelTest : public LayerTreePixelTest { 57 class LayerTreeHostBlendingPixelTest : public LayerTreePixelTest {
58 public: 58 public:
59 LayerTreeHostBlendingPixelTest() 59 LayerTreeHostBlendingPixelTest()
60 : force_antialiasing_(false), force_blending_with_shaders_(false) { 60 : force_antialiasing_(false), force_blending_with_shaders_(false) {
61 pixel_comparator_.reset(new FuzzyPixelOffByOneComparator(true)); 61 pixel_comparator_.reset(new FuzzyPixelOffByOneComparator(true));
62 } 62 }
63 63
64 void InitializeSettings(LayerTreeSettings* settings) override { 64 void InitializeSettings(LayerTreeSettings* settings) override {
65 settings->force_antialiasing = force_antialiasing_; 65 settings->renderer_settings.force_antialiasing = force_antialiasing_;
66 settings->force_blending_with_shaders = force_blending_with_shaders_; 66 settings->renderer_settings.force_blending_with_shaders =
67 force_blending_with_shaders_;
67 } 68 }
68 69
69 protected: 70 protected:
70 void RunBlendingWithRootPixelTestType(PixelTestType type) { 71 void RunBlendingWithRootPixelTestType(PixelTestType type) {
71 const int kLaneWidth = 2; 72 const int kLaneWidth = 2;
72 const int kLaneHeight = kLaneWidth; 73 const int kLaneHeight = kLaneWidth;
73 const int kRootWidth = (kBlendModesCount + 2) * kLaneWidth; 74 const int kRootWidth = (kBlendModesCount + 2) * kLaneWidth;
74 const int kRootHeight = 2 * kLaneWidth + kLaneHeight; 75 const int kRootHeight = 2 * kLaneWidth + kLaneHeight;
75 76
76 scoped_refptr<SolidColorLayer> background = 77 scoped_refptr<SolidColorLayer> background =
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 BlendingWithRenderPassShadersWithMaskColorMatrixAA_GL) { 468 BlendingWithRenderPassShadersWithMaskColorMatrixAA_GL) {
468 RunBlendingWithRenderPass( 469 RunBlendingWithRenderPass(
469 PIXEL_TEST_GL, FILE_PATH_LITERAL("blending_render_pass_mask.png"), 470 PIXEL_TEST_GL, FILE_PATH_LITERAL("blending_render_pass_mask.png"),
470 kUseMasks | kUseAntialiasing | kUseColorMatrix | kForceShaders); 471 kUseMasks | kUseAntialiasing | kUseColorMatrix | kForceShaders);
471 } 472 }
472 473
473 } // namespace 474 } // namespace
474 } // namespace cc 475 } // namespace cc
475 476
476 #endif // OS_ANDROID 477 #endif // OS_ANDROID
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_impl_unittest.cc ('k') | cc/trees/layer_tree_host_pixeltest_masks.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698