History log of /frameworks/base/libs/hwui/Layer.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
417ed6d4337e5409d52f58cc93677c8715193f32 23-Mar-2016 John Reck <jreck@google.com> Fix missing first frame

Bug: 26776366
Change-Id: I46258c0ff35fdefe5c9f2ee610c904b2dbe8c5d9
/frameworks/base/libs/hwui/Layer.h
38e0c32852e3b9d8ca4a9d3791577f52536419cb 10-Nov-2015 John Reck <jreck@google.com> Track texture memory globally

Also mostly consolidates texture creation

Change-Id: Ifea01303afda531dcec99b8fe2a0f64cf2f24420
/frameworks/base/libs/hwui/Layer.h
b9ce116dac378b4cf4490f265dcbd5704a1dd43c 21-Aug-2015 Chris Craik <ccraik@google.com> Switch several enums to enum classes

Change-Id: I00ecd0b61657196b51704f70ca31a9d1c1ac254e
/frameworks/base/libs/hwui/Layer.h
e5c6584a402fb3b1fe0507e4e00e601bec8f1bbc 03-Mar-2015 Chris Craik <ccraik@google.com> Constructor cleanup

Change-Id: Ic39911d08f44c3174de91fb92fcd4cab73fe4654
/frameworks/base/libs/hwui/Layer.h
f27133df2d179c99d6bc1ae644af09e9153a0071 19-Feb-2015 Chris Craik <ccraik@google.com> Glop layer mesh rendering

Change-Id: I2d902819d5d77f496b67d4d25a298782903e410d
/frameworks/base/libs/hwui/Layer.h
49bc4acfadf9c5b1e520217278ccb38010d38c89 29-Jan-2015 John Reck <jreck@google.com> resolved conflicts for merge of fe5ac4fc to master

Change-Id: I6c0cc82db14b56297586469f940e408c0e218b3b
fe5ac4fc31ee671721f98cf28cf1bd32ac119998 29-Jan-2015 John Reck <jreck@google.com> am 5f3e21ce: am 6efc3ac6: Merge "Allow ~Layer() to happen after onGLContextDestroyed" into lmp-mr1-dev

* commit '5f3e21cebeecf042e8e18a5021b3965415d9ff60':
Allow ~Layer() to happen after onGLContextDestroyed
57998017ff137f7d4ec33df21b6596141f8c4547 29-Jan-2015 John Reck <jreck@google.com> Allow ~Layer() to happen after onGLContextDestroyed

Bug: 19146354
Change-Id: I9e885936168bd541bfbed4064ad67ab524f58e32
/frameworks/base/libs/hwui/Layer.h
51d6a3db97bdd5315f1a17a4b447d10a92217b98 23-Dec-2014 Chris Craik <ccraik@google.com> Cleanup various clang warnings, use unique_ptrs in several places

Change-Id: I347904b25e51fcc7de14b1e72f1acd0f6ba26f3f
/frameworks/base/libs/hwui/Layer.h
bfed827028eae460a40464be7dbe146f4d748e26 02-Nov-2014 Nick Kralevich <nnk@google.com> partially fix build.

Addresses the following compile time errors:

