summaryrefslogtreecommitdiffstats
path: root/libs/gui
Commit message (Collapse)AuthorAgeFilesLines
* Within CpuConsumer, use gralloc lockAsync/unlockAsyncRiley Andrews2014-08-191-31/+60
| | | | Change-Id: I6b2cd195e111c3c7bf94c8052af4db92e09649a5
* Merge "Tunneled Video Playback support" into lmp-devRachad2014-08-091-0/+10
|\
| * Tunneled Video Playback supportRachad2014-08-041-0/+10
| | | | | | | | | | | | | | | | | | Added native_window_set_sideband_stream() method to Surface.[h|cpp] Added ConfigureVideoTunnelModeParams OMX configuration structure to HardwareAPI.h Bug: 16132368 Change-Id: I28fa1b9dbe858d93e353e0991098cad45c626bd9
* | Revert "Modify EGL to disconnect the window when the surface gets destroyed."Michael Lentine2014-08-081-2/+2
| | | | | | | | This reverts commit 843cbb241da60ada234918a30cfe9a01a1e04187.
* | Sensor related changes for NDK.Aravind Akella2014-08-051-1/+12
|/ | | | | | | | | i) ASensorManager_getDefaultSensor returns a wake-up/non wake-up sensor depending on the type. ii) Add ASensor_isWakeUpSensor and ASensorManager_getDefaultSensorEx methods. Bug : 16399898 Change-Id: I1a86fb8d9de23039fdf41679d1487e1cd761a9d0
* Sensor.cpp changes.Aravind Akella2014-07-311-9/+48
| | | | | | | | 1) Rename TILT_DETECTOR 2) Set mFlags correctly for wake-up sensors. 2) Log errors for incorrect sensor flags. Change-Id: Ia449217d3b8a53353ad6b5c33c544ce37eb1de4f
* Allow for resizing of Virtual Displays.Michael Lentine2014-07-301-0/+4
| | | | | | | | | | Modify SurfaceFlinger to use VirtualDisplaySurface in all cases when a virtual display is used. Add functionality in VirtualDisplaySurface to resize the buffers aquired in the QueueBufferOutput. Add transaction support in SurfaceFlinger for resize. Add the modification of the size in DisplayDevice. Change-Id: Iae7e3556dc06fd18d470adbbd76f7255f6e6dd6b Tested: None
* Have VirtualDisplays send SF resize messages when resizingMichael Wright2014-07-301-0/+14
| | | | Change-Id: I76d15b22099a659450ec875836c9bf2b6584838f
* Merge "Modify EGL to disconnect the window when the surface gets destroyed." ↵Michael Lentine2014-07-251-2/+2
|\ | | | | | | into lmp-dev
| * Modify EGL to disconnect the window when the surface gets destroyed.Michael Lentine2014-07-291-2/+2
| | | | | | | | | | | | Bug: 14445579 Change-Id: I1d263ff6cffcb6e448761fca7ca4b06466ad65aa
* | Remove WAKE_UP_* sensor constants.Aravind Akella2014-07-281-77/+4
| | | | | | | | Change-Id: I3de9d114ce82de4ed841932747d72e1f6f73c24f
* | BufferQueueProducer: fix which slot gets pre-allocatedAntoine Labour2014-07-251-1/+1
| | | | | | | | | | | | | | | | | | Commit 78014f32da6d0ebf52fb34ebb7663863000520a0 introduced a bug that made us pre-allocate buffers into the last available free slots instead of the first available ones. This in turn caused more re-allocations, and possibly triggered driver bugs. Change-Id: Ic4a70e676b4f2bbb054bc873be62ced26e3099a0
* | Merge "SensorService performance improvements." into lmp-devAravind Akella2014-07-243-15/+15
|\ \
| * | SensorService performance improvements.Aravind Akella2014-07-243-15/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | i) Send ack for wake_up sensors on the socket connection instead of using Binder RPC. ii) Cache events per connection in case there are write failures. Compute cache size from FIFO counts of sensors. iii) Send FlushCompleteEvent only for apps that explicitly called flush(). Change-Id: I018969736b7794b1b930529586f2294a03ee8667
* | | Merge "GLProducer: Reference count images rather than buffers." into lmp-devEric Penner2014-07-241-169/+155
|\ \ \ | |/ / |/| |
| * | GLProducer: Reference count images rather than buffers.Eric Penner2014-07-211-169/+155
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In most cases, EGLImages can be created one-to-one with graphic buffers in slots, but that was difficult due to some special cases: - ReleaseTexImage binds a custom 'unslotted' debug image. - When all slots are freed, we still need to hang on to one. These cases were handled by keeping an additional reference to the 'current' buffer (mCurrentTextureBuf), but we would create new images since we can't reference count them in the same way. This patch uses the same semantics, except that it reference counts the image (an EglImage wrapper class) rather than just buffer. The wrapper class also detects the cases when we need a new EGLImage, and only creates them in those rare cases. Change-Id: I2915761dbe49d2a9bda1f59e60f857543634636b
* | | BufferQueue: release mutex while allocating. DO NOT MERGEAntoine Labour2014-07-222-41/+101
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | BufferQueueProducer::allocateBuffers used to keep the BufferQueueCore mutex while doing the buffer allocation, which would cause the consumer (which also needs the mutex) to block if the allocation takes a long time. Instead, release the mutex while doing the allocation, and grab it again before filling the slots. Keep a bool state and a condvar to prevent other producers from trying to allocate the slots while the mutex is released. Bug: 11792166 Change-Id: I4ab1319995ef892be2beba892f1fdbf50ce0416d (cherry picked from commit ea96044470a29133321c681080870b9d31f81a19)
* | Add glance gesture for doze mode.Jeff Brown2014-07-171-0/+4
|/ | | | Change-Id: I038a706c3999200313ff5360c5ff1150ec081f08
* Add sticky transform to surfaceflinger.Ruben Brunk2014-07-143-5/+50
| | | | | | | | | | Bug: 15116722 - Adds a sticky transform field that can be set from a SurfaceFlinger client Surface. This transform is added to any transform applied to the Surface. Change-Id: Idaa4311dfd027b2d2b8ea5e2c6cba2da5779d753
* Merge "BufferQueue: Add allocateBuffers method"Dan Stoza2014-06-273-0/+87
|\
| * BufferQueue: Add allocateBuffers methodDan Stoza2014-06-203-0/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds an allocateBuffers method to BufferQueue, which instructs it to allocate up to the maximum number of buffers allowed by the current configuration. The goal is that this method can be called ahead of render time, which will prevent dequeueBuffers from blocking in allocation and inducing jank. This interface is also plumbed up to the native Surface (and, in another change, up to the Java Surface and ThreadedRenderer). Bug: 11792166 Change-Id: I4aa96b4351ea1c95ed5db228ca3ef98303229c74
* | GLConsumer: Allow creation in detached modeDan Stoza2014-06-251-0/+27
| | | | | | | | | | | | | | | | Adds a constructor that doesn't require a GLES texture name and sets up the GLConsumer in detached mode. Bug: 15616428 Change-Id: Idc9ea2e59baa24bbd959da9fffe0fb71c0aa9818
* | GLConsumer: Stop using default constructor paramsDan Stoza2014-06-243-4/+8
|/ | | | | | | | Removes the dependency on default constructor parameters for GLConsumer so that a different constructor prototype can safely be added. Change-Id: I0da924bbd4c141edbf305598c1be8bc575654680
* Merge "Surface reportingMode for Sensors."Aravind Akella2014-06-121-33/+73
|\
| * Surface reportingMode for Sensors.Aravind Akella2014-06-121-33/+73
| | | | | | | | Change-Id: Iac8dd3408c90eb7d285a2e8043131fab3a7e58fa
* | Merge "surfaceflinger: Replace blank/unblank with setPowerMode"Prashant Malani2014-06-122-28/+13
|\ \
| * | surfaceflinger: Replace blank/unblank with setPowerModePrashant Malani2014-06-052-28/+13
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We replace the blank/unblank calls in surfaceFlinger with a more generic setPowerMode() routine. Some displays support different power modes (for example, with reduced color palettes). Depending on the use case we should be able to toggle these modes, so as to achieve incremental power savings. Initially, three power modes will be supported: - HWC_POWER_MODE_OFF - HWC_POWER_MODE_DOZE - HWC_POWER_MODE_NORMAL HWC_POWER_MODE_OFF will correspond to blanking the display, while HWC_POWER_MODE_NORMAL will correspond to unblanking. HWC_POWER_MODE_DOZE will put the display into a low power setting, if it is supported in hardware. If such a low power mode is not supported, it should be treated as a call to set the mode to HWC_POWER_MODE_NORMAL. As a consequence of adding the mPowerMode field, the mScreenAcquired is no longer required, and thus references to it are removed and replaced equivalent references to mPowerMode. We also add the glue code to connect the services invocation of setting a power mode and the HAL implementation in HWComposer. Bug: 13472578 Change-Id: I431595ecf16d2f2c94259272db3dd42f29636204 Signed-off-by: Prashant Malani <pmalani@google.com>
* | am 72676e7d: am 0e1313cd: Merge "libgui: 64-bit compile issues"Mark Salyzyn2014-06-112-4/+6
|\ \ | | | | | | | | | | | | * commit '72676e7d0db89d477495245aa15f1a128b5c35bc': libgui: 64-bit compile issues
| * \ am 0e1313cd: Merge "libgui: 64-bit compile issues"Mark Salyzyn2014-06-092-4/+6
| |\ \ | | | | | | | | | | | | | | | | * commit '0e1313cdb1d5d21e4d6123f77b4238f1c8c2d564': libgui: 64-bit compile issues
| | * | libgui: 64-bit compile issuesMark Salyzyn2014-06-092-4/+6
| | | | | | | | | | | | | | | | Change-Id: I29961c1567b8431518a7d032ea43385e23b7bb37
| | * | Fix flattening/unflattening of android::Sensor.Narayan Kamath2014-05-301-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Write string lengths as uint32_t so that their width is the same on 32 and 64 bit processes. Note that this fixes another bug as a side effect; getFlattenedSize was assuming that sizeof(uint32_t) == sizeof(size_t). Change-Id: I7b6e3993e1f1ac45c14832ce59c59e0772855a2f
* | | | libgui: 64 bit compile issues (part deux)Mark Salyzyn2014-06-095-23/+38
| |_|/ |/| | | | | | | | | | | | | | | | | | | | | | | - nsecs_t printed with PRId64 - int64_t/uint64_t print issues - some size_t printing issues. - missing argument to BQ_LOGV Change-Id: I493f2b578e801dc38c44f8c536faa45266720402
* | | Merge "SurfaceFlinger: Add sourceCrop to screenshot"Dan Stoza2014-05-283-13/+17
|\ \ \
| * | | SurfaceFlinger: Add sourceCrop to screenshotDan Stoza2014-05-233-13/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds a sourceCrop Rect parameter to screenshot commands, which allows clients to capture only a portion of the screen instead of the whole screen. Bug: 15137922 Change-Id: I629447573cd34ffb96334cde7ba02490b9ea06d8
* | | | Surface maxDelay and isWakeUpSensor flag in Sensor.java.Aravind Akella2014-05-231-3/+29
|/ / / | | | | | | | | | Change-Id: Idd1e9045190beeca87b086b272e8cbf0bed05bae
* | | am 47d871b2: am d35e3af0: Set default values for FifoMaxEventCount and ↵Aravind Akella2014-05-131-0/+3
|\ \ \ | |/ / | | | | | | | | | | | | | | | ReservedEventCount. * commit '47d871b2795f714499a34ffe85b67f8577883f7b': Set default values for FifoMaxEventCount and ReservedEventCount.
| * | am d35e3af0: Set default values for FifoMaxEventCount and ReservedEventCount.Aravind Akella2014-05-131-0/+3
| |\ \ | | | | | | | | | | | | | | | | * commit 'd35e3af04d4b7e850a3b87b2211d1a3993f9b76f': Set default values for FifoMaxEventCount and ReservedEventCount.
| | * | Set default values for FifoMaxEventCount and ReservedEventCount.Aravind Akella2014-05-121-0/+3
| | | | | | | | | | | | | | | | Change-Id: I4f610c2912ffe1697d1ffb99c556d1c88578466e
* | | | Merge "Add wake gesture in Sensor.cpp"Etienne Le Grand2014-05-121-0/+4
|\ \ \ \
| * | | | Add wake gesture in Sensor.cppEtienne Le Grand2014-05-071-0/+4
| | | | | | | | | | | | | | | | | | | | Change-Id: Ifb1744acffc2d57da43112fb9966261e8246d6de
* | | | | am 38c9e132: am c1ffd351: am bd20e551: Merge "Use asynchronous lock/unlock API"Greg Hackmann2014-05-121-13/+5
|\ \ \ \ \ | | |/ / / | |/| | | | | | | | | | | | | * commit '38c9e1327a5b24267c3dab5293bc9d7ada6e9fc9': Use asynchronous lock/unlock API
| * | | | am c1ffd351: am bd20e551: Merge "Use asynchronous lock/unlock API"Greg Hackmann2014-05-121-13/+5
| |\ \ \ \ | | | |_|/ | | |/| | | | | | | | | | | | * commit 'c1ffd351bc44483369271c11dd4c6391bba8c64c': Use asynchronous lock/unlock API
| | * | | Use asynchronous lock/unlock APIFrancis Hart2014-05-121-13/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The gralloc API now provides a way for using lock/unlock with the Android explicit synchronisation concept. This changes updates the GraphicBuffer class to also expose this functionality, and updates the Surface class to make use of in line with the dequeueBuffer/queueBuffer mechanism. This new behaviour is dependent on GRALLOC_MODULE_API_VERSION_0_3. If the local gralloc module does not support this then the existing synchronous lock/unlock mechanism will be used. Change-Id: I8c3fd9592e0c5400ac9be84450f55a77cc0bbdc5
* | | | | am 9493d492: am 9eb142e3: am a9d49f99: Merge "Revert "Use asynchronous ↵Greg Hackmann2014-05-091-5/+13
|\ \ \ \ \ | |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | lock/unlock API"" * commit '9493d4924a59f14b698389386337a9c07a7ea3c4': Revert "Use asynchronous lock/unlock API"
| * | | | am 9eb142e3: am a9d49f99: Merge "Revert "Use asynchronous lock/unlock API""Greg Hackmann2014-05-091-5/+13
| |\ \ \ \ | | |/ / / | | | | | | | | | | | | | | | * commit '9eb142e34a5bc11508c0bd6f60ad3933c60aa530': Revert "Use asynchronous lock/unlock API"
| | * | | Revert "Use asynchronous lock/unlock API"Greg Hackmann2014-05-091-5/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 378ef07760eda717367d9429428c42d54d54d9a7. Change-Id: I1de5ab973b5383633e75924fe90ac3ca8216c36a
* | | | | am 4b46776f: am 8a6cd189: am f60564a1: Merge "Use asynchronous lock/unlock API"Greg Hackmann2014-05-091-13/+5
|\ \ \ \ \ | |/ / / / | | | / / | |_|/ / |/| | | * commit '4b46776ff88c5a365700b88e8b2b04e1b2c77e6e': Use asynchronous lock/unlock API
| * | | am 8a6cd189: am f60564a1: Merge "Use asynchronous lock/unlock API"Greg Hackmann2014-05-091-13/+5
| |\ \ \ | | |/ / | | | | | | | | | | | | * commit '8a6cd189034ec4709a66e581b41deba56c028291': Use asynchronous lock/unlock API
| | * | Use asynchronous lock/unlock APIFrancis Hart2014-05-021-13/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The gralloc API now provides a way for using lock/unlock with the Android explicit synchronisation concept. This changes updates the GraphicBuffer class to also expose this functionality, and updates the Surface class to make use of in line with the dequeueBuffer/queueBuffer mechanism. This new behaviour is dependent on GRALLOC_MODULE_API_VERSION_0_3. If the local gralloc module does not support this then the existing synchronous lock/unlock mechanism will be used. Change-Id: I77daa1beb197b63b1c2f281b8414ac4ae4b5b03c
* | | | Enable changing display configurationDan Stoza2014-05-052-10/+87
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows querying and switching display device configurations through the ISurfaceComposer/SurfaceComposerClient interface. Bug: 14320401 Change-Id: I8c22165698950e5da32204c1c4da92122f91a715