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