In file included from frameworks/base/libs/hwui/LayerRenderer.cpp:24:0:
frameworks/base/libs/hwui/RenderState.h:77:24: error: 'VirtualLightRefBase' has not been declared
void postDecStrong(VirtualLightRefBase* object);
^
In file included from frameworks/base/libs/hwui/LayerCache.h:21:0,
from frameworks/base/libs/hwui/LayerRenderer.cpp:25:
frameworks/base/libs/hwui/Layer.h:55:42: error: expected class-name before '{' token
class Layer : public VirtualLightRefBase {
^
In file included from frameworks/base/libs/hwui/RenderState.cpp:16:0:
frameworks/base/libs/hwui/RenderState.h:77:24: error: 'VirtualLightRefBase' has not been declared
void postDecStrong(VirtualLightRefBase* object);
^

Change-Id: I2be439b373ea356b861f413ff6ce323e8d9baf2d
/frameworks/base/libs/hwui/Layer.h
e05575e9c36850d8cfe49396ac9a1372511b12bf 01-Nov-2014 John Reck <jreck@google.com> am a8d83d63: Merge "Layer changes" into lmp-mr1-dev
automerge: a51fba0

* commit 'a51fba0bf037844bcb911e69e8af733e6d2cccf6':
Layer changes
0e89e2b7bcb2c035e8cee77f93120e7c5617f8d2 31-Oct-2014 John Reck <jreck@google.com> Layer changes

Bug: 17208461

* Switch Layer to be VirtualLightRefBase instead of
Caches' side-channel ref-counting
* Include active layers in gfxinfo dump
* Run gfxinfo dump on the correct thread
* Dump gfxinfo on Layer creation failure

Change-Id: I28d195699e2334518e215ab28c7a17355aee9678
/frameworks/base/libs/hwui/Layer.h
4ed472ab33e78391c0b084ed3908019e06b7dfe5 29-Oct-2014 Narayan Kamath <narayan@google.com> resolved conflicts for merge of 3028394c to stage-aosp-master

Change-Id: I980e4c95cdc6a4778cef3298338692656d23e7c6
d3448e437ac247e96455014e95f15a3ddd5cb328 15-Sep-2014 Chih-Hung Hsieh <chh@google.com> Suppress Clang compilation warnings.

Ignore warnings about unused parameters and initialization of static
constant float data members.

Change one potential error of allocating variable length
array of non-POD element type on stack.

Fix mismatch of class and struct declaration tags.

BUG: 17512760
Change-Id: I3a09c945fb1c17f27aff74a7e439dd4c35d1fb32
/frameworks/base/libs/hwui/Layer.h
bfd1cd620991ac2fa9202fdce6c00ec47d071935 10-Sep-2014 Chris Craik <ccraik@google.com> Additional layer logging

bug:17208461

Track layer's last known state.

Change-Id: Ic1799191f5839a1d6cc56f598f2ac2671dc27a6f
/frameworks/base/libs/hwui/Layer.h
8a226d24b8b2fde4c855d0051cb7bfc5b5813c36 09-Sep-2014 Chris Craik <ccraik@google.com> Don't track TextureLayer lifecycles in RenderState

bug:17208461

They are destroyed via finalizer-enqueued destroy method, so it's not
valid to check that they've been destroyed at gl context destruction
time.

Change-Id: I670f69825547facd5f31d44acb406418881fee00
/frameworks/base/libs/hwui/Layer.h
443a714fa7c0dd07fee3527cc5bc3d3ca1fb7d44 05-Sep-2014 John Reck <jreck@google.com> Yet more layer tracking logging

Bug: 17208461

Change-Id: I55e7d0921eb565867e966d68b798b7b92c391b55
/frameworks/base/libs/hwui/Layer.h
69e5adffb19135d51bde8e458f4907d7265f3e23 14-Aug-2014 Chris Craik <ccraik@google.com> Define shadow casting behavior within layers

bug:15860114

Savelayers and HW layers both now support shadow casting.

For save layers, the light source should always be correct, for HW
layers, the light source position is set when the layer is created,
and updated when it is resized.

Change-Id: Ie85567dd43c2bb0a0b08fd0bd4db41efa793ac2b
/frameworks/base/libs/hwui/Layer.h
3b20251a355c88193c439f928a84ae69483fb488 23-Jun-2014 John Reck <jreck@google.com> No-fail invokeFunctor

Bug: 15513308
Bug: 15449247

Change-Id: I13a29f9c8d4975cdda6dcb33b6332c2555ff0f7c
/frameworks/base/libs/hwui/Layer.h
a7090e0cfd7c719a6d4c03aae34f5db98754cbdd 21-Jun-2014 Chris Craik <ccraik@google.com> Update 'DisplayList' vs 'RenderNode' naming in several places

Change-Id: I635c6627d098b661fb9b0ba1bd42fa6d7277d287
/frameworks/base/libs/hwui/Layer.h
3f085429fd47ebd32ac2463b3eae2a5a6c17be25 16-Apr-2014 Chris Craik <ccraik@google.com> Clip TouchFeedbackDrawable effect to receiver Outline

Projected RenderNodes are now wrapped with a ClipRect or masked
SaveLayer, so that they are clipped to the outline of the projection
receiver surface.

Change-Id: I1d4afc1bb5d638d650bc0b1dac51a498f216773e
/frameworks/base/libs/hwui/Layer.h
087bc0c14bdccf7c258dce0cdef46a69a839b427 05-Apr-2014 John Reck <jreck@google.com> Refcount RenderNode

Change-Id: I7a86db8acc2b78ef33d987a43a119f5933d7d752
/frameworks/base/libs/hwui/Layer.h
668f0e38ef0277d55d3118af37e17b8c435df85c 26-Mar-2014 John Reck <jreck@google.com> Async drawing!

Change-Id: I7e728356f58af88174328a8c0b90d27b128bfe01
/frameworks/base/libs/hwui/Layer.h
e18264b079481a244b30e3f71012c53bbd861f92 12-Mar-2014 John Reck <jreck@google.com> Rename DisplayList->RenderNode

Change-Id: Id42e23c9a1a6eb6eaeafef707ced7fa6887b03d0
/frameworks/base/libs/hwui/Layer.h
9757ac0b9d62f6aea5e47cfb375f445c78bb7897 26-Feb-2014 Chris Craik <ccraik@google.com> Fix TextureView texture filtering.

bug:11748993

TextureView should always be drawn with linear filtering if drawing a
buffer sized differently from the layer.

This fixes a bug where TextureViews that were sized differently from
their contents wouldn't be drawn with texture filtering, causing
visible scaling artifacts.

Change-Id: I8a5d27452fe7269ec53896992f37cff51e3ce15a
/frameworks/base/libs/hwui/Layer.h
674554fc36932ca50b15bba41ac6f650254d4e72 19-Feb-2014 Derek Sollenberger <djsollen@google.com> Reapply "Refactor setting an SkPaint onto a hwui Layer."

This reverts commit 90d0c75e94a32fb7d993fae69762820aabc2fcbb.

Change-Id: Ie807761231edf7c848b019931dccbf466208c0be
/frameworks/base/libs/hwui/Layer.h
90d0c75e94a32fb7d993fae69762820aabc2fcbb 12-Feb-2014 Derek Sollenberger <djsollen@google.com> Revert "Refactor setting an SkPaint onto a hwui Layer."

This reverts commit e889298cd6ae1fc0d76bc00d7d12586db03eb261.

Change-Id: I4b1d609b2d4280595d40cb10d6c18875c22999f8
/frameworks/base/libs/hwui/Layer.h
e889298cd6ae1fc0d76bc00d7d12586db03eb261 11-Feb-2014 Derek Sollenberger <djsollen@google.com> Refactor setting an SkPaint onto a hwui Layer.

This CL removes the unecessary JNI call to set the colorFilter on
a layer.

Change-Id: I9e088f888938d4315745aa618334bfdb9e61343a
/frameworks/base/libs/hwui/Layer.h
76d3a1b8d035d27bc80b0f2fc480a903bd001514 10-Dec-2013 Derek Sollenberger <djsollen@google.com> Removing SkiaColorFilter and inspecting the native object directly.

bug: 10650594
Change-Id: I4fcf66d008765afa0e35d011f58bc792183cb74f
/frameworks/base/libs/hwui/Layer.h
564acf7c9bff822f608cda0d5df0a64a9f9aaefd 03-Jan-2014 Chris Craik <ccraik@google.com> Fix Clang warnings/errors

Fix several build warnings (struct != class, int != size_t) and errors
(variable leng non-POD arrays).

Change-Id: I70b4e784365514303d8954bfcb1f39d7c22c1321
/frameworks/base/libs/hwui/Layer.h
448455fe783b0a711340322dca272b8cc0ebe473 22-Jul-2013 Romain Guy <romainguy@google.com> Use global indices array to draw layers

An array of indices local to a layer would only be necessary if
we changed the way we resolve T-junctions. Since we only ever
draw quads, let's just use the indices we use everywhere else.

This change also uses the global indices array to render list
of colored rectangles to save on the number of vertices generated
CPU-side.

Change-Id: Ia6d1970b0e9247805af5a114ca2a84b5d0b7c282
/frameworks/base/libs/hwui/Layer.h
e93482f5eac3df581d57e64c2a771a96aa868585 17-Jun-2013 Romain Guy <romainguy@google.com> Cancel layer update when a layer is about to be destroyed
Bug #9310706

Change-Id: I73eea6314c326f15a979617e3a05b525935f0d3f
/frameworks/base/libs/hwui/Layer.h
8aa195d7081b889f3a7b1f426cbd8556377aae5e 05-Jun-2013 Romain Guy <romainguy@google.com> Introduce Caches::bindTexture() to reduce glBindTexture calls

Change-Id: Ic345422567c020c0a9035ff51dcf2ae2a1fc59f4
/frameworks/base/libs/hwui/Layer.h
34416eaa1c07b3d7a139e780cea8f8d73219650e 16-Apr-2013 Chris Craik <ccraik@google.com> Make layer double drawing visible in overdraw debug mode

A clipped saveLayer will cause two draws - first to an onscreen
buffer, then again back to the framebuffer. This change - when in
overdraw debug - reissues draws associated with a clipped saveLayer,
but only to the stencil buffer. Operations within a saveLayer are
shown correctly to be twice drawn, and View.setAlpha() without an
associated hardware layer, or hasOverlappingRendering() are made more
visible.

Hardware layers, on any frame that they are updated, similarly draw
twice, and will also be counted against the stencil buffer doubly.

Note: greater depths of layers - e.g. a saveLayer within a saveLayer -
are not respected, as that would require additional region tracking.

Change-Id: I61fb0e61038fe66013d59914c20bb47a550dea7d
/frameworks/base/libs/hwui/Layer.h
0908764b2b3cf5075df4178a5f0a8547dcb7b317 04-Apr-2013 Romain Guy <romainguy@google.com> First OpenGL ES 3.0 based optimization

This change uses a new OpenGL ES 3.0 feature to upload less data when
the font cache needs to be update. This can result in significant
performance improvements on device with large textures or with locales
that use a lot of glyphs (CJK for instance.)

This change also fixes various unpack alignment issues. The unpack
alignment, as well as the unpack row length, is not texture specific
but a global state that affect all glTex/SubImage2D calls. Some of
them were missing the appropriate glPixelStorei() call. This could
result in corrupted textures.

Change-Id: Iefb429d4d0d0b4e0faeadf27daafee6d30a21d85
/frameworks/base/libs/hwui/Layer.h
02b49b70ede0b9eb760ff334823aee1d9520ed85 29-Mar-2013 Romain Guy <romainguy@google.com> Prevent crash when a single layer is enqueued several times for updates
Bug #8504687

Change-Id: I9b01bbc4e3f37af23dfe5e68d3d03ad3d238b94a
/frameworks/base/libs/hwui/Layer.h
96885eb480c5e0526fe2f77d30f6e551f3f3ceab 26-Mar-2013 Romain Guy <romainguy@google.com> Avoid multiple font cache texture uploads
Bug #8378964

This change defers drawing into layers until after the renderer for FBO0
is ready to draw. At that point, all the precaching is done which means
all glyphs can be uploaded at once in the font caches.

Change-Id: Ie1f7a7ff30f76f06fb3dbc72c7d05e66207d1ecb
/frameworks/base/libs/hwui/Layer.h
da8d8b9699fe8e9557389465007e333d3f03dcc1 07-Feb-2013 Romain Guy <romainguy@google.com> Merge "Add a RenderBuffer object to store stencil buffers. Bug #7146141"
3bbacf27c0be1bae4e4483577fc89ae3113abe5d 07-Feb-2013 Romain Guy <romainguy@google.com> Add a RenderBuffer object to store stencil buffers.
Bug #7146141

This change is needed to add a render buffer cache to avoid
creating and destroying stencil buffers on every frame.

This change also allows the renderer to use a 1 bit or 4 bit
stencil buffer whenever possible.

Finally this change fixes a bug introduced by a previous CL
which causes the stencil buffer to not be updated in certain
conditions. The fix relies on a new optional parameter in
drawColorRects() that can be used to avoid performing a
quickReject on rectangles generated by the clip region.

Change-Id: I2f55a8e807009887b276a83cde9f53fd5c01199f
/frameworks/base/libs/hwui/Layer.h
781fd2b7c86a20b0f00b5e009237d69b557e3cc4 30-Jan-2013 Romain Guy <romainguy@google.com> am f5f85022: Merge "Fix graphical corruption on QCOM GPU Bug #7146141"

# Via Android (Google) Code Review (1) and Romain Guy (1)
* commit 'f5f8502271b04d63c518e3aecfd5eaf557904e72':
Fix graphical corruption on QCOM GPU Bug #7146141
c3fedafc5f50100219449125a000e3138f6fb987 30-Jan-2013 Romain Guy <romainguy@google.com> Fix graphical corruption on QCOM GPU
Bug #7146141

The GL_QCOM_tiled_rendering extension requires careful use of
start/endTiling when attaching a renderbuffer dynamically.

Change-Id: I20036683ed3909ffaf40cc3d57a25257e35b6fa2
/frameworks/base/libs/hwui/Layer.h
7d4f807b830eceb557e849629e95bd4bdc06ccfd 19-Jan-2013 Romain Guy <romainguy@google.com> am 49464796: Merge "Allow layers with a stencil buffer to be resized on the fly Bug #7146141"

* commit '494647961feb21d925d5e6e5ce1d42aa8b6949db':
Allow layers with a stencil buffer to be resized on the fly Bug #7146141
2055abaa0a590c35e27e1ae2e7d7cfccdfb98b59 19-Jan-2013 Romain Guy <romainguy@google.com> Allow layers with a stencil buffer to be resized on the fly
Bug #7146141

This change moves the resizeLayer() from LayerCache (where it should
never have been anyway) to Layer. This makes a little more sense.

Change-Id: I8b2f9c19c558e738405a58b9e71ec5799fc6be88
/frameworks/base/libs/hwui/Layer.h
e9a983b44407413f18aeb16c892e97ea938a7fab 18-Jan-2013 Romain Guy <romainguy@google.com> am b12db26f: Merge "Implement clipRect with a transform, clipRegion & clipPath Bug #7146141"

* commit 'b12db26fec178794915d819c3dd64f13d788c461':
Implement clipRect with a transform, clipRegion & clipPath Bug #7146141
8ce00301a023eecaeb8891ce906f67b513ebb42a 16-Jan-2013 Romain Guy <romainguy@google.com> Implement clipRect with a transform, clipRegion & clipPath
Bug #7146141

When non-rectangular clipping occurs in a layer the render buffer
used as the stencil buffer is not cached. If this happens on a
View's hardware layer the render buffer will live for as long
as the layer is bound to the view. When a stencil buffer is
required because of a call to Canvas.saveLayer() it will be allocated
on every frame. A future change will address this problem.

If "show GPU overdraw" is enabled, non-rectangular clips are not
supported anymore and we fall back to rectangular clips instead.
This is a limitation imposed by OpenGL ES that cannot be worked
around at this time.

This change also improves the Matrix4 implementation to easily
detect when a rect remains a rect after transform.

Change-Id: I0e69fb901792d38bc0c4ca1bf9fdb02d7db415b9
/frameworks/base/libs/hwui/Layer.h
ca79cf69d09efa0c327e9b1237d86a119aea5da7 14-Aug-2012 Derek Sollenberger <djsollen@google.com> Update framework to support r5967 of Skia.

bug: 6906025
Change-Id: Iefdb830ec3aa2ab3472c1c142484a7aa21788a15
/frameworks/base/libs/hwui/Layer.h
5bb3c730f5ebd2a0db1b02a8981c6fdbea6c1a2e 30-Nov-2012 Romain Guy <romainguy@google.com> Apply dev. settings at runtime
Bug #7434649

Change-Id: I16f00eaa8a5eefd9f9849e196cf2cb1659215390
/frameworks/base/libs/hwui/Layer.h
7c25aab491707f7324f9941b8cfa9bd2b4b97e76 19-Oct-2012 Romain Guy <romainguy@google.com> Defer layer rendering to avoid stalls
Bug #7326824

When a layer is taken out of the cache and initialized it gets cleared
to prepare it for future rendering. This triggers the following sequence
of operations:

glBindFramebuffer(layer.fbo)
attach texture storage to FBO
glClear()
glBindFramebuffer(defaultFbo)

The clear forces a resolve on tilers which stalls the CPU for a little
while, thus producing jank during animations. This change moves the
clear to the next frame when we know we will have to execute a resolve
anyway.

Change-Id: Ic1939c25df20ed65a4c48dc81ee549b2cd8b6ec3
/frameworks/base/libs/hwui/Layer.h
b2e2f2470693e78baed20617f989d9a166864ed4 18-Oct-2012 Romain Guy <romainguy@google.com> Take into account the texture layer's transform for clipping
Bug #7370212

Change-Id: Ibdc3161306f54a1cfe66e08458f05ee01a13b1df
/frameworks/base/libs/hwui/Layer.h
98d3a64ffa13596e3ea9125bbff40c51ec96bd8d 26-Sep-2012 Chet Haase <chet@google.com> Assign default texture id of 0

Some logic depends on a default value of 0, which was not being
assigned.

Issue #7195815 chrome url bar is corrupted
Issue #7190656 Textures corrupted on mr1

Change-Id: I346b7b76e885bf8f04740e711fd88f917a5418c7
/frameworks/base/libs/hwui/Layer.h
56257aff8a55c847be72be9924c392033fd8151d 26-Sep-2012 Dave Burke <daveburke@google.com> Revert "Deleting objects on the wrong thread is a silly idea Bug #7195815"

This reverts commit 8a1374946a928fcba7495c87ff6adda327fdfb9f

Change-Id: I53564a6c531d334afcc1fce0bea1e57ae266aa78
/frameworks/base/libs/hwui/Layer.h
8a1374946a928fcba7495c87ff6adda327fdfb9f 26-Sep-2012 Romain Guy <romainguy@google.com> Deleting objects on the wrong thread is a silly idea
Bug #7195815

Turns out that multi-threading is hard.

Change-Id: Ib0b4bd6dc3caea27f7ced22cbb363bb955fe58ab
/frameworks/base/libs/hwui/Layer.h
ef09a210dd6ea481158b7028ec2424a7f5769ed2 25-Sep-2012 Romain Guy <romainguy@google.com> Don't destroy the same texture twice
Bug #7221449

SurfaceTexture already deletes the GL texture when detachFromContext
is invoked. The newly introduced refcount would casue the Layer
object to be destroyed later and attempt to delete the GL texture
again. By the time the second cleanup occurs, the texture name
might have been reused by somebody else, resulting in erroneous
behaviors.

Change-Id: I257c589fea64b34c00f46fbfaa7732e6854a5e41
/frameworks/base/libs/hwui/Layer.h
97dc9172b0e58979c63de0dedbab656399a62281 24-Sep-2012 Romain Guy <romainguy@google.com> Avoid deadlock when deleting layers
Bug #7217459

Change-Id: I12bfa6c30c5030bd1b23ea6a3ce64240ab1dfba3
/frameworks/base/libs/hwui/Layer.h
603f6de35f21d74ae242d52d501f4f5c25ff4f4c 15-Sep-2012 Chet Haase <chet@google.com> Fix occasional crash bug with layers

Launcher occasionally crashes with a stack trace indicating that the memory
of a Layer object is corrupt. It is possible for us to delete a Layer
structure and then, briefly, use it to draw a DisplayList again before
that DisplayList gets recreated (without the layer that got deleted).

When this happens, if the memory got corrupted, it's possible to crash.

The fix is to add Layer to the other objects which we currently refcount
(bitmaps, shaders, etc.). Then instead of deleting a Layer, we decrement the
refcount. We increment when creating it, then increment it again when it's
referenced from a DisplayList. Then we decrement the refcount instead of
deleting it, and decrement when we clear a DisplayList that refers to it.
Then when the refcount reaches 0, we delete it.

Issue #6994632 Native crash in launcher when trying to launch all apps screen

Change-Id: I0627be8d49bb2f9ba8d158a84b764bb4e7df934c
/frameworks/base/libs/hwui/Layer.h
d15ebf25c595b855f6978d0600218e3ea5f31e92 05-Sep-2012 Chet Haase <chet@google.com> Enable changing properties of layer paint

Previously, to draw a layered view with a changed Paint object for the
drawLayer operation, you'd have to invalidate the parent view, to get the
native DisplayList to pick up the new Paint properties. This change adds
API and functionality so that the developer can call setLayerPaint(), which
does the proper invalidation (lightweight, doesn't cause redrawing the view).

Issue #6923810 Make it easy to efficiently animate a layer's Paint

Change-Id: I7fea79788d50f6d9c86dd5e5b2a4490cb95142bb
/frameworks/base/libs/hwui/Layer.h
2bf68f063b0077ddef6ebfe54f2ae5e063c2c229 02-Mar-2012 Romain Guy <romainguy@google.com> Deferred layer updates

Change-Id: I83d9e564fe274db658dcee9e0cc5bbf9223ebb49
/frameworks/base/libs/hwui/Layer.h
d21b6e1fe337b35f62cf2028e9bd0637fd009a75 01-Dec-2011 Romain Guy <romainguy@google.com> Optimize away unnecessary state changes

Change-Id: I0f6816f9f6234853575ecee5033186ad19e76380
/frameworks/base/libs/hwui/Layer.h
302a9df1d50373c82923bb84ff665dfce584fb22 16-Aug-2011 Romain Guy <romainguy@google.com> Add an API to set the transform on a TextureView's surface texture.
Bug #5156689

Change-Id: I635a625885c9b832a60d44ece0de7613ceb84109
/frameworks/base/libs/hwui/Layer.h
912a7b32d0c59ba38265c5dd6ff84ce93f909a7f 27-Jul-2011 Romain Guy <romainguy@google.com> Make sure we have a current EGL context when invoking EGL
Bug #5081795

Change-Id: Iee3382d362a71c1e6c5c498b319bf7f7bcf5a2f0
/frameworks/base/libs/hwui/Layer.h
e3c26851dc315b730ea0fe5ef35bb1db81f6d675 26-Jul-2011 Romain Guy <romainguy@google.com> Improve rendering performance on some GPUs

This change sets textures filtering to GL_NEAREST by default. GL_LINEAR
filtering is only used when textures are transformed with a scale or
a rotation. This helps save a couple of fps on some GPUs.

Change-Id: I1efaa452c2c79905f00238e54d886a37203a2ac1
/frameworks/base/libs/hwui/Layer.h
9ace8f5e79e76893fe4ca9e4d10f6c4056330485 08-Jul-2011 Romain Guy <romainguy@google.com> Use NEAREST filtering for layers whenever possible.

Change-Id: Id5bee1bd4a322cf93e8000b08e18f1e1b058648e
/frameworks/base/libs/hwui/Layer.h
8f0095cd33558e9cc8a440047908e53b68906f5f 03-May-2011 Romain Guy <romainguy@google.com> Allows to render with an OpenGL context inside a TextureView.

Change-Id: I59453f7fc3997f0502a1c5d325d37fed376fabc7
/frameworks/base/libs/hwui/Layer.h
aa6c24c21c727a196451332448d4e3b11a80be69 29-Apr-2011 Romain Guy <romainguy@google.com> New widget: TextureView
Bug #4343984

TextureView can be used to render media content (video, OpenGL,
RenderScript) inside a View.

The key difference with SurfaceView is that TextureView does
not create a new Surface. This gives the ability to seamlessly
transform, animate, fade, etc. a TextureView, which was hard
if not impossible to do with a SurfaceView.
A TextureView also interacts perfectly with ScrollView,
ListView, etc. It allows application to embed media content
in a much more flexible way than before.

For instance, to render the camera preview at 50% opacity,
all you need to do is the following:

mTextureView.setAlpha(0.5f);
Camera c = Camera.open();
c.setPreviewTexture(mTextureView.getSurfaceTexture());
c.startPreview();

TextureView uses a SurfaceTexture to get the job done. More
APIs are required to make it easy to create OpenGL contexts
for a TextureView. It can currently be done with a bit of
JNI code.

Change-Id: Iaa7953097ab5beb8437bcbbfa03b2df5b7f80cd7
/frameworks/base/libs/hwui/Layer.h
9fc27819d75e24ad63d7b383d80f5cb66a577a0d 27-Apr-2011 Romain Guy <romainguy@google.com> Correctly compute tex coords for rect layers.
Bug #4192695

This change also fixes Javadoc links in the framework.

Change-Id: Ia548bcb18baba5d6fe6a4a04a2278e3a3bd465b2
/frameworks/base/libs/hwui/Layer.h
40667676e542a9daeafeac9904c30004e8706fd3 18-Mar-2011 Romain Guy <romainguy@google.com> Optimize rect-shaped layers.

This brings back an optimization disabled in HC-MR1. This time the
correct geometry is generated to avoid unnecessary blending.

Change-Id: Id56404dc46bb84c75facc25c18488a690741b592
/frameworks/base/libs/hwui/Layer.h
f219da5e32e85deb442468ee9a63bb28eb198557 16-Jan-2011 Romain Guy <romainguy@google.com> Don't blend transparent pixels when rendering layers.

With this change, the rendere keeps track of what regions are rendered into
and generates a mesh that matches these regions exactly. The mesh is used
to composite the layer on screen.

Change-Id: I1f342576b9134fb29caff7fb8f4c1da179fe956d
/frameworks/base/libs/hwui/Layer.h
171c592f0b7066acf279863c8a52ddabea49d3db 06-Jan-2011 Romain Guy <romainguy@google.com> New layers API for Views.

This API can be used to back a view and its children with either a
software layer (bitmap) or hardware layer (FBO). Layers have
various usages, including color filtering and performance
improvements during animations.

Change-Id: Ifc3bea847918042730fc5a8c2d4206dd6c9420a3
/frameworks/base/libs/hwui/Layer.h
5b3b35296e8b2c8d3f07d32bb645d5414db41a1d 28-Oct-2010 Romain Guy <romainguy@google.com> Optimize FBO drawing with regions.
This optimization is currently disabled until Launcher is
modified to take advantage of it. The optimization can be
enabled by turning on RENDER_LAYERS_AS_REGIONS in the
OpenGLRenderer.h file.

Change-Id: I2fdf59d0f4dc690a3d7f712173ab8db3848b27b1
/frameworks/base/libs/hwui/Layer.h
8550c4c7b5952b7a4e1e0ede95c9492d03099a13 09-Oct-2010 Romain Guy <romainguy@google.com> Better cache for layers, reduce memory usage and increase framerate.

Change-Id: I5ff864a361db4791bd5ff6be716f7ce692ef572d
/frameworks/base/libs/hwui/Layer.h
eb99356a0548684a501766e6a524529ab93304c8 06-Oct-2010 Romain Guy <romainguy@google.com> Optimize saveLayer() when the clip flag is set.

This speeds up applications, especially Launcher.
/frameworks/base/libs/hwui/Layer.h
0bb5667b4ef91fefd0500fae0186789d15d54e0e 01-Oct-2010 Romain Guy <romainguy@android.com> Fix INVALID_OPERATION error with layers rendering.

This change is a workaround for a driver bug that causes an INVALID_OPERATION
to be thrown on every glCopyTexSubImage() call. This change also adds a new
test for gradients local matrices.

Change-Id: I41b7437481026702d0a3a9677f099b4557c0a84e
/frameworks/base/libs/hwui/Layer.h
38c85b907a478af96d71b9a5df5a2066b8475311 23-Sep-2010 Romain Guy <romainguy@android.com> Correctly initialize/refresh layers.

Change-Id: Id8cdcf587b13098460f7d4aa1bd17708784d89bb
/frameworks/base/libs/hwui/Layer.h
f607bdc167f66b3e7003acaa4736ae46d78c1492 11-Sep-2010 Romain Guy <romainguy@google.com> Correct implementation of saveLayer().

Change-Id: I5375126636913e0a84f2d6bbd0ebe40d2e4f2763
/frameworks/base/libs/hwui/Layer.h
f7f93556c8fcc640ab5adef79d021a80a72a645a 09-Jul-2010 Romain Guy <romainguy@google.com> Draw n-patches using OpenGL.

Currently only tested with title bars and buttons.

Change-Id: I8263a9281898dc0e943b1b8412827fe55639b9d6
/frameworks/base/libs/hwui/Layer.h
6c81893c626499e58c8eeb20d6c35ec4e1ce808b 08-Jul-2010 Romain Guy <romainguy@google.com> Simpler way to deal with the FBO multi-cache.

This change removes the need for the SortedList and instead just
add a generated id to each FBO stored in the cache. This is an
artificial way to store several FBOs with the same dimensions.

Change-Id: I9638364e9bdc0f2391261937a0c86096f20505bf
/frameworks/base/libs/hwui/Layer.h
dda570201ac851dd85af3861f7e575721d3345da 06-Jul-2010 Romain Guy <romainguy@android.com> Add a layer (FBO) cache.

The cache is used to draw layers so that a new
texture does not have to be recreated every time
a call to saveLayer() happens.

The FBO cache used a KeyedVector, which is a bad
idea. The cache should be able to store several
FBOs of the same size (this happens a lot during
scrolling with fading edges for instance.) This
will be changed in a future CL.

Change-Id: Ic316189e625f0dbcf0d273a71cc981a433d48726
/frameworks/base/libs/hwui/Layer.h