Commit Graph

49230 Commits

Author SHA1 Message Date
Jesse Hall
497ba0e085 Don't use implementation-defined format with CPU consumers
If the virtual display surface is being consumed by the CPU, it can't
be allowed with HAL_PIXEL_FORMAT_IMPLEMENTATION_DEFINED since there is
no way for the CPU consumer to find out what format gralloc chose. So
for CPU-consumer surfaces, just use the BufferQueue's default format,
which can be set by the consumer.

A better but more invasive change would be to let the consumer require
a certain format (or set of formats?), and disallow the producer from
requesting a different format.

Bug: 11479817
Change-Id: I5b20ee6ac1146550e8799b806e14661d279670c0
2013-11-04 16:43:03 -08:00
Igor Murashkin
40da5283eb Merge "EGL: rename CallStack::dump into CallStack::log" into klp-dev 2013-10-30 21:09:40 +00:00
Igor Murashkin
1f8363329c EGL: rename CallStack::dump into CallStack::log
Bug: 11324229
Change-Id: Ibac1be182c336e7aa5ac098f08d18b3c188964b4
2013-10-25 17:13:57 -07:00
Aravind Akella
46417b845a Merge "Bug fixes for SensorService" into klp-dev 2013-10-25 23:16:59 +00:00
Aravind Akella
b4099e77ec Bug fixes for SensorService
i) Emulate Flush for AOSP Fusion Sesnsors on newer HALs that support batching.
ii) Early return if there are no events for the current SensorEventConnection.

Bug: 11325707, 11376538

Change-Id: Idb856302463649a99d3d5d0c965bb06ba06b8e1d
2013-10-25 13:58:58 -07:00
Marco Nelissen
708cc794f6 Native counterpart of new power manager method
Cherrypicked from master.

b/9464621

Change-Id: I54c0ed50a57ac870da91db8589a73a2c792dbd8d
2013-10-25 12:50:04 -07:00
Jesse Hall
c354effe97 Fix handling of undefined TARGET_FORCE_HWC_FOR_VIRTUAL_DISPLAYS
related to b/8316155 - Implement HWComposer 1.3 w/ virtual display support
Change-Id: I2dc8d65a74174aa833cc491264f97f1f2df49307
2013-10-25 17:48:09 +00:00
Jesse Hall
93fcb82361 Merge "Add a boardconfig to force HWC composition of virtual displays" into klp-dev 2013-10-23 22:12:54 +00:00
Jesse Hall
c5807f90f8 Merge "Use implementation-defined format when HWC writes to output buffer" into klp-dev 2013-10-23 22:12:37 +00:00
Michael Wright
3223217aed Only consume touches up until the frame time
When resampling is disabled, it's currently possible to consume
touches after the current frame time. This breaks some guarantees and
could cause unexpected behaviors.

Change-Id: I99908a2cac2df9f795dd4a07188b4451213cf3e4
2013-10-21 23:57:17 +00:00
Andy McFadden
8507586903 Wait for buffers to drain
When a BufferQueue producer disconnects and reconnects, we retain
the previously-queued buffers but empty the slots.  This allows
the number of queued buffers to grow without limit.  The low-memory
killer does not approve.

Bug 11069934

Change-Id: Ia2eaa954c7a3904b54209a3701dba01689e204d8
2013-10-18 23:10:16 +00:00
Naseer Ahmed
6a968462f9 Add a boardconfig to force HWC composition of virtual displays
When this boardconfig is defined, even when all virtual display
composition is done by GLES, the HWC will be forced to copy from the
GLES framebuffer to the output buffer. On some hardware this allows
HWC to do format conversions that would otherwise have to be done by
the consumer, with worse power and/or performance.

Bug: 8316155
Change-Id: If980ecc589f138cef063eafa757f7f748196713e
2013-10-17 13:57:58 -07:00
Jesse Hall
1e27ba234c Use implementation-defined format when HWC writes to output buffer
When GLES isn't writing to the output buffer directly, request an
implementation-defined format with minimal usage flags, leaving the
format choice up to gralloc. On some hardware this allows HWC to do
format conversions during composition that would otherwise need to be
done (with worse power and/or performance) by the consumer.

