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

Side by Side Diff: cc/resources/managed_tile_state.h

Issue 12642010: Implement on demand quad rasterization for PicturePiles. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: build fix. Created 7 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_RESOURCES_MANAGED_TILE_STATE_H_ 5 #ifndef CC_RESOURCES_MANAGED_TILE_STATE_H_
6 #define CC_RESOURCES_MANAGED_TILE_STATE_H_ 6 #define CC_RESOURCES_MANAGED_TILE_STATE_H_
7 7
8 #include <list> 8 #include <list>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 69
70 void set_transparent() { 70 void set_transparent() {
71 mode_ = TRANSPARENT_MODE; 71 mode_ = TRANSPARENT_MODE;
72 } 72 }
73 73
74 void set_solid_color(const SkColor& color) { 74 void set_solid_color(const SkColor& color) {
75 mode_ = SOLID_COLOR_MODE; 75 mode_ = SOLID_COLOR_MODE;
76 solid_color_ = color; 76 solid_color_ = color;
77 } 77 }
78 78
79 void set_rasterize_on_demand() {
80 mode_ = PICTURE_PILE_MODE;
81 }
82
79 Mode mode_; 83 Mode mode_;
80 SkColor solid_color_; 84 SkColor solid_color_;
81 85
82 scoped_ptr<ResourcePool::Resource> resource_; 86 scoped_ptr<ResourcePool::Resource> resource_;
83 bool resource_is_being_initialized_; 87 bool resource_is_being_initialized_;
84 bool can_be_freed_; 88 bool can_be_freed_;
85 bool contents_swizzled_; 89 bool contents_swizzled_;
86 }; 90 };
87 91
88 92
(...skipping 19 matching lines...) Expand all
108 // to determine policy. 112 // to determine policy.
109 TileManagerBin gpu_memmgr_stats_bin; 113 TileManagerBin gpu_memmgr_stats_bin;
110 TileResolution resolution; 114 TileResolution resolution;
111 float time_to_needed_in_seconds; 115 float time_to_needed_in_seconds;
112 float distance_to_visible_in_pixels; 116 float distance_to_visible_in_pixels;
113 }; 117 };
114 118
115 } // namespace cc 119 } // namespace cc
116 120
117 #endif // CC_RESOURCES_MANAGED_TILE_STATE_H_ 121 #endif // CC_RESOURCES_MANAGED_TILE_STATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698