| 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 405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 416 forSurface); | 416 forSurface); |
| 417 | 417 |
| 418 // Manually create the quad state for the gutter quads, as the root layer | 418 // Manually create the quad state for the gutter quads, as the root layer |
| 419 // doesn't have any bounds and so can't generate this itself. | 419 // doesn't have any bounds and so can't generate this itself. |
| 420 // FIXME: Make the gutter quads generated by the solid color layer (make it
smarter about generating quads to fill unoccluded areas). | 420 // FIXME: Make the gutter quads generated by the solid color layer (make it
smarter about generating quads to fill unoccluded areas). |
| 421 | 421 |
| 422 gfx::Rect rootTargetRect = rootLayer->renderSurface()->contentRect(); | 422 gfx::Rect rootTargetRect = rootLayer->renderSurface()->contentRect(); |
| 423 float opacity = 1; | 423 float opacity = 1; |
| 424 SharedQuadState* sharedQuadState = quadCuller.useSharedQuadState(SharedQuadS
tate::Create()); | 424 SharedQuadState* sharedQuadState = quadCuller.useSharedQuadState(SharedQuadS
tate::Create()); |
| 425 sharedQuadState->SetAll(rootLayer->drawTransform(), | 425 sharedQuadState->SetAll(rootLayer->drawTransform(), |
| 426 rootTargetRect.size(), |
| 426 rootTargetRect, | 427 rootTargetRect, |
| 427 rootTargetRect, | 428 rootTargetRect, |
| 428 false, | 429 false, |
| 429 opacity); | 430 opacity); |
| 430 | 431 |
| 431 AppendQuadsData appendQuadsData; | 432 AppendQuadsData appendQuadsData; |
| 432 | 433 |
| 433 gfx::Transform transformToLayerSpace(gfx::Transform::kSkipInitialization); | 434 gfx::Transform transformToLayerSpace(gfx::Transform::kSkipInitialization); |
| 434 bool didInvert = rootLayer->screenSpaceTransform().GetInverse(&transformToLa
yerSpace); | 435 bool didInvert = rootLayer->screenSpaceTransform().GetInverse(&transformToLa
yerSpace); |
| 435 DCHECK(didInvert); | 436 DCHECK(didInvert); |
| (...skipping 1361 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1797 m_tileManager->SetRecordRenderingStats(m_debugState.recordRenderingStats
()); | 1798 m_tileManager->SetRecordRenderingStats(m_debugState.recordRenderingStats
()); |
| 1798 } | 1799 } |
| 1799 | 1800 |
| 1800 void LayerTreeHostImpl::savePaintTime(const base::TimeDelta& totalPaintTime, int
commitNumber) | 1801 void LayerTreeHostImpl::savePaintTime(const base::TimeDelta& totalPaintTime, int
commitNumber) |
| 1801 { | 1802 { |
| 1802 DCHECK(m_debugState.continuousPainting); | 1803 DCHECK(m_debugState.continuousPainting); |
| 1803 m_paintTimeCounter->SavePaintTime(totalPaintTime, commitNumber); | 1804 m_paintTimeCounter->SavePaintTime(totalPaintTime, commitNumber); |
| 1804 } | 1805 } |
| 1805 | 1806 |
| 1806 } // namespace cc | 1807 } // namespace cc |
| OLD | NEW |