diff options
| author | 2013-10-25 18:30:17 -0700 | |
|---|---|---|
| committer | 2013-12-12 10:18:23 -0800 | |
| commit | f57776b2d195f0937906eb88b777bb55ccc36967 (patch) | |
| tree | f2c160bb0860a6f3d0f883cdf0c520892a1bde24 /libs/hwui/Layer.cpp | |
| parent | c3c4d36df01631883a79163da841ca222497c9d3 (diff) | |
3d view system!
True 3d transformations are now supported by DisplayLists and the
renderer, initially with the translationZ property on view.
Renderer operations used directly by DisplayList (formerly,
clip/save/restore/saveLayer) are now more simply managed by allocating
them temporarily on the handler's allocator, which exists for a single
frame. This is much simpler than continuing to expand the pool of
pre-allocated DisplayListOps now that more operations are called
directly by DisplayList, especially with z ordered drawing.
Still TODO:
-APIs for camera positioning, shadows
-Make Z apis public, and expose through XML
-Make invalidation / input 3d aware
Change-Id: I95fe6fa03f9b6ddd34a7e0c6ec8dd9fe47c6c6eb
Diffstat (limited to 'libs/hwui/Layer.cpp')
| -rw-r--r-- | libs/hwui/Layer.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/libs/hwui/Layer.cpp b/libs/hwui/Layer.cpp index bd371a3bcef4..742ffd47fd8d 100644 --- a/libs/hwui/Layer.cpp +++ b/libs/hwui/Layer.cpp @@ -194,11 +194,9 @@ void Layer::defer() { dirtyRect.set(0, 0, width, height); } - if (deferredList) { - deferredList->reset(dirtyRect); - } else { - deferredList = new DeferredDisplayList(dirtyRect); - } + delete deferredList; + deferredList = new DeferredDisplayList(dirtyRect); + DeferStateStruct deferredState(*deferredList, *renderer, DisplayList::kReplayFlag_ClipChildren); @@ -206,6 +204,7 @@ void Layer::defer() { renderer->setupFrameState(dirtyRect.left, dirtyRect.top, dirtyRect.right, dirtyRect.bottom, !isBlend()); + displayList->computeOrdering(); displayList->defer(deferredState, 0); deferredUpdateScheduled = false; |