summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/platform/graphics/android/TiledTexture.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Rename several classesChris Craik2012-04-041-491/+0
| | | | | | | | | | | | | | | | | | | | BaseTile,BaseTileTexture -> Tile,TileTexture Used in layers other than the base LayerGroup -> Surface Renamed to convey that it is a member of the SurfaceCollection, and that the layers grouped inside are painted together (if at all) DualTiledTexture -> SurfaceBacking Better conveys that this is the raster backing for a surface that can paint. It may be implemented with two tiled textures for now, but that isn't as important as its relationship to the surface. TiledTexture -> TileGrid Renamed to make it more clear that it was a container of tiles, and to be less similar to TileTexture Change-Id: I843f8603a2080cfe5a7313ba1c2eff10620f8aa2
* Use new draw-less functor execution mode to do work without redrawingTeng-Hui Zhu2012-04-021-14/+6
| | | | | | Depends on frameworks/base change https://android-git.corp.google.com/g/#/c/177934/ Change-Id: I9154017ef2990b3bebd038cabcaf3d93c9df14d8
* Translucent background color support for webviewTeng-Hui Zhu2012-04-021-9/+57
| | | | | | | | | | | | | | | | | | We need to respect the background color set for webview and combine that with the CSS background. Since we are tiled based and need to avoid double drawing, we need to determine the areas not covered by available tiles and draw the background. This involves a bit computation overhead. Therefore, we only compute those areas when alpha is between 1 to 254. When alpha is 255, we just need a glClear. When alpha is 0, nothing need to be drawn. Due to the fact that the tile can be partially drawn, texture generator need to know the background color to clear the tiles for the base layer. bug:5684832 Change-Id: I51f9d219f2722cc088eeea603623f9660f7a136a
* Add back low res base layer rendering, and expanded bounds prefetchingChris Craik2012-03-301-58/+87
| | | | Change-Id: Ib6a38d8dd8223bdca9cb652771f0b19dbec892dc
* reimplement BaseLayerAndroid as a LayerAndroid subclassChris Craik2012-03-221-11/+26
| | | | | | Breaks low res tiling, and expanded rendering bounds. Change-Id: Iec3ba2adceb6bd95399594d29fd8c0b18c1122ce
* Paint tiles with the PaintTileOperation's painterChris Craik2012-03-161-1/+1
| | | | | | | The refcounting there prevents the painter from being deallocated while painting bug:6064973 Change-Id: Ief4e615876aab74afb74e135acc1dd92c92af570
* Fix layers ordering issue with Absolute positioned elementsNicolas Roard2012-03-131-2/+2
| | | | | | | | | - Promote absolute positioned elements to be composited - Reorder the elements as needed in LayerAndroid - Simplify fixed elements composition culling (don't do it anymore, we just promote everything and let the Layers sort things out) Change-Id: If76cf76a92410dec7e305a1a70c660d8597e399a
* replace XLOGC/XLOG with ALOGD/ALOGVChris Craik2012-03-121-57/+30
| | | | | | | Started using ALOGW/E for indicating warnings/errors Also delete the unused TilesTracker.h Change-Id: I1986a3057efd4c8e260dbc020e21c02d4d646cf3
* Replace picture count with the SurfaceCollection countChris Craik2012-03-091-1/+1
| | | | | | Displays surface collection count on tiles when visual indicator is on. Change-Id: Ibe90792279849baff6f5bf0d71b80d9081471dc4
* Pass transform matrix in draw instead of through painterChris Craik2012-03-021-4/+6
| | | | | | | | | | bug:6105013 Since BaseTile's painter pointer may be stale, pass transform through draw rename transparency->opacity where needed added const for drawing path rects Change-Id: Ie08cef63c656e95887a3230af18b5b6a4513c10d
* layer rendering cleanup/rewriteChris Craik2012-02-281-89/+89
| | | | | | | | | | | | | | | | | | | | | * added 'LayerGroup' class separate the painting/tiled features of a layer (eventually multiple layers) tiled drawing/preparing/counting details are abstracted out of LayerAndroid * added 'SurfaceCollection' class incorporates both the BaseLayerAndroid/LayerAndroid tree, as well as the vector of tiled LayerGroup * renamed 'TreeManager' to 'SurfaceManager' * Removes PaintedSurface was mostly a thin wrapper around DualTiledTexture * Combines TilePainter/SurfacePainter * Simplified ref counting Change-Id: I92c5c75f48d92e0e28812c56de00102399fc02ee
* Revert "simplify texture generation filters"Chris Craik2012-02-231-2/+3
| | | | | | | Seems to be a problem with the refcounting. bug:6050242 bug:6058365 This reverts commit 92a7e4bc6b67b150cbb30f78374173ecfeb43607
* simplify texture generation filtersChris Craik2012-02-161-3/+2
| | | | | | | | | | Filters can no longer block, which removes the need for transfer queue interruption. The filter no longer touches the currently painting tile. Tiles are now all ref-counted to accomodate the container being deleted while one of its tiles is still painting. Change-Id: Iaa4848665efdf90846defb0a53bf1ea013b8421b
* Fix for high latency when creating a new layerNicolas Roard2012-02-141-0/+5
| | | | | bug:6016661 Change-Id: I09b729203b77f8138f8b32182d70e1fc6c5ea9f7
* Don't draw clipped texturesChris Craik2011-12-131-17/+18
| | | | | | | | | bug:5748350 Use separate areas for preperation vs drawing, so that we don't waste draw calls in kAllTextures mode Change-Id: Ie4f100a48ed0013769ef73d446a92cb883ca9f13
* Account for dirty tiles doubly in texture countingChris Craik2011-12-061-2/+13
| | | | | | | | | | | | bug:5704511 Dirty tiles use two textures - one for display, and one for painting. This fixes an issue where the number of textures requested did not meet the needs of a double buffered tree with most content invalidated. The webview would give up drawing, and thus not paint the invalidated portions of the layers. Change-Id: Icd9b9e0b53cf82415074dac4338a8c48de880364
* Fix image layer codepathNicolas Roard2011-11-301-4/+10
| | | | | | | | | | | | | | - asynchronous loading - support for tiled content using TiledTexture - fix repaint/duplication bugs - share same textures as layers - disambiguate between images by computing a CRC code - added better debugging in TilesManager/ClassTracker to track memory usage bug:5661120 bug:5572134 bug:5521718 Change-Id: Id422fb991d6233bbe4dc6e5c3c7409468b7dca98
* Swap tiled page tiles on zoomChris Craik2011-11-301-0/+1
| | | | | bug:5678199 Change-Id: I8cc811753f1c9325d3adefbd30e7501ee8719b6b
* synchronous layer updates, and animation deferral during paintChris Craik2011-11-161-44/+69
| | | | | | | | bug:5522081 bug:5239801 bug:5297563 Change-Id: I600f66999e093f720a8ea97ef3e15d3d1d297a8f
* Fallback mode when running out of textures for layersNicolas Roard2011-11-101-22/+38
| | | | | | | | | | - Implements a degraded rendering mode when running out of textures - Speed up rendering by reusing the same SkBitmap in RasterRenderer - Some refactoring bug:5279231 Change-Id: I52943a87bed56c49b01b47fea4fa1a5c49e09e93
* Merge "DO NOT MERGE Fix SW extras for layers" into ics-mr1John Reck2011-10-251-5/+0
|\
| * DO NOT MERGE Fix SW extras for layersJohn Reck2011-10-251-5/+0
| | | | | | | | | | | | | | Bug: 5507239 Also remove all the old, unused layer setExtras stuff Change-Id: Id1670010536712b7a9f50e74821c9fb7f708e851
* | Mark layers as ready to swap if invisibleChris Craik2011-10-251-1/+1
|/ | | | | | | | | bug:5505364 This avoids the problem of waiting infinitely during initialization (when a layer doesn't have content) for the layer to be ready. Change-Id: I364eff66616ea304a68976d5ad06ce5fdb1a6d4b
* Implement dual textures for layers to handle zooming correctly.Nicolas Roard2011-10-201-25/+120
| | | | | | | | | We add a new class, DualTiledTexture, that encapsulate two TiledTextures and manage them according to the current scale factor. bug:5492874 Change-Id: I4ba3ff539f9242ae5102189e9623e1535e9cc28f
* Fixed infinite redraw loop from running out of layer tilesChris Craik2011-10-111-1/+1
| | | | | | | | | | | bug:5349958 Clear a flag when a layer tile can't allocate a texture, and only try and redraw from tile dirtiness if that flag is set. Also, don't ask for redraw if offending tiles are offscreen. Change-Id: Iadb0cb267a9c1f308e5b42a6e0e3b4bc71d18ece
* Double buffering for layersChris Craik2011-10-101-41/+68
| | | | | | | | | | | | | bug:5309934 Defer picture changes and invalidations when: 1) a tiled texture hasn't completed painting 2) the user is scrolling (done in PaintedSurface) Remaining issues: Should block updates on zooming Change-Id: I60ee722e651f96e95a4ac0e819999fc1589037c3
* Enable double buffering via base tilesChris Craik2011-09-021-12/+12
| | | | | | | | | | | | bug:2522049 allocate textures and tiles using the gldraw count when they were most recently prepared remaining issues: -layers still flicker (presumably from texture stealing) -layers aren't double buffered yet Change-Id: Iccdf68326d7d476269d4e3a13903aaab249ee92d
* Implement partial repaint for layers (at the tile level)Nicolas Roard2011-08-171-6/+10
| | | | | | | | Fixes a scheduling problem with layers bug:3392331 bug:5145259 Change-Id: I2ea2c91f2c6d6f5288375cb5ebdaa69819b740be
* Fix missing tilesNicolas Roard2011-08-101-12/+12
| | | | | | bug:5123881 Change-Id: Ia3f5e76bc38f32c756cb4e108fe153dd8e103bf3
* Fix ANR in webkitNicolas Roard2011-08-081-2/+1
| | | | | bug:5128336 Change-Id: I591882eb9bd96a04fd34299a8bf76d35a9462d94
* Fixes layers painting crashesNicolas Roard2011-08-041-2/+18
| | | | | | bug:5097230 bug:5045149 Change-Id: I20fcae13e7f617658447c02bd51dc83d2914922e
* Shared surface textureTeng-Hui Zhu2011-08-021-4/+4
| | | | | | | | | | | Instead of assigning each tile a Surface Texture, now just a normal GL texture. The content from skia bitmap will first drawn into a queue of Surface Textures, at draw time, blit them into each tile's GL texture. Added extra lock to protect the queue operation and Surface Texture operation. bug:5044597 Change-Id: I25f46228b93a3e99526daf52d8bd0d8d8fcc2879
* Implements tiled layers. We remove all the existing code in LayerAndroidNicolas Roard2011-07-141-0/+231
related to the old texture management and introduce two new classes: - PaintedSurface, used as a placeholder ui-side for the regularly changing LayerAndroid - TiledTexture, implementing the tiling of PaintedSurface using a set of BaseTile bug:4580444 bug:3392331 Change-Id: I0daa079d2acce49f3baa8c312ea0b0dd457ccd5c