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

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

Issue 23455060: mix-blend-mode implementation for accelerated layers (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressing comments 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 unified diff | Download patch
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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/trees/layer_tree_host_impl.h" 5 #include "cc/trees/layer_tree_host_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <limits> 8 #include <limits>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 570 matching lines...) Expand 10 before | Expand all | Expand 10 after
581 581
582 gfx::Rect root_target_rect = root_layer->render_surface()->content_rect(); 582 gfx::Rect root_target_rect = root_layer->render_surface()->content_rect();
583 float opacity = 1.f; 583 float opacity = 1.f;
584 SharedQuadState* shared_quad_state = 584 SharedQuadState* shared_quad_state =
585 quad_culler.UseSharedQuadState(SharedQuadState::Create()); 585 quad_culler.UseSharedQuadState(SharedQuadState::Create());
586 shared_quad_state->SetAll(root_layer->draw_transform(), 586 shared_quad_state->SetAll(root_layer->draw_transform(),
587 root_target_rect.size(), 587 root_target_rect.size(),
588 root_target_rect, 588 root_target_rect,
589 root_target_rect, 589 root_target_rect,
590 false, 590 false,
591 opacity); 591 opacity,
592 SkXfermode::kSrcOver_Mode);
592 593
593 AppendQuadsData append_quads_data; 594 AppendQuadsData append_quads_data;
594 595
595 gfx::Transform transform_to_layer_space(gfx::Transform::kSkipInitialization); 596 gfx::Transform transform_to_layer_space(gfx::Transform::kSkipInitialization);
596 bool did_invert = root_layer->screen_space_transform().GetInverse( 597 bool did_invert = root_layer->screen_space_transform().GetInverse(
597 &transform_to_layer_space); 598 &transform_to_layer_space);
598 DCHECK(did_invert); 599 DCHECK(did_invert);
599 for (Region::Iterator fill_rects(fill_region); 600 for (Region::Iterator fill_rects(fill_region);
600 fill_rects.has_rect(); 601 fill_rects.has_rect();
601 fill_rects.next()) { 602 fill_rects.next()) {
(...skipping 2200 matching lines...) Expand 10 before | Expand all | Expand 10 after
2802 std::set<UIResourceId>::iterator found_in_evicted = 2803 std::set<UIResourceId>::iterator found_in_evicted =
2803 evicted_ui_resources_.find(uid); 2804 evicted_ui_resources_.find(uid);
2804 if (found_in_evicted == evicted_ui_resources_.end()) 2805 if (found_in_evicted == evicted_ui_resources_.end())
2805 return; 2806 return;
2806 evicted_ui_resources_.erase(found_in_evicted); 2807 evicted_ui_resources_.erase(found_in_evicted);
2807 if (evicted_ui_resources_.empty()) 2808 if (evicted_ui_resources_.empty())
2808 client_->OnCanDrawStateChanged(CanDraw()); 2809 client_->OnCanDrawStateChanged(CanDraw());
2809 } 2810 }
2810 2811
2811 } // namespace cc 2812 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698