| 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/layer_tree_host_impl.h" | 5 #include "cc/layer_tree_host_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
| (...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 409 forSurface); | 409 forSurface); |
| 410 | 410 |
| 411 // Manually create the quad state for the gutter quads, as the root layer | 411 // Manually create the quad state for the gutter quads, as the root layer |
| 412 // doesn't have any bounds and so can't generate this itself. | 412 // doesn't have any bounds and so can't generate this itself. |
| 413 // FIXME: Make the gutter quads generated by the solid color layer (make it
smarter about generating quads to fill unoccluded areas). | 413 // FIXME: Make the gutter quads generated by the solid color layer (make it
smarter about generating quads to fill unoccluded areas). |
| 414 | 414 |
| 415 gfx::Rect rootTargetRect = rootLayer->renderSurface()->contentRect(); | 415 gfx::Rect rootTargetRect = rootLayer->renderSurface()->contentRect(); |
| 416 float opacity = 1; | 416 float opacity = 1; |
| 417 SharedQuadState* sharedQuadState = quadCuller.useSharedQuadState(SharedQuadS
tate::Create()); | 417 SharedQuadState* sharedQuadState = quadCuller.useSharedQuadState(SharedQuadS
tate::Create()); |
| 418 sharedQuadState->SetAll(rootLayer->drawTransform(), | 418 sharedQuadState->SetAll(rootLayer->drawTransform(), |
| 419 rootTargetRect.size(), |
| 419 rootTargetRect, | 420 rootTargetRect, |
| 420 rootTargetRect, | 421 rootTargetRect, |
| 421 false, | 422 false, |
| 422 opacity); | 423 opacity); |
| 423 | 424 |
| 424 AppendQuadsData appendQuadsData; | 425 AppendQuadsData appendQuadsData; |
| 425 | 426 |
| 426 gfx::Transform transformToLayerSpace(gfx::Transform::kSkipInitialization); | 427 gfx::Transform transformToLayerSpace(gfx::Transform::kSkipInitialization); |
| 427 bool didInvert = rootLayer->screenSpaceTransform().GetInverse(&transformToLa
yerSpace); | 428 bool didInvert = rootLayer->screenSpaceTransform().GetInverse(&transformToLa
yerSpace); |
| 428 DCHECK(didInvert); | 429 DCHECK(didInvert); |
| (...skipping 1294 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1723 m_tileManager->SetRecordRenderingStats(m_debugState.recordRenderingStats
()); | 1724 m_tileManager->SetRecordRenderingStats(m_debugState.recordRenderingStats
()); |
| 1724 } | 1725 } |
| 1725 | 1726 |
| 1726 void LayerTreeHostImpl::savePaintTime(const base::TimeDelta& totalPaintTime, int
commitNumber) | 1727 void LayerTreeHostImpl::savePaintTime(const base::TimeDelta& totalPaintTime, int
commitNumber) |
| 1727 { | 1728 { |
| 1728 DCHECK(m_debugState.continuousPainting); | 1729 DCHECK(m_debugState.continuousPainting); |
| 1729 m_paintTimeCounter->SavePaintTime(totalPaintTime, commitNumber); | 1730 m_paintTimeCounter->SavePaintTime(totalPaintTime, commitNumber); |
| 1730 } | 1731 } |
| 1731 | 1732 |
| 1732 } // namespace cc | 1733 } // namespace cc |
| OLD | NEW |