| Index: cc/layers/picture_layer_impl.cc
|
| diff --git a/cc/layers/picture_layer_impl.cc b/cc/layers/picture_layer_impl.cc
|
| index 54cfac88b32ec722abac90809ad0c5c9486e7731..36ac1ac30e9f155d556126ce2ccf0e791b2f9a7b 100644
|
| --- a/cc/layers/picture_layer_impl.cc
|
| +++ b/cc/layers/picture_layer_impl.cc
|
| @@ -277,6 +277,9 @@ void PictureLayerImpl::AppendQuads(RenderPass* render_pass,
|
| } else if (mode == ManagedTileState::DrawInfo::PICTURE_PILE_MODE) {
|
| color = DebugColors::PictureTileBorderColor();
|
| width = DebugColors::PictureTileBorderWidth(layer_tree_impl());
|
| + } else if (iter->draw_info().has_compressed_resource()) {
|
| + color = DebugColors::CompressedTileBorderColor();
|
| + width = DebugColors::CompressedTileBorderWidth(layer_tree_impl());
|
| } else if (iter.resolution() == HIGH_RESOLUTION) {
|
| color = DebugColors::HighResTileBorderColor();
|
| width = DebugColors::HighResTileBorderWidth(layer_tree_impl());
|
| @@ -381,7 +384,8 @@ void PictureLayerImpl::AppendQuads(RenderPass* render_pass,
|
| ResourceProvider* resource_provider =
|
| layer_tree_impl()->resource_provider();
|
| ResourceFormat format =
|
| - resource_provider->memory_efficient_texture_format();
|
| + resource_provider->memory_efficient_texture_format(
|
| + FORMAT_USAGE_NATIVE);
|
| PictureDrawQuad* quad =
|
| render_pass->CreateAndAppendDrawQuad<PictureDrawQuad>();
|
| quad->SetNew(shared_quad_state, geometry_rect, opaque_rect,
|
| @@ -616,17 +620,18 @@ skia::RefPtr<SkPicture> PictureLayerImpl::GetPicture() {
|
| }
|
|
|
| scoped_refptr<Tile> PictureLayerImpl::CreateTile(PictureLayerTiling* tiling,
|
| - const gfx::Rect& content_rect) {
|
| + const gfx::Rect& content_rect,
|
| + int flags) {
|
| DCHECK(!raster_source_->IsSolidColor());
|
| if (!raster_source_->CoversRect(content_rect, tiling->contents_scale()))
|
| return scoped_refptr<Tile>();
|
|
|
| - int flags = 0;
|
| -
|
| // We don't handle solid color masks, so we shouldn't bother analyzing those.
|
| // Otherwise, always analyze to maximize memory savings.
|
| if (!is_mask_)
|
| - flags = Tile::USE_PICTURE_ANALYSIS;
|
| + flags |= Tile::USE_PICTURE_ANALYSIS;
|
| + if (contents_opaque())
|
| + flags |= Tile::IS_OPAQUE;
|
|
|
| return layer_tree_impl()->tile_manager()->CreateTile(
|
| raster_source_.get(), content_rect.size(), content_rect,
|
| @@ -784,7 +789,8 @@ void PictureLayerImpl::SyncFromActiveLayer(const PictureLayerImpl* other) {
|
| if (CanHaveTilings()) {
|
| synced_high_res_tiling = tilings_->SyncTilings(
|
| *other->tilings_, raster_source_->GetSize(), invalidation_,
|
| - MinimumContentsScale(), raster_source_.get());
|
| + MinimumContentsScale(), raster_source_.get(),
|
| + layer_tree_impl()->CurrentBeginFrameArgs().frame_time);
|
| } else {
|
| RemoveAllTilings();
|
| }
|
|
|