Bug: 8316155
Change-Id: Iee6ee8404282036f9fd1833067cfe11dbadbf0bf
2013-10-17 11:20:22 -07:00
Ed Heyl
dacd415963 merge in klp-release (no-op) 2013-10-16 17:43:06 -07:00
The Android Automerger
993da5c301 merge in klp-release history after reset to klp-dev 2013-10-15 21:14:09 -07:00
The Android Automerger
288515bf44 merge in klp-release history after reset to klp-dev 2013-10-15 15:55:41 -07:00
Jamie Gennis
0a645cc5a9 SurfaceFlinger: give SF its own vsync phase
This change allows SurfaceFlinger to run at a different vsync phase offset from
that used by external listeners.

Bug: 11175503
Change-Id: I561c53a5659fa6dc1e3e4ae30340f3c1a6adceb4
2013-10-15 14:31:41 -07:00
Jamie Gennis
d1700756ec SurfaceFlinger: Add EventControlThread
This change adds a new thread for calling HWComposer's eventControl
asynchronously.  The DispSync-based vsync approach ends up enabling and
disabling HWComposer's vsync callbacks at arbitrary times, and some HWComposer
implementations do not have these calls optimized.

Bug: 11175503
Change-Id: I719be82bd200b391c61d40863b991c7b59acdfd6
2013-10-15 14:31:41 -07:00
Jesse Hall
247423751f Merge "Disable hardware vsync when blanking the screen" into klp-dev 2013-10-15 19:53:11 +00:00
Aravind Akella
641a18688b Merge "SensorService Flush API bug fix." into klp-dev 2013-10-15 17:01:55 +00:00
The Android Automerger
3bd1b65ffb merge in klp-release history after reset to klp-dev 2013-10-15 06:00:54 -07:00
Aravind Akella
c551eac5b1 SensorService Flush API bug fix.
SensorService is dead locking itself when flush is called on older devices which don't support batching. mConnectionLock is acquired twice.

Change-Id: I5c25585bfb2b396df4b05826a9cba1da7997a3ee
2013-10-14 17:09:19 -07:00
Jesse Hall
948fe0ce74 Disable hardware vsync when blanking the screen
Bug: 11220224
Change-Id: I99d0a42e1a6bb0aaf89706f6d100e9ef2a5deaa4
2013-10-14 16:25:01 -07:00
Jesse Hall
8e26b28be6 Filter out vsync events from HWC with duplicate timestamps
Bug: 11220224
Change-Id: I4efe0b66ea8969bf0ec3c4fcb325d354c8a0c315
2013-10-14 15:34:00 -07:00
The Android Automerger
4fec2900a3 merge in klp-release history after reset to klp-dev 2013-10-13 19:20:31 -07:00
Aravind Akella
2d344979eb Merge "Adding PackageManager feature strings for stepcounter and stepdetector." into klp-dev 2013-10-13 22:47:47 +00:00
Aravind Akella
d7a5342828 Adding PackageManager feature strings for stepcounter and stepdetector.
Change-Id: I75ec21900fdc3ea80b61ec12c851a0c5ce9c44e8
2013-10-13 14:53:45 -07:00
Jesse Hall
44e45cfeb3 Merge "DispSync: don't compensate for wakeup latency" into klp-dev 2013-10-13 20:13:59 +00:00
The Android Automerger
26ef413c59 merge in klp-release history after reset to klp-dev 2013-10-13 06:02:02 -07:00
Andy McFadden
6410c8c409 Merge "Use black for blackout layer" into klp-dev 2013-10-11 21:39:49 +00:00
Aravind Akella
4c4cd9c8cc Change API from flush(handle) to flush(). Call flush on all active sensors in the given SensorEventConnection.
Change-Id: I4ef2bec80406c517903ab9782dc9eaf3fa8b7f36
2013-10-11 12:42:13 -07:00
Andy McFadden
c6f2169559 Use black for blackout layer
SurfaceFlinger was rendering dark purple for secure content, which
showed up when we took a screen shot for the orientation change
animation.  Use black instead.

Bug 11157921

Change-Id: I3895e8168891d49dc5b84eed599bcd0a303bb70a
2013-10-11 11:16:03 -07:00
Michael Wright
a8b5982c32 Eliminate latency when resampling is disabled
Since the latency was introduced to avoid egregious errors during
resampling, remove it when we aren't resampling.

