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

Side by Side Diff: Source/WebCore/platform/graphics/chromium/cc/CCTiledLayerImpl.cpp

Issue 10146014: Merge 113677 - [chromium] Viewport is not filled when out of texture memory on mac (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1084/
Patch Set: Created 8 years, 8 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 return transform; 134 return transform;
135 } 135 }
136 136
137 void CCTiledLayerImpl::appendQuads(CCQuadCuller& quadList, const CCSharedQuadSta te* sharedQuadState, bool& usedCheckerboard) 137 void CCTiledLayerImpl::appendQuads(CCQuadCuller& quadList, const CCSharedQuadSta te* sharedQuadState, bool& usedCheckerboard)
138 { 138 {
139 const IntRect& layerRect = visibleLayerRect(); 139 const IntRect& layerRect = visibleLayerRect();
140 140
141 if (m_skipsDraw) 141 if (m_skipsDraw)
142 return; 142 return;
143 143
144 appendGutterQuads(quadList, sharedQuadState);
145
146 if (!m_tiler || !m_tiler->numTiles() || layerRect.isEmpty()) 144 if (!m_tiler || !m_tiler->numTiles() || layerRect.isEmpty())
147 return; 145 return;
148 146
149 int left, top, right, bottom; 147 int left, top, right, bottom;
150 m_tiler->layerRectToTileIndices(layerRect, left, top, right, bottom); 148 m_tiler->layerRectToTileIndices(layerRect, left, top, right, bottom);
151 149
152 if (hasDebugBorders()) { 150 if (hasDebugBorders()) {
153 for (int j = top; j <= bottom; ++j) { 151 for (int j = top; j <= bottom; ++j) {
154 for (int i = left; i <= right; ++i) { 152 for (int i = left; i <= right; ++i) {
155 DrawableTile* tile = tileAt(i, j); 153 DrawableTile* tile = tileAt(i, j);
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 if (!tile) 218 if (!tile)
221 tile = createTile(i, j); 219 tile = createTile(i, j);
222 tile->setTextureId(textureId); 220 tile->setTextureId(textureId);
223 tile->setOpaqueRect(opaqueRect); 221 tile->setOpaqueRect(opaqueRect);
224 } 222 }
225 223
226 Region CCTiledLayerImpl::visibleContentOpaqueRegion() const 224 Region CCTiledLayerImpl::visibleContentOpaqueRegion() const
227 { 225 {
228 if (m_skipsDraw) 226 if (m_skipsDraw)
229 return Region(); 227 return Region();
230 228 if (opaque())
229 return visibleLayerRect();
231 return m_tiler->opaqueRegionInLayerRect(visibleLayerRect()); 230 return m_tiler->opaqueRegionInLayerRect(visibleLayerRect());
232 } 231 }
233 232
234 } // namespace WebCore 233 } // namespace WebCore
235 234
236 #endif // USE(ACCELERATED_COMPOSITING) 235 #endif // USE(ACCELERATED_COMPOSITING)
OLDNEW
« no previous file with comments | « Source/WebCore/platform/graphics/chromium/cc/CCRenderPass.cpp ('k') | Source/WebKit/chromium/ChangeLog » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698