| OLD | NEW |
| 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/layers/render_surface_impl.h" | 5 #include "cc/layers/render_surface_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/strings/stringprintf.h" | 10 #include "base/strings/stringprintf.h" |
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 | 149 |
| 150 const gfx::Transform& draw_transform = | 150 const gfx::Transform& draw_transform = |
| 151 for_replica ? replica_draw_transform_ : draw_transform_; | 151 for_replica ? replica_draw_transform_ : draw_transform_; |
| 152 SharedQuadState* shared_quad_state = | 152 SharedQuadState* shared_quad_state = |
| 153 quad_sink->UseSharedQuadState(SharedQuadState::Create()); | 153 quad_sink->UseSharedQuadState(SharedQuadState::Create()); |
| 154 shared_quad_state->SetAll(draw_transform, | 154 shared_quad_state->SetAll(draw_transform, |
| 155 content_rect_.size(), | 155 content_rect_.size(), |
| 156 content_rect_, | 156 content_rect_, |
| 157 clip_rect_, | 157 clip_rect_, |
| 158 is_clipped_, | 158 is_clipped_, |
| 159 draw_opacity_); | 159 draw_opacity_, |
| 160 owning_layer_->blend_mode()); |
| 160 | 161 |
| 161 if (owning_layer_->ShowDebugBorders()) { | 162 if (owning_layer_->ShowDebugBorders()) { |
| 162 SkColor color = for_replica ? | 163 SkColor color = for_replica ? |
| 163 DebugColors::SurfaceReplicaBorderColor() : | 164 DebugColors::SurfaceReplicaBorderColor() : |
| 164 DebugColors::SurfaceBorderColor(); | 165 DebugColors::SurfaceBorderColor(); |
| 165 float width = for_replica ? | 166 float width = for_replica ? |
| 166 DebugColors::SurfaceReplicaBorderWidth( | 167 DebugColors::SurfaceReplicaBorderWidth( |
| 167 owning_layer_->layer_tree_impl()) : | 168 owning_layer_->layer_tree_impl()) : |
| 168 DebugColors::SurfaceBorderWidth( | 169 DebugColors::SurfaceBorderWidth( |
| 169 owning_layer_->layer_tree_impl()); | 170 owning_layer_->layer_tree_impl()); |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 226 for_replica, | 227 for_replica, |
| 227 mask_resource_id, | 228 mask_resource_id, |
| 228 contents_changed_since_last_frame, | 229 contents_changed_since_last_frame, |
| 229 mask_uv_rect, | 230 mask_uv_rect, |
| 230 owning_layer_->filters(), | 231 owning_layer_->filters(), |
| 231 owning_layer_->background_filters()); | 232 owning_layer_->background_filters()); |
| 232 quad_sink->Append(quad.PassAs<DrawQuad>(), append_quads_data); | 233 quad_sink->Append(quad.PassAs<DrawQuad>(), append_quads_data); |
| 233 } | 234 } |
| 234 | 235 |
| 235 } // namespace cc | 236 } // namespace cc |
| OLD | NEW |