Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(35)

Side by Side Diff: cc/layer_tree_host_impl.cc

Issue 10984053: cc: Use ui/gfx geometry types for the CCRenderPass and CCDrawQuad classes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « cc/io_surface_draw_quad.cc ('k') | cc/layer_tree_host_impl_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "config.h" 5 #include "config.h"
6 6
7 #include "CCLayerTreeHostImpl.h" 7 #include "CCLayerTreeHostImpl.h"
8 8
9 #include "CCAppendQuadsData.h" 9 #include "CCAppendQuadsData.h"
10 #include "CCDamageTracker.h" 10 #include "CCDamageTracker.h"
(...skipping 533 matching lines...) Expand 10 before | Expand all | Expand 10 after
544 if (currentQuad->material() != CCDrawQuad::RenderPass) 544 if (currentQuad->material() != CCDrawQuad::RenderPass)
545 continue; 545 continue;
546 546
547 CCRenderPass::Id nextRemoveRenderPassId = CCRenderPassDrawQuad::material Cast(currentQuad)->renderPassId(); 547 CCRenderPass::Id nextRemoveRenderPassId = CCRenderPassDrawQuad::material Cast(currentQuad)->renderPassId();
548 removeRenderPassesRecursive(nextRemoveRenderPassId, frame); 548 removeRenderPassesRecursive(nextRemoveRenderPassId, frame);
549 } 549 }
550 } 550 }
551 551
552 bool CCLayerTreeHostImpl::CullRenderPassesWithCachedTextures::shouldRemoveRender Pass(const CCRenderPassDrawQuad& quad, const FrameData&) const 552 bool CCLayerTreeHostImpl::CullRenderPassesWithCachedTextures::shouldRemoveRender Pass(const CCRenderPassDrawQuad& quad, const FrameData&) const
553 { 553 {
554 return quad.contentsChangedSinceLastFrame().isEmpty() && m_renderer.haveCach edResourcesForRenderPassId(quad.renderPassId()); 554 return quad.contentsChangedSinceLastFrame().IsEmpty() && m_renderer.haveCach edResourcesForRenderPassId(quad.renderPassId());
555 } 555 }
556 556
557 bool CCLayerTreeHostImpl::CullRenderPassesWithNoQuads::shouldRemoveRenderPass(co nst CCRenderPassDrawQuad& quad, const FrameData& frame) const 557 bool CCLayerTreeHostImpl::CullRenderPassesWithNoQuads::shouldRemoveRenderPass(co nst CCRenderPassDrawQuad& quad, const FrameData& frame) const
558 { 558 {
559 const CCRenderPass* renderPass = findRenderPassById(quad.renderPassId(), fra me); 559 const CCRenderPass* renderPass = findRenderPassById(quad.renderPassId(), fra me);
560 const CCRenderPassList& renderPasses = frame.renderPasses; 560 const CCRenderPassList& renderPasses = frame.renderPasses;
561 CCRenderPassList::const_iterator foundPass = std::find(renderPasses.begin(), renderPasses.end(), renderPass); 561 CCRenderPassList::const_iterator foundPass = std::find(renderPasses.begin(), renderPasses.end(), renderPass);
562 562
563 bool renderPassAlreadyRemoved = foundPass == renderPasses.end(); 563 bool renderPassAlreadyRemoved = foundPass == renderPasses.end();
564 if (renderPassAlreadyRemoved) 564 if (renderPassAlreadyRemoved)
(...skipping 910 matching lines...) Expand 10 before | Expand all | Expand 10 after
1475 1475
1476 CCScrollbarAnimationController* scrollbarController = layer->scrollbarAnimat ionController(); 1476 CCScrollbarAnimationController* scrollbarController = layer->scrollbarAnimat ionController();
1477 if (scrollbarController && scrollbarController->animate(monotonicTime)) 1477 if (scrollbarController && scrollbarController->animate(monotonicTime))
1478 m_client->setNeedsRedrawOnImplThread(); 1478 m_client->setNeedsRedrawOnImplThread();
1479 1479
1480 for (size_t i = 0; i < layer->children().size(); ++i) 1480 for (size_t i = 0; i < layer->children().size(); ++i)
1481 animateScrollbarsRecursive(layer->children()[i], monotonicTime); 1481 animateScrollbarsRecursive(layer->children()[i], monotonicTime);
1482 } 1482 }
1483 1483
1484 } // namespace cc 1484 } // namespace cc
OLDNEW
« no previous file with comments | « cc/io_surface_draw_quad.cc ('k') | cc/layer_tree_host_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698