1. Enable composition bypass for 1 or 2 non-overlapping layers.
2. Open bypass only if video playback status is CLOSED.
3. Close bypass immediately if Video or Camera needs VG pipe.
Change-Id: I1bef030b32ff2721d00b61f7717027d4d9219d04
This change enables c2d composition in HWC by removing the temporary
flag added in the following commit:
commit 7b814382ad
Change-Id: Ia6705c369090b14f3a00678c4e82078bd6e58847
-- Enable HWC
-- handle overlay as lib rather than HAL
-- move copybit changes under COPYBIT_ENABLE flag (temporary)
Change-Id: I36d8f9688cd7cbd838e288e5f482d8ee5c9b2df6
Allow 1 or 2 non overlapping layers to use composition bypass.
This is an enhancement to the previous approach which uses
bypass strictly for 2 layers.
Change-Id: I879903db44cb1fddbe3e428ffa77eb67e95e0886
Close overlay channels in the next HWC set phase. This allows the
framebuffer to be composed prior to the closing of channels.
CRs-fixed: 305070
Change-Id: I8719381136c20c0febbd4f7bf5b935b92f6508ec
When composing UI along with video, enable the overlay NOWAIT option.
If there is no UI during overlay playback, use the WAIT flag.
Change-Id: Idc538e4412c790fc295a3aff1d1f23a6e4767fce
Update the overlay when we have a channel up. Previously, we did updates
only when the width and height changed. Now, we always update the overlay
when the channel is open, and not close the channel to update parameters
such as orientation change, flags etc.
Change-Id: I0b2ef8b19bd860d5361c391e040ff497f1023ae3
Bypass composition if we have 2 visible layers. However, this feature
is not used if:
1) Video playback is on
2) Rotation involved
3) App launch animation
4) HDMI connected
Set property debug.compbypass.enable=1 in build.prop
to enable this feature.
Change-Id: I4c0fa2aa1999c06c51f2b9a58641203316896e53
prepareOverlay will setup the channels for video playback, so
inform gralloc to close UI channels before they are setup.
Change-Id: I757a8fd79661eb66ccbe2ac1475e48740bbf1733
CRs-fixed: 298102
Create a new function to check if we need to skip the composition
during overlay operations.
Reset the previous compCount variable if there is no video layer present.
Change-Id: Ibf570805114440f117f0fb98b5f2d53c1780ec84
CRs-fixed: 298014
Put HDMI code in HWC under compile time flag.
This prevents crashes in use cases like HDMI used as primary.
If not done, non-existing code in gralloc is called in that
use case.
Change-Id: Ic7e792acf0c35eb12f04a74405619385d7288991
The overlay_buffer_info buffer geometry and size. When calling the
overlay from the gralloc or hardware composer, populate this structure
with the information from the gralloc handle.
(cherry picked from commit 128adc3b8177ef72f2bf21f4022d7ef06ed9281b)
Change-Id: I2f60f691ac01e67f150c753f168be754b14f94e6
Separate overlay setup and overlay play.
On setup failure, mark the layer to use C2D if enabled.
Else mark the layer to use GPU.
CRs-fixed: 292398
(cherry picked from commit b1459b0b1106ed66810b1c5a09878fae353c123c)
Change-Id: Id4c27384193612ab13e87d18492b0fef662eb8b4
If SurfaceFlinger marks a layer with the HWC_DO_NOT_USE_OVERLAY
flag, do not use the overlay to draw the layer
(cherry picked from commit 9271a839b6bbbdc7b22bd7f1dca6f4c0c63de965)
Change-Id: Ie44586a1254a2dc2ad41ae902debc5bb442cbfde
If we have only one overlay layer, and the rest of the layers
are not updating, set the HWC_SKIP_COMPOSITION flag to inform
SurfaceFlinger not to compose anything. Also skip the drawing of
any UI frames and swapping the buffers.
Change-Id: I2f6554c905756a08880cba531c0210a58396179b
CRs-fixed: 289477
If the layer blending has been disabled, disable copybit alpha so
that copybit does not perform any blend operation.
Change-Id: I9a83fad0f126adaf9540bc72d17e7dcb1c55cd0f
CRs-fixed: 288527
- Inform the gralloc of the HDMI status.
- If the HDMI is disconnected, close the overlay and also inform the
gralloc that video mirroring has stopped.
Change-Id: Ie89ffe860c0f9c9142d6c7f5d7a6c555884561ce
CRs-fixed: 286954
Whenever there is a change in the buffer geometry, set a flag in the
gralloc handle stating that the buffer geometry has changed.
In the HWC, whenever we encounter an update in the geometry, if the
channel is already open, we just call the necessary ioctls to update
the overlay information and not unnecessarily open/close channels.
Change-Id: I27db8fc497ebc514e262d6b7854739f312644714
When the layer flags are marked to maintain the original surface
resolution, draw the layer using the overlay.
Store the HDMI status in the overlay object instead of the HWC
context.
Set the correct parameters for the source and destination rectangles
when drawing the layer using copybit.
Change-Id: I6ab7e2b5ba7b457a5bc604fd3a0031e6bada82cb
SurfaceFlinger calls a hwc_set with a NULL context and
list when it is releasing the HWC. Check the validity
of the pointers before using it.
Change-Id: I5b61cc50a85b9b660646789b2cf9a0f4ee6e4a5c
Enable video on HDMI when cable is connected.
Inform gralloc module when video playback starts and stops.
Change-Id: Icc2a1b62fcd8cf75c1be98d88c3fa4dc49ef0278
Initial HWC changes
- Add support to recognize video/camera buffers in the prepare phase
- Use overlays to draw single video/camera layers
Change-Id: I3351b3172fae12d9f6e016ff7e1a2f6a476799b3