This change makes updateTexImage default to performing the necessary
synchronization and adds an argument for SurfaceFlinger to disable that
synchronization so that it can be performed lazily.
Change-Id: I7c20923cc786634126fbf7021c9d2541aa77be5d
Bug: 6991805
The Surface createDisplay() call takes a display name for debugging.
This change carries it through SurfaceFlinger and displays it in
the "dumpsys SurfaceFlinger" output.
Bug 7058158
Change-Id: I79f3474a8656ff1beb7b478e0dbf2c5de666118a
The hints were being set a little too late, so the pre-rotation stuff
wasn't quite working.
Bug 7054997
Change-Id: Id8d5c626db7a76f768ba762a145b315878ee08e6
This change adds a call to eglDestroySync after we've dup'd the fd for the
Android fence that the EGLSyncKHR object wraps.
Change-Id: I4fa6ece863260793630d70bb9a69d6284d05d99e
This change adds a compile-option to use eglWaitSyncANDROID to ensure that
texturing operations that access the current buffer of a SurfaceTexture do not
occur until the buffer is completely written. It also moves this
synchronization into a new SurfaceTexture method called doGLFenceWait and
changes SurfaceFlinger's Layer class to use that method rather than performing
its own wait on the fence.
Change-Id: I70afa88086ca7ff49a80e3cd03d423767db7cb88
This change adds support for using Android fences that come from EGLSyncKHR
objects as the release fence for a buffer.
Change-Id: Ice192ce2ec001020f909a2018afdf0f17b24dec9
The ComposerService object wasn't watching for SurfaceFlinger
restarts, which doesn't usually matter because the app framework
restarts when SurfaceFlinger dies. However, mediaserver continues
to run, which means its ComposerService object was trying to use
a dead handle, and playback of DRM movies was failing.
This adds a DeathRecipient listener and some logic to re-establish
the SurfaceFlinger connection.
Bug 6645813
Change-Id: I07581b881d3835601aa57d5358c8259d93bc4515
This change moves some common fence handling code into the base class for
BufferQueue consumer classes. It also makes the ConsumerBase class initialize
a buffer slot's fence with the acquire fence every time a buffer is acquired.
Change-Id: I0bd88bc269e919653b659bfb3ebfb04dd61692a0
This change adds some infrastructure for testing the BufferQueue class. It
also includes a test that tests the new check in BufferQueue::acquireBuffer
that prevents the consumer from acquiring more than one buffer beyond the max
acquired buffer count that was set.
Change-Id: I38554ad3f9a53d2ddeba7ef0deee35ec2e2f9775
This change disables the CpuConsumer tests because they require a Gralloc
format that is not supported on all devices.
Change-Id: Ifaa618062c1dae53d9fcb9e16ba92c480d3dbd0c
This change adds an error check to ensure that consumers don't acquire more
buffers than the maximum that they set.
Change-Id: I026643564bde52732e4ee6146972b207ddbbba77
This change makes BufferQueue derive the min undequeued buffer count from a max
acquired buffer count that is set by the consumer. This value may be set at
any time that a producer is not connected to the BufferQueue rather than at
BufferQueue construction time.
Change-Id: Icf9f1d91ec612a079968ba0a4621deffe48f4e22
This change is a clean up of some of the handling of the maximum number of
buffers that are allowed at once. It mostly renames a few member variables and
methods, but it includes a couple small refactorings.
Change-Id: I9959310f563d09583548d4291e1050a7bbc7d87d
This is a compatibility shim for one product whose drivers
are depending on SurfaceComposerClient::getDisplayInfo(
int, DisplayInfo*) when it really shouldn't.
Revert this patch when the problem has been resolved.
Bug: 7065398
Change-Id: I6542691b81fd1b1e1d79500a62e82d40a3d51db7
Use only display tokens in the API to refer to new displays.
Don't require the caller to specify the display when creating
a surface (since in general a surface could be shown on
any display).
This is intended to be a minimum change just to update the API.
Note that SurfaceFlinger still uses DisplayID in a few places
internally that might cause some features not to work properly
when there are multiple displays (LayerScreenshot, for example).
Change-Id: I3d91eec2da406eefd97bcd53655d403ad865a7e6
This change makes SurfaceTexture inherit from ConsumerBase. It removes all of
the functionality from SurfaceTexture that is now provided by the base class.
This includes fixes for two bugs that were found after checking this change in
the first time and then reverting it.
Change-Id: Ie2d9f4f27cfef26fdac341de3152e842b01a58d2
BufferItemConsumer allows for acquiring BufferQueue's BufferItems,
which contain all the data and metadata the BufferQueue has for a
given graphics buffer.
This consumer is useful when direct access to the native buffer_handles
is needed by the client.
Also includes a minor cleanup of CpuConsumer's use of 'virtual'.
Bug: 6243944
Change-Id: If7dc4192b15ac499555f1eda42a85140f2434795
This change fixes SurfaceTexture::freeBufferLocked so that it calls the base
class implementation.
Change-Id: I45d76fb2eb02c1fa6e4e917823ead83e2086bd15
This change makes SurfaceTexture inherit from ConsumerBase. It removes all of
the functionality from SurfaceTexture that is now provided by the base class.
Change-Id: I4a881df42810a14ee32d4ef7c8772a8f2510f4c7
this change introduces a new class LightFlattenable<> which is
a protocol to flatten simple objects that don't require
binders or file descriptors; the benefit of this protocol is that
it doesn't require the objects to have a virtual table and give us
a consitant way of doing this.
we also introduce an implementation of this protocol for
POD structures, LightFlattenablePod<>.
Parcel has been update to handle this protocol automatically.
Sensor, Rect, Point and Region now use this new protocol.
Change-Id: Icb3ce7fa1d785249eb666f39c2129f2fc143ea4a
- displays are represented by a binder on the client side
- c++ clients can now create and modify displays
Change-Id: I203ea5b4beae0819d742ec5171c27568f4e8354b
This change refactors the FramebufferSurface class to inherit from the new
ConsumerBase class.
Bug: 6620200
Change-Id: I46ec942ddb019658e3c5e79465548b171b2261f2