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 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
219 uv_scale_y); | 219 uv_scale_y); |
220 } | 220 } |
221 | 221 |
222 ResourceProvider::ResourceId mask_resource_id = | 222 ResourceProvider::ResourceId mask_resource_id = |
223 mask_layer ? mask_layer->ContentsResourceId() : 0; | 223 mask_layer ? mask_layer->ContentsResourceId() : 0; |
224 gfx::Rect contents_changed_since_last_frame = | 224 gfx::Rect contents_changed_since_last_frame = |
225 ContentsChanged() ? content_rect_ : gfx::Rect(); | 225 ContentsChanged() ? content_rect_ : gfx::Rect(); |
226 | 226 |
227 RenderPassDrawQuad* quad = | 227 RenderPassDrawQuad* quad = |
228 render_pass->CreateAndAppendDrawQuad<RenderPassDrawQuad>(); | 228 render_pass->CreateAndAppendDrawQuad<RenderPassDrawQuad>(); |
229 gfx::Transform owning_layer_to_target_scale; | |
230 owning_layer_to_target_scale.Scale(owning_layer_->contents_scale_x(), | |
231 owning_layer_->contents_scale_y()); | |
232 owning_layer_to_target_scale.PreconcatTransform( | |
enne (OOO)
2014/07/25 22:45:51
Do you really need the full transform multiplicati
garykac
2014/07/29 17:10:01
Done.
| |
233 owning_layer_->draw_properties().target_space_transform); | |
234 DCHECK(owning_layer_to_target_scale.IsScale2d()); | |
229 quad->SetNew(shared_quad_state, | 235 quad->SetNew(shared_quad_state, |
230 content_rect_, | 236 content_rect_, |
231 visible_content_rect, | 237 visible_content_rect, |
232 render_pass_id, | 238 render_pass_id, |
233 for_replica, | 239 for_replica, |
234 mask_resource_id, | 240 mask_resource_id, |
235 contents_changed_since_last_frame, | 241 contents_changed_since_last_frame, |
236 mask_uv_rect, | 242 mask_uv_rect, |
237 owning_layer_->filters(), | 243 owning_layer_->filters(), |
244 owning_layer_to_target_scale.Scale2d(), | |
238 owning_layer_->background_filters()); | 245 owning_layer_->background_filters()); |
239 } | 246 } |
240 | 247 |
241 } // namespace cc | 248 } // namespace cc |
OLD | NEW |