this would happen when the composition was handled
entirely in h/w composer, in this case, we would
not set the fences for any involved layers.
Bug: 7049373
Change-Id: I1439dc156ce23c24041cdfbbebfe8ff4fdf790f8
This change is a clean up of some of the handling of the maximum number of
buffers that are allowed at once. It mostly renames a few member variables and
methods, but it includes a couple small refactorings.
Change-Id: I9959310f563d09583548d4291e1050a7bbc7d87d
this happened because we didn't check that the visible
region was within the bounds of the display.
Bug: 7064121
Change-Id: I2e81850a3dc3d1474253520ad7f9e559c26d5a96
DisplayDevices are now keyed of the wp<IBinder> the client uses.
DisplayID has now become DisplayType which is just used to identify
physical displays (as opposed to virtual displays such as wifi displays).
Change-Id: I0c5968f2c902dcd699a7e0afacf833ff070c12ea
Use only display tokens in the API to refer to new displays.
Don't require the caller to specify the display when creating
a surface (since in general a surface could be shown on
any display).
This is intended to be a minimum change just to update the API.
Note that SurfaceFlinger still uses DisplayID in a few places
internally that might cause some features not to work properly
when there are multiple displays (LayerScreenshot, for example).
Change-Id: I3d91eec2da406eefd97bcd53655d403ad865a7e6
The primary display device was being configured to "blank" by
default, which prevented the boot animation from appearing
(unless you got lucky with the hardware composer state).
Bug 6975688
Change-Id: I0fa52e9e719c6e997c5725a7baf15d9718461b78
The primary display device was being configured to "blank" by
default, which prevented the boot animation from appearing
(unless you got lucky with the hardware composer state).
Bug 6975688
(This reverts an earlier revert.)
HWComposer can now create IDs representing a display
it can deal with. IDs MAIN and HDMI are reserved.
SurfaceFlinger associate HWComposer IDs with a
DisplayDevice and uses that when it talks to HWComposer.
A DisplayDevice doesn't have to have a HWComposer ID,
in that case it just can't use h/w composer composition.
Change-Id: Iec3d7ac92e0c22bf975052ae2847402f58bade71
- we now clean-up "dead" connection in the main loop,
this entirely avoid the problem with the side effects of
releasing strong references. We now only hold on to strong
reference for the connection we will signal.
- also simplify how we build the list of "ready" connections, by
only adding them to the list when we did receive a vsync event
Change-Id: I2a84da431320a2af8e8a93e07622a1d258236f43
The primary display device was being configured to "blank" by
default, which prevented the boot animation from appearing
(unless you got lucky with the hardware composer state).
Bug 6975688
Change-Id: Idaa0d0b98ebb331a17d1b16774c6b05bfa1e8728
- one issues caused most timestamps to be reported as 0
- on rare occasions an uninitialized variable could be used
- vsync counts per connection were accessed unthreadsafely
we now have 2 lists of connections in the main loop, one just
keeps a list of strong refs to the connections because once
we have a strong ref we're not allowed to release it while
holding the lock.
the 2nd list holds the connections that have a vsync event to
be reported. all the calculations are made with the lock held.
Change-Id: Iacfad3745b05df79d9ece3719bd4c34ddbfd5b83
problem was that we were acquiring a strong reference
on Connection object with a lock held, when those
got out of scope (lock still held) their dtor
could be called if all other refs had dropped,
the dtor would acquire the lock again to
remove the Connection from the main list. boom.
we rearange the code so this doesn't happen.
Bug: 6942208
Change-Id: I0a0ebabce2842d29d60d645b64aac2f26640e59b
when multiple displays are connected, we ended-up having to
call eglMakeCurrent() twice per display due to a limitation
in EGL. this fixes that.
Change-Id: I11e4584df50f8c24bbecee74e37b28b3ee031d2f
fix a few bugs with external displays
- HWComposer doesn't really handle multiple displays yet
so there is a lot of ugliness there
- We also need to make sure that external displays are not
blanked by default
- due to some EGL limitations surfaces being swapped need
to be current
Change-Id: I82bff05b43bcebd8da863c7c76b4edbc3bc223a9
due to a typo, SF's main transaction was conditional to having a
display transaction.
more correct fix for 6970310
Bug: 6970310
Change-Id: Iafd8c4e02afa5db829cc1c65950cfcc74754c6af
Layers were not properly being removed because we were
setting the wrong transaction type flag at the time of
removal.
When layers are removed, we must use eDisplayTransactionNeeded,
not eTransactionNeeded, to ensure that the mLayersRemoved
flag is checked and the appropriate cleanup occurs.
Bug: 6970310
Change-Id: Id4b2897a34d4ac00aa0f92349c0ec6db95c1aaf7
- displays are represented by a binder on the client side
- c++ clients can now create and modify displays
Change-Id: I203ea5b4beae0819d742ec5171c27568f4e8354b
once a secure window is put on screen the display
would retain its "secure" flag forever, preventing
screenshots from being taken.
Bug: 6933967
Change-Id: I5be8355145ca7d580d84552311642f8fa912fe6a
- also replace C casts with C++ casts
- only the interface is changed, HWComposer still doesn't
fully handle multiple displays
Change-Id: I48eb89bff2edb76bf1d4d41f46802b9b2a7166a8
This change refactors the FramebufferSurface class to inherit from the new
ConsumerBase class.
Bug: 6620200
Change-Id: I46ec942ddb019658e3c5e79465548b171b2261f2
it's safer this way because this object owns an
EGLSurface which cannot be easily reference-counted.
it also gives us the ability to sub-class it, which
we might want to do soon.
Change-Id: I07358bb052dc5a13b4f2196b2c2b6e6e94c4bb4f