summaryrefslogtreecommitdiffstats
path: root/services
Commit message (Collapse)AuthorAgeFilesLines
* Virtual Display async mode is overriddenJohn Dong2014-02-211-10/+10
| | | | | | | | | | | | Virtual Display async setting is overridden by eglApi.c causing stall during composition. Set the async mode after eglCreateWindowSurface() b/13139121 Change-Id: I336ca145552e387217cd8bea6e4b7f5f490a274d Signed-off-by: Pierre Couillaud <pierre@broadcom.com>
* surfaceflinger: add BoardConfig.mk variable to force 32-bitColin Cross2014-02-201-0/+4
| | | | | | | Individual devices may need to force surfaceflinger to compile for 32-bit if they don't have 64-bit GL libraries. Change-Id: I3703b2f8e36e90cf125d9ed5e6318c3506861948
* SurfaceFlinger: mFbProducerSlot initailizationmayank parshar2014-01-281-0/+1
| | | | | | | | | | | | | | | | b/12487813 SurfaceFlinger crash is observed during simulation of Secondary display Note: change 14e8b01a761180250671f3d6494532d8bd04fa8e removed the initialization leading to the crash when simulating secondary display. Restore the initialization to solve the problem. Change-Id: Iae5845fb82735e01de5cc0dc582d13c27e3c614f Signed-off-by: mayank parshar <mayankp@broadcom.com> Signed-off-by: Pierre Couillaud <pierre@broadcom.com>
* SurfaceFlinger: mFbFence initializationmayank parshar2014-01-251-0/+1
| | | | | | | | | | | | | | | | | MobC00383030 b/12487813 SurfaceFlinger crash is observed while connecting to Wi-Fi display. Note: change 14e8b01a761180250671f3d6494532d8bd04fa8e removed the initialization leading to the crash when running through the HWC composition path. Restore the initialization to solve the problem. Change-Id: I581defc7135ac512080c0da06a62b1dae7d218c4 Signed-off-by: mayank parshar <mayankp@broadcom.com> Signed-off-by: Pierre Couillaud <pierre@broadcom.com>
* Implement per-display EGLConfig and configless EGLContextJesse Hall2013-12-236-14/+58
| | | | | | Bug: 12230666 Change-Id: Icca608b108cbdcab9cf01a9236d8cdbda000a836 Signed-off-by: Jesse Hall <jessehall@google.com>
* Move EGLConfig selection to RenderEngineJesse Hall2013-12-234-177/+178
| | | | | | Bug: 12230666 Change-Id: I8d1111a7e0fd9d9e2525e6a80da8ce46d7dd085d Signed-off-by: Jesse Hall <jessehall@google.com>
* Track Looper decoupling from ALooperBrian Carlstrom2013-12-121-6/+6
| | | | Change-Id: I612f0de7002e24948a4cbbea7b416b4fbb3929aa
* Don't change the framebuffer target until we render a new oneJesse Hall2013-11-071-12/+10
| | | | | | | | | Continuing to send the last-rendered framebuffer to HWC on subsequent frames allows the HWC to read partially-composed regions that haven't changed, instead of re-composing from scratch. Bug: 11573910 Change-Id: I8829877d2a06001f1e1b3f168cbba71c7b217b2d
* Merge "Provide virtual display output buffer to HWC in prepare" into klp-devJesse Hall2013-11-071-1/+1
|\
| * Provide virtual display output buffer to HWC in prepareJesse Hall2013-11-051-1/+1
| | | | | | | | | | | | | | | | We were already making sure the HWComposer class had the handle before prepare, but it wasn't passing the handle along to HWC as intended. Partial fix for bug: 11430248 Change-Id: I25f672c4fdfaa6a81fe0acb24d9ad05153ee17dc
* | Merge "Don't use implementation-defined format with CPU consumers" into klp-devJesse Hall2013-11-062-7/+24
|\ \ | |/ |/|
| * Don't use implementation-defined format with CPU consumersJesse Hall2013-11-042-7/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* | DispSync: remove delay when enabling vsync eventsJamie Gennis2013-11-011-1/+8
|/ | | | | | | | | | This change fixes a bug that caused an extra frame of latency when enabling vsync event callbacks in DispSync. The bug was related to the logic that prevents the two events from firing with very little time between them due to updates to the vsync model. Bug: 11479720 Change-Id: Ie7eaff9e92ffb7b7b6cb4d3d4402c96cbd29af7e
* Merge "Bug fixes for SensorService" into klp-devAravind Akella2013-10-252-1/+12
|\
| * Bug fixes for SensorServiceAravind Akella2013-10-252-1/+12
| | | | | | | | | | | | | | | | | | 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
* | Native counterpart of new power manager methodMarco Nelissen2013-10-251-0/+11
| | | | | | | | | | | | | | | | Cherrypicked from master. b/9464621 Change-Id: I54c0ed50a57ac870da91db8589a73a2c792dbd8d
* | Fix handling of undefined TARGET_FORCE_HWC_FOR_VIRTUAL_DISPLAYSJesse Hall2013-10-252-5/+7
| | | | | | | | | | related to b/8316155 - Implement HWComposer 1.3 w/ virtual display support Change-Id: I2dc8d65a74174aa833cc491264f97f1f2df49307
* | Add a boardconfig to force HWC composition of virtual displaysNaseer Ahmed2013-10-172-0/+20
| | | | | | | | | | | | | | | | | | | | | | 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
* | Use implementation-defined format when HWC writes to output bufferJesse Hall2013-10-172-15/+42
|/ | | | | | | | | | | 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
* SurfaceFlinger: give SF its own vsync phaseJamie Gennis2013-10-153-6/+30
| | | | | | | | This change allows SurfaceFlinger to run at a different vsync phase offset from that used by external listeners. Bug: 11175503 Change-Id: I561c53a5659fa6dc1e3e4ae30340f3c1a6adceb4
* SurfaceFlinger: Add EventControlThreadJamie Gennis2013-10-155-10/+131
| | | | | | | | | | 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
* Merge "Disable hardware vsync when blanking the screen" into klp-devJesse Hall2013-10-152-8/+22
|\
| * Disable hardware vsync when blanking the screenJesse Hall2013-10-142-8/+22
| | | | | | | | | | Bug: 11220224 Change-Id: I99d0a42e1a6bb0aaf89706f6d100e9ef2a5deaa4
* | Merge "SensorService Flush API bug fix." into klp-devAravind Akella2013-10-152-34/+19
|\ \ | |/ |/|
| * SensorService Flush API bug fix.Aravind Akella2013-10-142-34/+19
| | | | | | | | | | | | SensorService is dead locking itself when flush is called on older devices which don't support batching. mConnectionLock is acquired twice. Change-Id: I5c25585bfb2b396df4b05826a9cba1da7997a3ee
* | Filter out vsync events from HWC with duplicate timestampsJesse Hall2013-10-141-2/+16
|/ | | | | Bug: 11220224 Change-Id: I4efe0b66ea8969bf0ec3c4fcb325d354c8a0c315
* Merge "DispSync: don't compensate for wakeup latency" into klp-devJesse Hall2013-10-131-2/+2
|\
| * DispSync: don't compensate for wakeup latencyJamie Gennis2013-10-091-2/+2
| | | | | | | | | | | | | | | | | | 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
* | Merge "Use black for blackout layer" into klp-devAndy McFadden2013-10-112-2/+2
|\ \
| * | Use black for blackout layerAndy McFadden2013-10-112-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* | | Merge "Change API from flush(handle) to flush(). Call flush on all active ↵Aravind Akella2013-10-112-5/+19
|\ \ \ | | | | | | | | | | | | sensors in the given SensorEventConnection." into klp-dev
| * | | Change API from flush(handle) to flush(). Call flush on all active sensors ↵Aravind Akella2013-10-092-5/+19
| | | | | | | | | | | | | | | | | | | | | | | | in the given SensorEventConnection. Change-Id: I4ef2bec80406c517903ab9782dc9eaf3fa8b7f36
* | | | Merge "Wake up disp sync thread when setting display period" into klp-devJesse Hall2013-10-101-0/+1
|\ \ \ \ | |_|/ / |/| | |
| * | | Wake up disp sync thread when setting display periodJesse Hall2013-10-101-0/+1
| | |/ | |/| | | | | | | | | | Bug: 10624956 Change-Id: I272c15f319521bfbd1bb70451366c7dd84d60bf9
* | | Fix blank / partial screenshotsAndy McFadden2013-10-091-0/+21
|/ / | | | | | | | | | | | | | | | | 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
* | SurfaceFlinger: SW-based vsync eventsJamie Gennis2013-10-078-41/+863
|/ | | | | | | | | | 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
* Merge "Allow blaming a single uid for work done" into klp-devMarco Nelissen2013-10-031-1/+16
|\
| * Allow blaming a single uid for work doneMarco Nelissen2013-10-031-1/+16
| | | | | | | | | | | | | | | | This lets audioflinger assign blame for wakelocks to a single uid. Currently this is only used for recording wakelocks. b/10985160 Change-Id: Idc9adb22c29030010ac690d4cb95e7e7ea6b91e6
* | Merge "only clear FB when asked for the opaque layer" into klp-devDave Burke2013-10-021-1/+2
|\ \
| * | only clear FB when asked for the opaque layerMathias Agopian2013-10-011-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | a layer need to be considered NOT opaque if it has a plane-alpha. Bug: 10846930 Change-Id: Ibd8981b63ede4560c7096bacc4cff46a7eb2a8bb
* | | Merge "Treat composition frames with no layers as using GLES composition" ↵Jesse Hall2013-10-022-1/+10
|\ \ \ | | | | | | | | | | | | into klp-dev
| * | | Treat composition frames with no layers as using GLES compositionJesse Hall2013-09-302-1/+10
| | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When there are no window layers for a display, SurfaceFlinger clears the undefined region using GLES. Some of the places that check for GLES composition weren't considering this special case, in particular: - We were skipping the eglSwapBuffers() on these frames. - We were putting VirtualDisplaySurface in HWC-only composition mode. This change centralizes the logic for this special case. Bug: 10957068 Change-Id: I2deaf2ed101e8ea76708862a6bb67751b6078794
* | | Set the outbuf acquire fence after we actually have it.Jesse Hall2013-10-011-1/+9
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | In GLES-only mode, we don't have the outbuf acquire fence until after GLES composition is done for the frame. We were setting the fence in HWC's state immediately after dequeueing the buffer from the consumer, before GLES had started. This fence got passed through HWC and on to the consumer, so the consumer was reading the buffer before GLES was done writing to it. Now we update HWC's state just before set(), when we know we have the right fence. Bug: 11000763 Change-Id: Iea9db4c69634c352dc2d600f0bdb6bef2a432636
* | Fix two EGLConfig selection bugsJesse Hall2013-09-302-23/+20
|/ | | | | | | | | | | | | | This fixes two bugs introduced by Change-Id: Ia8cc084c02a0e3de910def024da8a08d02bbd89d (a) There is no invalid EGLConfig value, in particular zero is valid. Checking return values of eglGetConfigs and eglChooseConfig is the only way to determine success. (b) The "simple" EGLConfig query used as the emulator fallback should not include EGL_RECORDABLE; the emulator doesn't have it. Bug: 10935622 Change-Id: Ib798a24e7cf06a679811c46eaa45d39174a715ec
* Merge "fix initialization of framebuffer target crop rect on hwc 1.3" into ↵Mathias Agopian2013-09-261-1/+8
|\ | | | | | | klp-dev
| * fix initialization of framebuffer target crop rect on hwc 1.3Mathias Agopian2013-09-251-1/+8
| | | | | | | | | | Bug: 10936771 Change-Id: If283e5e231ca34b93e0b1784bb4e8e4c7bfd75de
* | fix crashers with wifi/virtual displaysMathias Agopian2013-09-252-0/+17
|/ | | | | Bug: 10647742 Change-Id: I4b8ed9da52ef95af3a3b3a04b98514a3776a674d
* reinstate black-screenshot debugging codeMathias Agopian2013-09-194-9/+20
| | | | | | | turned off by default. Bug: 10809349 Change-Id: I3e6b8c7860e6b0e122b8f07de4020967cd1f005c
* Fix GLES context version selectionMathias Agopian2013-09-183-36/+61
| | | | | | | | Explicitly selects an ES 2.0 config first, then an ES 1.x config, before attempting the fallback path for the emulator. Bug: 10820214 Change-Id: Ia8cc084c02a0e3de910def024da8a08d02bbd89d
* fix camera API 2.0 orientationMathias Agopian2013-09-175-2/+87
| | | | | | | | | we add a flag to ANativeWindow::setBufferTransform that means "apply the inverse rotation of the display this buffer is displayed onto to". Bug: 10804238 Change-Id: Id2447676271950463e8dbcef1b95935c5c3f32b2