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
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
This lets audioflinger assign blame for wakelocks to a single uid.
Currently this is only used for recording wakelocks.
b/10985160
Change-Id: Idc9adb22c29030010ac690d4cb95e7e7ea6b91e6
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
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
This change makes GLConsumer use the EGL_ANDROID_image_crop extension when
available on a device. The crop rectangle is passed to the EGL driver when
creating EGLImages, allowing the crop to be performed by the driver rather than
using the texture transform matrix.
Bug: 10897141
Change-Id: I63e9a5d5c85067376abc420e3639154468346311
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
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
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
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