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

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

Issue 156603005: cc: Clean up iterator template to only take 1 parameter. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: iteratorcleanup: Created 6 years, 9 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/trees/layer_tree_host_common.cc ('k') | cc/trees/layer_tree_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 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 744 matching lines...) Expand 10 before | Expand all | Expand 10 after
755 755
756 if (debug_state_.show_occluding_rects) { 756 if (debug_state_.show_occluding_rects) {
757 occlusion_tracker.set_occluding_screen_space_rects_container( 757 occlusion_tracker.set_occluding_screen_space_rects_container(
758 &frame->occluding_screen_space_rects); 758 &frame->occluding_screen_space_rects);
759 } 759 }
760 if (debug_state_.show_non_occluding_rects) { 760 if (debug_state_.show_non_occluding_rects) {
761 occlusion_tracker.set_non_occluding_screen_space_rects_container( 761 occlusion_tracker.set_non_occluding_screen_space_rects_container(
762 &frame->non_occluding_screen_space_rects); 762 &frame->non_occluding_screen_space_rects);
763 } 763 }
764 764
765 // Add quads to the Render passes in FrontToBack order to allow for testing 765 // Add quads to the Render passes in front-to-back order to allow for testing
766 // occlusion and performing culling during the tree walk. 766 // occlusion and performing culling during the tree walk.
767 typedef LayerIterator<LayerImpl, 767 typedef LayerIterator<LayerImpl> LayerIteratorType;
768 LayerImplList,
769 RenderSurfaceImpl,
770 LayerIteratorActions::FrontToBack> LayerIteratorType;
771 768
772 // Typically when we are missing a texture and use a checkerboard quad, we 769 // Typically when we are missing a texture and use a checkerboard quad, we
773 // still draw the frame. However when the layer being checkerboarded is moving 770 // still draw the frame. However when the layer being checkerboarded is moving
774 // due to an impl-animation, we drop the frame to avoid flashing due to the 771 // due to an impl-animation, we drop the frame to avoid flashing due to the
775 // texture suddenly appearing in the future. 772 // texture suddenly appearing in the future.
776 DrawSwapReadbackResult::DrawResult draw_result = 773 DrawSwapReadbackResult::DrawResult draw_result =
777 DrawSwapReadbackResult::DRAW_SUCCESS; 774 DrawSwapReadbackResult::DRAW_SUCCESS;
778 // When we have a copy request for a layer, we need to draw no matter 775 // When we have a copy request for a layer, we need to draw no matter
779 // what, as the layer may disappear after this frame. 776 // what, as the layer may disappear after this frame.
780 bool have_copy_request = false; 777 bool have_copy_request = false;
(...skipping 2242 matching lines...) Expand 10 before | Expand all | Expand 10 after
3023 swap_promise_monitor_.erase(monitor); 3020 swap_promise_monitor_.erase(monitor);
3024 } 3021 }
3025 3022
3026 void LayerTreeHostImpl::NotifySwapPromiseMonitorsOfSetNeedsRedraw() { 3023 void LayerTreeHostImpl::NotifySwapPromiseMonitorsOfSetNeedsRedraw() {
3027 std::set<SwapPromiseMonitor*>::iterator it = swap_promise_monitor_.begin(); 3024 std::set<SwapPromiseMonitor*>::iterator it = swap_promise_monitor_.begin();
3028 for (; it != swap_promise_monitor_.end(); it++) 3025 for (; it != swap_promise_monitor_.end(); it++)
3029 (*it)->OnSetNeedsRedrawOnImpl(); 3026 (*it)->OnSetNeedsRedrawOnImpl();
3030 } 3027 }
3031 3028
3032 } // namespace cc 3029 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_common.cc ('k') | cc/trees/layer_tree_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698