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

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

Issue 1895873006: compositor-worker: Initialize CW machinery plumbing to compositor and fire CW rAF callbacks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove unnecessary scope Created 4 years, 8 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
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.h" 5 #include "cc/trees/layer_tree_host.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 1264 matching lines...) Expand 10 before | Expand all | Expand 10 after
1275 proxy_->SetAuthoritativeVSyncInterval(interval); 1275 proxy_->SetAuthoritativeVSyncInterval(interval);
1276 } 1276 }
1277 1277
1278 void LayerTreeHost::RecordFrameTimingEvents( 1278 void LayerTreeHost::RecordFrameTimingEvents(
1279 std::unique_ptr<FrameTimingTracker::CompositeTimingSet> composite_events, 1279 std::unique_ptr<FrameTimingTracker::CompositeTimingSet> composite_events,
1280 std::unique_ptr<FrameTimingTracker::MainFrameTimingSet> main_frame_events) { 1280 std::unique_ptr<FrameTimingTracker::MainFrameTimingSet> main_frame_events) {
1281 client_->RecordFrameTimingEvents(std::move(composite_events), 1281 client_->RecordFrameTimingEvents(std::move(composite_events),
1282 std::move(main_frame_events)); 1282 std::move(main_frame_events));
1283 } 1283 }
1284 1284
1285 void LayerTreeHost::SetLayerTreeMutator(LayerTreeMutator* mutator) {
1286 proxy_->SetMutator(mutator);
1287 }
1288
1285 Layer* LayerTreeHost::LayerById(int id) const { 1289 Layer* LayerTreeHost::LayerById(int id) const {
1286 LayerIdMap::const_iterator iter = layer_id_map_.find(id); 1290 LayerIdMap::const_iterator iter = layer_id_map_.find(id);
1287 return iter != layer_id_map_.end() ? iter->second : NULL; 1291 return iter != layer_id_map_.end() ? iter->second : NULL;
1288 } 1292 }
1289 1293
1290 void LayerTreeHost::AddLayerShouldPushProperties(Layer* layer) { 1294 void LayerTreeHost::AddLayerShouldPushProperties(Layer* layer) {
1291 layers_that_should_push_properties_.insert(layer); 1295 layers_that_should_push_properties_.insert(layer);
1292 } 1296 }
1293 1297
1294 void LayerTreeHost::RemoveLayerShouldPushProperties(Layer* layer) { 1298 void LayerTreeHost::RemoveLayerShouldPushProperties(Layer* layer) {
(...skipping 354 matching lines...) Expand 10 before | Expand all | Expand 10 after
1649 [seq_num](Layer* layer) { 1653 [seq_num](Layer* layer) {
1650 layer->set_property_tree_sequence_number(seq_num); 1654 layer->set_property_tree_sequence_number(seq_num);
1651 }, 1655 },
1652 CallFunctionLayerType::ALL_LAYERS); 1656 CallFunctionLayerType::ALL_LAYERS);
1653 1657
1654 surface_id_namespace_ = proto.surface_id_namespace(); 1658 surface_id_namespace_ = proto.surface_id_namespace();
1655 next_surface_sequence_ = proto.next_surface_sequence(); 1659 next_surface_sequence_ = proto.next_surface_sequence();
1656 } 1660 }
1657 1661
1658 } // namespace cc 1662 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698