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

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

Issue 1336733002: Re-land: cc: Implement shared worker contexts. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix typo in last patch Created 5 years, 3 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 #ifndef CC_TREES_LAYER_TREE_HOST_IMPL_H_ 5 #ifndef CC_TREES_LAYER_TREE_HOST_IMPL_H_
6 #define CC_TREES_LAYER_TREE_HOST_IMPL_H_ 6 #define CC_TREES_LAYER_TREE_HOST_IMPL_H_
7 7
8 #include <set> 8 #include <set>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 void SetMemoryPolicy(const ManagedMemoryPolicy& policy) override; 356 void SetMemoryPolicy(const ManagedMemoryPolicy& policy) override;
357 void SetTreeActivationCallback(const base::Closure& callback) override; 357 void SetTreeActivationCallback(const base::Closure& callback) override;
358 void OnDraw() override; 358 void OnDraw() override;
359 359
360 // Called from LayerTreeImpl. 360 // Called from LayerTreeImpl.
361 void OnCanDrawStateChangedForTree(); 361 void OnCanDrawStateChangedForTree();
362 362
363 // Implementation. 363 // Implementation.
364 int id() const { return id_; } 364 int id() const { return id_; }
365 bool CanDraw() const; 365 bool CanDraw() const;
366 OutputSurface* output_surface() const { return output_surface_.get(); } 366 OutputSurface* output_surface() const { return output_surface_; }
367 367
368 std::string LayerTreeAsJson() const; 368 std::string LayerTreeAsJson() const;
369 369
370 void FinishAllRendering(); 370 void FinishAllRendering();
371 int RequestedMSAASampleCount() const; 371 int RequestedMSAASampleCount() const;
372 372
373 virtual bool InitializeRenderer(scoped_ptr<OutputSurface> output_surface); 373 virtual bool InitializeRenderer(OutputSurface* output_surface);
374 TileManager* tile_manager() { return tile_manager_.get(); } 374 TileManager* tile_manager() { return tile_manager_.get(); }
375 375
376 void SetHasGpuRasterizationTrigger(bool flag) { 376 void SetHasGpuRasterizationTrigger(bool flag) {
377 has_gpu_rasterization_trigger_ = flag; 377 has_gpu_rasterization_trigger_ = flag;
378 UpdateGpuRasterizationStatus(); 378 UpdateGpuRasterizationStatus();
379 } 379 }
380 void SetContentIsSuitableForGpuRasterization(bool flag) { 380 void SetContentIsSuitableForGpuRasterization(bool flag) {
381 content_is_suitable_for_gpu_rasterization_ = flag; 381 content_is_suitable_for_gpu_rasterization_ = flag;
382 UpdateGpuRasterizationStatus(); 382 UpdateGpuRasterizationStatus();
383 } 383 }
(...skipping 309 matching lines...) Expand 10 before | Expand all | Expand 10 after
693 693
694 typedef base::hash_map<UIResourceId, UIResourceData> 694 typedef base::hash_map<UIResourceId, UIResourceData>
695 UIResourceMap; 695 UIResourceMap;
696 UIResourceMap ui_resource_map_; 696 UIResourceMap ui_resource_map_;
697 697
698 // Resources that were evicted by EvictAllUIResources. Resources are removed 698 // Resources that were evicted by EvictAllUIResources. Resources are removed
699 // from this when they are touched by a create or destroy from the UI resource 699 // from this when they are touched by a create or destroy from the UI resource
700 // request queue. 700 // request queue.
701 std::set<UIResourceId> evicted_ui_resources_; 701 std::set<UIResourceId> evicted_ui_resources_;
702 702
703 scoped_ptr<OutputSurface> output_surface_; 703 OutputSurface* output_surface_;
704 704
705 scoped_ptr<ResourceProvider> resource_provider_; 705 scoped_ptr<ResourceProvider> resource_provider_;
706 bool content_is_suitable_for_gpu_rasterization_; 706 bool content_is_suitable_for_gpu_rasterization_;
707 bool has_gpu_rasterization_trigger_; 707 bool has_gpu_rasterization_trigger_;
708 bool use_gpu_rasterization_; 708 bool use_gpu_rasterization_;
709 bool use_msaa_; 709 bool use_msaa_;
710 GpuRasterizationStatus gpu_rasterization_status_; 710 GpuRasterizationStatus gpu_rasterization_status_;
711 bool tree_resources_for_gpu_rasterization_dirty_; 711 bool tree_resources_for_gpu_rasterization_dirty_;
712 scoped_ptr<TileTaskWorkerPool> tile_task_worker_pool_; 712 scoped_ptr<TileTaskWorkerPool> tile_task_worker_pool_;
713 scoped_ptr<ResourcePool> resource_pool_; 713 scoped_ptr<ResourcePool> resource_pool_;
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
821 scoped_ptr<FrameTimingTracker> frame_timing_tracker_; 821 scoped_ptr<FrameTimingTracker> frame_timing_tracker_;
822 822
823 scoped_ptr<Viewport> viewport_; 823 scoped_ptr<Viewport> viewport_;
824 824
825 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl); 825 DISALLOW_COPY_AND_ASSIGN(LayerTreeHostImpl);
826 }; 826 };
827 827
828 } // namespace cc 828 } // namespace cc
829 829
830 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_ 830 #endif // CC_TREES_LAYER_TREE_HOST_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698