summaryrefslogtreecommitdiffstats
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
* Add support for OMX_QCOM_COLOR_FormatYUV420PackedSemiPlanar32m color formatRom Lemarchand2013-04-111-0/+1
| | | | Change-Id: I9392eb961ec92d4d778573b7a142344e552c80d6
* Merge "Updated comments" into jb-mr2-devAndy McFadden2013-04-111-101/+193
|\
| * Updated commentsAndy McFadden2013-04-051-101/+193
| | | | | | | | | | | | Updated many comments. Added one minor error check. Change-Id: Ib935dd99d417bada91d2e198008a50dd94269316
* | Merge changes I82e361a6,I83694682 into jb-mr2-devJamie Gennis2013-04-091-0/+12
|\ \ | | | | | | | | | | | | | | | * changes: libgui_test: increase the tolerance for a YUV test libgui: fix an EGLImage leak
| * | libgui: fix an EGLImage leakJamie Gennis2013-04-081-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves the call to ConsumerBase::abandon from the ConsumerBase dtor to ConsumerBase::onLastStrongRef. The abandon call relies on virtual methods to perform the clean-up, so calling it from the ConsumerBase dtor after the derived classes dtors ran was skipping some of the clean-up. The onLastStrongRef method should get called just before the most derived class's dtor gets called. Bug: 8349135 Change-Id: I836946826927cc1ed69c049049f525f92b17a269
* | | Merge "Implement async event callout from drm plugin to Java app" into ↵Jeff Tinker2013-04-051-3/+39
|\ \ \ | | | | | | | | | | | | jb-mr2-dev
| * | | Implement async event callout from drm plugin to Java appJeff Tinker2013-04-031-3/+39
| | | | | | | | | | | | | | | | Change-Id: I83a7757a7b83676ce1a9ffa6ff0a8e495e31b859
* | | | latch transparent region hint only when we get a new frameMathias Agopian2013-04-021-0/+4
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | since the transparent region hint really depends on the content of the window containing the SurfaceView (it's calculated by the view hierarchy based on overlapping views), it makes sense to latch it only when the content of the window (the app) changes. This should help fixing drawing artifacts when changing the layout of a window containing a SurfaceView. Bug: 8511430 Change-Id: Ic3aa668495293cb4d82a2cd7dcf3b6a337287678
* | | Merge "MediaDrm API update" into jb-mr2-devJeff Tinker2013-04-021-33/+100
|\ \ \ | |/ / | | / | |/ |/|
| * MediaDrm API updateJeff Tinker2013-04-011-33/+100
| | | | | | | | | | | | | | | | Clarify offline usage of sessions and keys and implement implement CryptoSession to support additional crypto use cases. Change-Id: I418ffbb37e3036a2b5eea5a86ac88a5af1a9da07
* | don't use compile-time configuration of libgui as much as possibleMathias Agopian2013-03-292-4/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We now detect at runtime which sync features to use, which allows us to remove a lot of the compile-time configuration options. There is still one option though, to disable KHR_fence_sync on some devices (which are more efficient without it). - added a backdoor to get the vendor's EGL strings the new logic is: - use always ANDROID_native_fence_sync if available - fallback to KHR_fence_sync if available and not disabled by the compile-time option - use KHR_wait_sync if available and either of the above is enabled Change-Id: I9c4b49d9ff1151faf902cc93bd53ea5f205aaabf
* | make sure to unlock the screenshot's buffer on destructionMathias Agopian2013-03-261-0/+1
|/ | | | | | | this fixes a memory leak on various devices Bug: 8475134 Change-Id: I25924674c803a0cb22371a95c60664c36acb0340
* Pass sp<Fence>s around instead of file descriptorsJesse Hall2013-03-221-7/+6
| | | | Change-Id: Iac70584a2207940730e8f803a543e4e9a4000c47
* Merge "improved CallStack a bit" into jb-mr2-devMathias Agopian2013-03-221-2/+4
|\
| * improved CallStack a bitMathias Agopian2013-03-211-2/+4
| | | | | | | | | | | | | | - added a ctor that updates and dumps the stack immediately - added a "logtag" parameter to dump() Change-Id: Ie51c256071d282591752243bdb4f68cf9ff8829d
* | Merge "CpuConsumer: Properly track acquired buffers" into jb-mr2-devEino-Ville Talvala2013-03-211-5/+16
|\ \
| * | CpuConsumer: Properly track acquired buffersEino-Ville Talvala2013-03-051-5/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CpuConsumer cannot simply assume a slot's buffer is the same buffer between acquire and release, and therefore it could be possible for the same slot to get used for a second acquired buffer, if there's a producer disconnect in between. This would cause a problem when the first buffer is released by the consumer. Instead, use an independent list of acquired buffers to properly track their state. Bug: 8291751 Change-Id: I0241ad8704e53d47318c7179b13daed8181b1fab
* | | Merge "Revert "Revert "Change SurfaceControl setPosition to take floats""" ↵Ramanan Rajeswaran2013-03-211-1/+1
|\ \ \ | |_|/ |/| | | | | into jb-mr2-dev
| * | Revert "Revert "Change SurfaceControl setPosition to take floats""Ramanan Rajeswaran2013-03-211-1/+1
| |/ | | | | | | | | | | This reverts commit bbb57f3331c7182399ed82e9c4f93a965677dde3 Change-Id: Ib8f039f530d6b8175b5205c6c0008b135d4001a2
* | Merge "rework how we take screenshots for a CPU consumer" into jb-mr2-devMathias Agopian2013-03-202-15/+8
|\ \
| * | rework how we take screenshots for a CPU consumerMathias Agopian2013-03-192-15/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We're not using IMemoryHeap as a transport anymore, instead we're providing a CpuConsumer and use the IGraphicBufferProducer version of the screenshot API. However, some GPU drivers don't support properly a GPU to CPU path, to work around this, we use a temporary BufferQueue on the server side for the GL rendering, and we use glReadPixels into the CpuConsumer (we're now using a CPU to CPU path which is always supported). Currently this "wrapping" is always performed, but it can be bypassed on devices that support the GPU to CPU path. This also addresses a DoS attack vector on SurfaceFlinger, where an application could consume all of SF's filedescriptors by creating a lot of screenshots in a row. Bug: 8390553 Change-Id: I9e81514c2a7711b9bb393f74305be7d2abe08f1c
* | | Merge "Updated MediaDrm API based on review input." into jb-mr2-devJeff Tinker2013-03-203-194/+205
|\ \ \ | |/ / |/| |
| * | Updated MediaDrm API based on review input.Jeff Tinker2013-03-133-194/+205
| | | | | | | | | | | | Change-Id: I06716d2616bbe7efaea6cbf9ba7bf303dfae1650
* | | Fix a crasher with RefBase debugging and vectors of wp<>Mathias Agopian2013-03-191-39/+56
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | background: we have some code to fix-up the IDs of references when using RefBase's DEBUG_REFS when those refs are managed by arrays wp<> or sp<> (this is because wp<> / sp<> don't have a trivial ctor when DEBUG_REFS is enabled, and Vector treats them as trivial for obvious performance reasons) this is complicated by the fact that we don't want to have to recompile everything when enabling DEBUG_REFs (i.e.: the Vector code cannot know wheter it's enabled or not for its template stuff). problem: there was a bug in the fix-up code for wp<> which was trying to access the weakref_impl from the RefBase* however, this was moronic since RefBase could have been destroyed if there wasn't any more strong refs -- and this happned. Instead we need to get the weakref_impl directly from the wp<> Change-Id: Ie16e334204205fdbff142acb9faff8479a78450b
* | | Merge changes I61ae54f3,I57cb668e,I7a3f1e1a,Id28a2f9b into jb-mr2-devJesse Hall2013-03-193-8/+7
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | * changes: Add BufferQueueInterposer and use it for virtual displays Add DisplaySurface abstraction Fix argument types in IGraphicBufferProducer methods Minor cleanups/fixes before virtual display refactoring
| * | | Fix argument types in IGraphicBufferProducer methodsJesse Hall2013-03-182-4/+4
| | | | | | | | | | | | | | | | | | | | Bug: 8384764 Change-Id: I7a3f1e1a0584a70af04f9eafef900505389d2202
| * | | Minor cleanups/fixes before virtual display refactoringJesse Hall2013-03-181-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | None of these should change behavior, except for removing some incorrect log messages when using a virtual display. - HWComposer::getAndResetReleaseFenceFd() checks the HWC version, so no need to do that in the DisplayDevice::onSwapBuffersCompleted(). However, it should check that mFramebufferSurface is not NULL like it is for virtual displays. - Comment that FramebufferSurface::dump() overrides the non-virtual ConsumerBase::dump(), and fix it so the right thing happens regardless of the static type of the pointer/reference the callee has. FramebufferSurface::dump() could be removed right now, but I'd need to bring it back in a later change. - Use the right enum for validating display type ids. - Don't try to send hotplug events for virtual displays. - Mark virtual displays as connected so HWComposer::prepare() doesn't think something is wrong when it gets a non-NULL layer list. - Remove unused FramebufferSurface methods. Bug: 8384764 Change-Id: Id28a2f9be86b45f4bb7915fdf7752157035f4294
* | | | Merge "Add Vector::resize()" into jb-mr2-devJesse Hall2013-03-162-1/+8
|\ \ \ \ | |/ / /
| * | | Add Vector::resize()Jesse Hall2013-03-152-1/+8
| | | | | | | | | | | | | | | | | | | | Bug: 8384764 Change-Id: Icee83d389f3e555eba7d419b64c8d52a9aa21b8b
* | | | don't allow screenshots without the READ_FRAMEBUFFER permissionMathias Agopian2013-03-151-2/+9
|/ / / | | | | | | | | | | | | | | | | | | the recent screenshot rework allowed the older screenshot interface to work without that permission Change-Id: I6c4743f4591c81106e3b823d55a055f7b4907de1
* | | Revert "Add a compatibility symbol for the MemoryBase constructor."Elliott Hughes2013-03-141-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | Cherry pick from AOSP to fix the build. See https://android-review.googlesource.com/#/c/53690/ This reverts commit 7f974ff2f317ffbf9256579109f000ec876c3037 Change-Id: I1b123f446d0ff41e11ff81d4ef5f1472b59cac93
* | | am 9b57ad73: am 8facd1b2: Merge "Add a compatibility symbol for the ↵Elliott Hughes2013-03-131-0/+3
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | MemoryBase constructor." * commit '9b57ad737bceba9f8d4f5be303c70fa72be00eaf': Add a compatibility symbol for the MemoryBase constructor.
| * | | Add a compatibility symbol for the MemoryBase constructor.Elliott Hughes2013-03-131-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Third-party libraries are currently trying to use the MemoryBase constructor but failing because we fixed the definition of ssize_t. This is a stop-gap for users of this private API until we can get them fixed. Bug: 8253769 Change-Id: I8a19770f3252d88ee87023fde625cc6289924b0d
| * | | Tweaks for forward compatibilityJean-Baptiste Queru2013-03-063-0/+91
| | | | | | | | | | | | | | | | Change-Id: I136fcbbc14072ee5f5281d09445f28d083ed3ce1
* | | | Surface can now be created only from an IGraphicBufferProducerMathias Agopian2013-03-121-11/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | it can't write itself to a parcel, nor can it be created from a parcel. Change-Id: I69165d5c54d6024b3e546e80d8b57e3dedda7893
* | | | get rid of ISurfaceMathias Agopian2013-03-124-71/+12
| |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ISurface was only used to get the IGraphicBufferProducer from a Layer. It's now replaced by a BBinder subclass / IBinder and is only used as a handle to the surface, to both refer to it and manage its life-time. Also cleaned-up a bit the ISurfaceComposer interface and "create layer" code path. Change-Id: I68d0e02d57b862cffb31d5168c3bc10cea0906eb
* | | Merge "Add TOUCH_NAVIGATION input source" into jb-mr2-devMichael Wright2013-03-121-0/+2
|\ \ \
| * | | Add TOUCH_NAVIGATION input sourceMichael Wright2013-03-111-0/+2
| | | | | | | | | | | | | | | | Change-Id: Id76e2e85246269ba7b16bb9635e41593b45cac1c
* | | | Merge "Add Thread::isRunning and Condition::signal(WakeUpType)" into jb-mr2-devRomain Guy2013-03-112-0/+16
|\ \ \ \ | |/ / / |/| | |
| * | | Add Thread::isRunning and Condition::signal(WakeUpType)Romain Guy2013-03-112-0/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The signal() method is useful to choose whether to wake up one or all threads. Change-Id: I062ab6d3ddd306a9fb735549ea140e2a76eed75a
* | | | rename binder services main thread to Binder_*Mathias Agopian2013-03-073-2/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a binder service's main thread joins the thread pool it retains its name (whatever the exec name was), which is very confusing in systrace. we now rename that thread just like its friends in the thread pool. Change-Id: Ibb3b6ff07304b247cfc6fb1694e72350c579513e
* | | | Make GraphicBuffer a RefBaseMathias Agopian2013-03-061-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - this gives us access to RefBase's refcounting debugging - it doesn't cost much because GraphicBuffer already has a vtable Change-Id: I7f696e421fea14b14bfaeb83880689b83e96af4d
* | | | Remove support for ScreenshotLayerMathias Agopian2013-03-051-2/+0
|/ / / | | | | | | | | | Change-Id: I5b571a4cf3faa77d2c4aca916fa4bd00a1065bb9
* | | Merge "rework screenshot API and implementation" into jb-mr2-devMathias Agopian2013-03-052-2/+16
|\ \ \ | |_|/ |/| |
| * | rework screenshot API and implementationMathias Agopian2013-03-012-2/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - SurfaceFlinger now supports to take a screenshot directly into an IGraphicBufferProducer - reimplement the IMemoryHeap screenshot on top of the above - reimplement LayerScreenshot such that its BufferQueue is directly used as the destination of the screenshot. LayerScreenshot is now a thin wrapper around Layer Bug: 6940974 Change-Id: I69a2096b44b91acbb99eba16f83a9c78d94e0d10
* | | Revert "Change SurfaceControl setPosition to take floats"Dave Burke2013-03-011-1/+1
|/ / | | | | | | | | | | | | | | | | | | Temporary, to fix weekend build, until we get Nvidia code drop. This reverts commit 9a867a8798fa6ea21f6341db31e38ea64fde6c83 DO NOT MERGE Change-Id: I7b5dbc4db46ef3d97dc8598057d5487d6971178b
* | CpuConsumer: Add optional asynchronous modeEino-Ville Talvala2013-02-281-1/+1
| | | | | | | | | | | | | | Bug: 8290146 Bug: 8291751 Change-Id: I9c8ac4bff38b0411e987a204e540d018dba6d0b4
* | CpuConsumer: Don't unlock buffers on producer disconnectEino-Ville Talvala2013-02-281-1/+5
| | | | | | | | | | | | Bug: 8291751 Change-Id: I062a3d34b41183d07fb6b9109cdb6bf0c0c75672
* | Add createTJunctionFreeRegionChris Craik2013-02-271-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | T-junction free regions are useful for rendering regions with various geometric transformations, and the Region's span-ordered, sorted rect list supports T-junction free storage without modification. This approach creates a T-junction free region by splitting each rectangle that is part of a vertical T-junction. This approach is two pass (up and down) so that divisions can trickle up/down to other adjacent spans. Change-Id: Ifcf5e6fe0034c96b00ef09a4433b2b0fce8f4300
* | GraphicBuffer.h: Remove redundant friend class declaration causing warningsIgor Murashkin2013-02-261-1/+0
| | | | | | | | Change-Id: I8a4b0e0b4d0a1cf472de820553c31f2d42044543