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

Unified Diff: cc/layers/picture_layer_impl.h

Issue 812543002: Update from https://crrev.com/308331 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/layers/picture_layer.cc ('k') | cc/layers/picture_layer_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layers/picture_layer_impl.h
diff --git a/cc/layers/picture_layer_impl.h b/cc/layers/picture_layer_impl.h
index ddf928b621ed1d31bc818ef26d585655f97344cd..f17743d421b51a0835dc63279fe0da07216ff2a1 100644
--- a/cc/layers/picture_layer_impl.h
+++ b/cc/layers/picture_layer_impl.h
@@ -39,8 +39,10 @@ class CC_EXPORT PictureLayerImpl
PictureLayerImpl* pending;
};
- static scoped_ptr<PictureLayerImpl> Create(LayerTreeImpl* tree_impl, int id) {
- return make_scoped_ptr(new PictureLayerImpl(tree_impl, id));
+ static scoped_ptr<PictureLayerImpl> Create(LayerTreeImpl* tree_impl,
+ int id,
+ bool is_mask) {
+ return make_scoped_ptr(new PictureLayerImpl(tree_impl, id, is_mask));
}
~PictureLayerImpl() override;
@@ -73,9 +75,6 @@ class CC_EXPORT PictureLayerImpl
PictureLayerTiling* GetRecycledTwinTiling(
const PictureLayerTiling* tiling) override;
TilePriority::PriorityBin GetMaxTilePriorityBin() const override;
- size_t GetMaxTilesForInterestArea() const override;
- float GetSkewportTargetTimeInSeconds() const override;
- int GetSkewportExtrapolationLimitInContentPixels() const override;
WhichTree GetTree() const override;
bool RequiresHighResToDraw() const override;
@@ -85,7 +84,8 @@ class CC_EXPORT PictureLayerImpl
// Mask-related functions.
void GetContentsResourceId(ResourceProvider::ResourceId* resource_id,
gfx::Size* resource_size) const override;
- void set_is_mask(bool is_mask) { is_mask_ = is_mask; }
+
+ void SetNearestNeighbor(bool nearest_neighbor);
size_t GPUMemoryUsageInBytes() const override;
@@ -108,10 +108,9 @@ class CC_EXPORT PictureLayerImpl
friend class LayerRasterTileIterator;
using TileRequirementCheck = bool (PictureLayerTiling::*)(const Tile*) const;
- PictureLayerImpl(LayerTreeImpl* tree_impl, int id);
+ PictureLayerImpl(LayerTreeImpl* tree_impl, int id, bool is_mask);
PictureLayerTiling* AddTiling(float contents_scale);
void RemoveAllTilings();
- void SyncFromActiveLayer(const PictureLayerImpl* other);
void AddTilingsForRasterScale();
void UpdateTilePriorities(const Occlusion& occlusion_in_content_space);
virtual bool ShouldAdjustRasterScale() const;
@@ -122,7 +121,9 @@ class CC_EXPORT PictureLayerImpl
void ResetRasterScale();
gfx::Rect GetViewportForTilePriorityInContentSpace() const;
PictureLayerImpl* GetRecycledTwinLayer() const;
- void UpdateRasterSource(scoped_refptr<RasterSource> raster_source);
+ void UpdateRasterSource(scoped_refptr<RasterSource> raster_source,
+ Region* new_invalidation,
+ const PictureLayerTilingSet* pending_set);
void DoPostCommitInitializationIfNeeded() {
if (needs_post_commit_initialization_)
@@ -146,6 +147,7 @@ class CC_EXPORT PictureLayerImpl
virtual void UpdateIdealScales();
float MaximumTilingContentsScale() const;
+ scoped_ptr<PictureLayerTilingSet> CreatePictureLayerTilingSet();
PictureLayerImpl* twin_layer_;
@@ -171,7 +173,9 @@ class CC_EXPORT PictureLayerImpl
// after a CalculateContentsScale/ManageTilings.
bool should_update_tile_priorities_;
bool only_used_low_res_last_append_quads_;
- bool is_mask_;
+ const bool is_mask_;
+
+ bool nearest_neighbor_;
// Any draw properties derived from |transform|, |viewport|, and |clip|
// parameters in LayerTreeHostImpl::SetExternalDrawConstraints are not valid
« no previous file with comments | « cc/layers/picture_layer.cc ('k') | cc/layers/picture_layer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698