Change-Id: Ia8e9a9afb1e16212fec81a8c9c661c598e1b0ebf
2013-10-10 22:13:38 -07:00
Dave Burke
9c0dfa0973 Merge "Eliminate latency when resampling is disabled" into klp-dev 2013-10-11 02:33:15 +00:00
Aravind Akella
5d6aa95129 Merge "Change API from flush(handle) to flush(). Call flush on all active sensors in the given SensorEventConnection." into klp-dev 2013-10-11 02:05:41 +00:00
Michael Wright
ad526f8505 Eliminate latency when resampling is disabled
Since the latency was introduced to avoid egregious errors during
resampling, remove it when we aren't resampling.

Change-Id: Ia8e9a9afb1e16212fec81a8c9c661c598e1b0ebf
2013-10-10 18:54:12 -07:00
Jesse Hall
5c65efe2b1 Merge "Wake up disp sync thread when setting display period" into klp-dev 2013-10-10 22:24:32 +00:00
Jesse Hall
72f69d9f23 Wake up disp sync thread when setting display period
Bug: 10624956
Change-Id: I272c15f319521bfbd1bb70451366c7dd84d60bf9
2013-10-10 14:48:22 -07:00
Andy McFadden
0e9c51ec78 Fix blank / partial screenshots
The screen capture code wasn't waiting for the render to finish,
so sometimes you'd see an empty or partial image.

Bug 11131777

Change-Id: Ic64087322ce3bb15bb5f4fb1eb07579880fe6197
2013-10-10 12:16:58 -07:00
Jamie Gennis
0d5c60edf1 DispSync: don't compensate for wakeup latency
This change removes the wakeup latency compensation from the software-generated
vsync events.  Choreographer can't handle timestamps in the future, so don't
aim for early wake-ups with the expectation that the actual wake-up will be
late.

Bug: 11153576
2013-10-09 17:56:42 -07:00
Aravind Akella
701166d9f6 Change API from flush(handle) to flush(). Call flush on all active sensors in the given SensorEventConnection.
Change-Id: I4ef2bec80406c517903ab9782dc9eaf3fa8b7f36
2013-10-09 17:26:01 -07:00
Andy McFadden
2d8d120dc1 Fix blank / partial screenshots
The screen capture code wasn't waiting for the render to finish,
so sometimes you'd see an empty or partial image.

Bug 11131777

Change-Id: Ic64087322ce3bb15bb5f4fb1eb07579880fe6197
2013-10-09 16:38:02 -07:00
The Android Automerger
e0df32c9a7 merge in klp-release history after reset to klp-dev 2013-10-09 06:01:16 -07:00
Ed Heyl
98c197d826 merge in KQS81M 2013-10-08 15:40:38 -07:00
Jamie Gennis
faf77cce9d SurfaceFlinger: SW-based vsync events
This change adds the DispSync class, which models the hardware vsync event
times to allow vsync event callbacks to be done at an arbitrary phase offset
from the hardware vsync.  This can be used to reduce the minimum latency from
Choreographer wake-up to on-screen image presentation.

Bug: 10624956
Change-Id: I8c7a54ceacaa4d709726ed97b0dcae4093a7bdcf
2013-10-07 17:59:53 -07:00
The Android Automerger
38234af6bd merge in klp-release history after reset to klp-dev 2013-10-06 06:01:27 -07:00
Alex Ray
d457ec52d7 Add feature android.hardware.consumerir xml file
Bug: 10676690
Change-Id: I2cc62b9c97a71588c43ff96ca38d470976bde9b0
2013-10-03 13:09:37 -07:00
Marco Nelissen
48d3741ba5 Merge "Allow blaming a single uid for work done" into klp-dev 2013-10-03 16:34:51 +00:00
Lajos Molnar
b1f94ef3f9 Merge "media/hardware/HardwareAPI.h: Added PrepareForAdaptivePlaybackParams" into klp-dev 2013-10-03 16:10:25 +00:00
Marco Nelissen
9a7706bb17 Allow blaming a single uid for work done
This lets audioflinger assign blame for wakelocks to a single uid.
Currently this is only used for recording wakelocks.
b/10985160

Change-Id: Idc9adb22c29030010ac690d4cb95e7e7ea6b91e6
2013-10-03 08:49:07 -07:00