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

Unified Diff: cc/quads/render_pass_unittest.cc

Issue 23455060: mix-blend-mode implementation for accelerated layers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: unittests fixed Created 7 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/quads/draw_quad_unittest.cc ('k') | cc/quads/shared_quad_state.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/quads/render_pass_unittest.cc
diff --git a/cc/quads/render_pass_unittest.cc b/cc/quads/render_pass_unittest.cc
index 394a3ec56a89ed188ae7aca1378686190238e477..e70a33dd685a7b3f3eff236ed79d70fbd31b256d 100644
--- a/cc/quads/render_pass_unittest.cc
+++ b/cc/quads/render_pass_unittest.cc
@@ -80,8 +80,13 @@ TEST(RenderPassTest, CopyShouldBeIdenticalExceptIdAndQuads) {
// Stick a quad in the pass, this should not get copied.
scoped_ptr<SharedQuadState> shared_state = SharedQuadState::Create();
- shared_state->SetAll(
- gfx::Transform(), gfx::Size(), gfx::Rect(), gfx::Rect(), false, 1);
+ shared_state->SetAll(gfx::Transform(),
+ gfx::Size(),
+ gfx::Rect(),
+ gfx::Rect(),
+ false,
+ 1,
+ SkXfermode::kSrcOver_Mode);
pass->AppendSharedQuadState(shared_state.Pass());
scoped_ptr<CheckerboardDrawQuad> checkerboard_quad =
@@ -126,8 +131,13 @@ TEST(RenderPassTest, CopyAllShouldBeIdentical) {
// Two quads using one shared state.
scoped_ptr<SharedQuadState> shared_state1 = SharedQuadState::Create();
- shared_state1->SetAll(
- gfx::Transform(), gfx::Size(1, 1), gfx::Rect(), gfx::Rect(), false, 1);
+ shared_state1->SetAll(gfx::Transform(),
+ gfx::Size(1, 1),
+ gfx::Rect(),
+ gfx::Rect(),
+ false,
+ 1,
+ SkXfermode::kSrcOver_Mode);
pass->AppendSharedQuadState(shared_state1.Pass());
scoped_ptr<CheckerboardDrawQuad> checkerboard_quad1 =
@@ -144,8 +154,13 @@ TEST(RenderPassTest, CopyAllShouldBeIdentical) {
// And two quads using another shared state.
scoped_ptr<SharedQuadState> shared_state2 = SharedQuadState::Create();
- shared_state2->SetAll(
- gfx::Transform(), gfx::Size(2, 2), gfx::Rect(), gfx::Rect(), false, 1);
+ shared_state2->SetAll(gfx::Transform(),
+ gfx::Size(2, 2),
+ gfx::Rect(),
+ gfx::Rect(),
+ false,
+ 1,
+ SkXfermode::kSrcOver_Mode);
pass->AppendSharedQuadState(shared_state2.Pass());
scoped_ptr<CheckerboardDrawQuad> checkerboard_quad3 =
@@ -176,8 +191,13 @@ TEST(RenderPassTest, CopyAllShouldBeIdentical) {
contrib_has_transparent_background);
scoped_ptr<SharedQuadState> contrib_shared_state = SharedQuadState::Create();
- contrib_shared_state->SetAll(
- gfx::Transform(), gfx::Size(2, 2), gfx::Rect(), gfx::Rect(), false, 1);
+ contrib_shared_state->SetAll(gfx::Transform(),
+ gfx::Size(2, 2),
+ gfx::Rect(),
+ gfx::Rect(),
+ false,
+ 1,
+ SkXfermode::kSrcOver_Mode);
contrib->AppendSharedQuadState(contrib_shared_state.Pass());
scoped_ptr<CheckerboardDrawQuad> contrib_quad =
@@ -228,8 +248,13 @@ TEST(RenderPassTest, CopyAllWithCulledQuads) {
// A shared state with a quad.
scoped_ptr<SharedQuadState> shared_state1 = SharedQuadState::Create();
- shared_state1->SetAll(
- gfx::Transform(), gfx::Size(1, 1), gfx::Rect(), gfx::Rect(), false, 1);
+ shared_state1->SetAll(gfx::Transform(),
+ gfx::Size(1, 1),
+ gfx::Rect(),
+ gfx::Rect(),
+ false,
+ 1,
+ SkXfermode::kSrcOver_Mode);
pass->AppendSharedQuadState(shared_state1.Pass());
scoped_ptr<CheckerboardDrawQuad> checkerboard_quad1 =
@@ -240,20 +265,35 @@ TEST(RenderPassTest, CopyAllWithCulledQuads) {
// A shared state with no quads, they were culled.
scoped_ptr<SharedQuadState> shared_state2 = SharedQuadState::Create();
- shared_state2->SetAll(
- gfx::Transform(), gfx::Size(2, 2), gfx::Rect(), gfx::Rect(), false, 1);
+ shared_state2->SetAll(gfx::Transform(),
+ gfx::Size(2, 2),
+ gfx::Rect(),
+ gfx::Rect(),
+ false,
+ 1,
+ SkXfermode::kSrcOver_Mode);
pass->AppendSharedQuadState(shared_state2.Pass());
// A second shared state with no quads.
scoped_ptr<SharedQuadState> shared_state3 = SharedQuadState::Create();
- shared_state3->SetAll(
- gfx::Transform(), gfx::Size(2, 2), gfx::Rect(), gfx::Rect(), false, 1);
+ shared_state3->SetAll(gfx::Transform(),
+ gfx::Size(2, 2),
+ gfx::Rect(),
+ gfx::Rect(),
+ false,
+ 1,
+ SkXfermode::kSrcOver_Mode);
pass->AppendSharedQuadState(shared_state3.Pass());
// A last shared state with a quad again.
scoped_ptr<SharedQuadState> shared_state4 = SharedQuadState::Create();
- shared_state4->SetAll(
- gfx::Transform(), gfx::Size(2, 2), gfx::Rect(), gfx::Rect(), false, 1);
+ shared_state4->SetAll(gfx::Transform(),
+ gfx::Size(2, 2),
+ gfx::Rect(),
+ gfx::Rect(),
+ false,
+ 1,
+ SkXfermode::kSrcOver_Mode);
pass->AppendSharedQuadState(shared_state4.Pass());
scoped_ptr<CheckerboardDrawQuad> checkerboard_quad2 =
« no previous file with comments | « cc/quads/draw_quad_unittest.cc ('k') | cc/quads/shared_quad_state.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698