Earlier, on configuration errors, we simply drained the fences held
by current rotator objects and went to GPU comp. The rotator objects
were deleted in the subsequent rounds, if they remained unused.
If we don't use GPU comp on failure but use other strategies, then we
need to mark the rotator objects for a display for reuse, so that
other strategies can use them.
Also any failure resets on overlay or rotator need to happen from
functions that call configuration helpers rather than the helper
themselves. Leaving cleanup to black-box helpers is not desirable.
Change-Id: I59b5b1bb774b82ee85a037e934c9d2d023db30af
Restrict scissor rect within view frame boundary to avoid displaying
the layer content out of view frame boundary.
Change-Id: Iea19a4c4880a0c495d2f215e6cfd0eb41b65b785
1. Use viewframe of external display to compute Aspect ratio position
for external.
2. Use viewframe to find the crop rectangle of the frame buffer to
configure rotator for external orientation usecase.
Change-Id: I564c70f202176c8b1f707cbafc08cbbb2abde383
Add hw limitation checks for MDP composition once
we identify actual layers for MDP. This should be generic
way for all basic hw limitations of underlying MDP/MDSS.
Current limitations:
- a-family : MDP can not handle alpha scaling.
- 8226 & 8974 : Can not handle if multiple layers need
downscaling and blending
Change-Id: Ia944802d798f2d0e9cd4515d7e9854c7314cac78
CRs-fixed: 538803
When a rotator or mdp configuration for a display fails, reset the
layer-to-rotator mappings for that display and reset the release
fences for the rotator objects used for that display.
Note: The rotator itself is offline and not tied to any mixer. It is
from the mappings that we deduce which rotator object was used for
layers of which display. Also we don't delete rotator objects held
for a specific display, since during stability runs, failures could
repeat each round and we end up allocating and deallocating memory
unnecessarily. The rotator objects will be deleted automatically
when not required anymore.
Change-Id: I9a67f02574be30be3b96b3575f60530cb1c89e10
If a layer destination can be optimized, its source rect
needs to be cropped for the optimized destination rect.
Change-Id: If9a9891200d9cea52b58b253299b4007197cd9e5
For portrait videos case on WFD, driver supports multiplexing
of DMA pipe in LINE and BLOCK mode.
Loosen the requirements to allow DMA pipe in block mode for
portrait case of virtual display.
Change-Id: I5821501f89b17bb2d29c425aee0a6c16b2a4783b
To minimize usage of decimation when 4K x 2K video is played
on primary, split the yuv layer into 2 halves and configure
each layer to individual VG pipes. With this approach,
decimation can be avoided in some 4K x 2K video use cases,
thereby improving performance.
Change-Id: I7cddfab787c50f6ff132eaa7f5a3d9cfd636c282
1. Color layer has a destination rectangle, RGBA color and plane
alpha. There is no gralloc buffer. Layer flag "HWC_COLOR_FILL"
denotes a Color layer.
2. There is no color member in HWC layer, so RGBA color value
is passed via the "tranform" member from framework to HAL.
Change-Id: I8769fd3f5febcaf952a1456de0a4262679c9a0e4
Instead of trimming out of screen layer dimensions for various
operations repetitively, trim and store.
Will also prevent accidentally missing out on trimming.
Change-Id: I8800586070ec433aa1fcbb3aad73ec29c9c9111e
Seperate out rectangle deduction from the layer cropping. Update
layer sourceCrop and displayFrame after deducting the rect value.
This makes the function generic enough to be used by other
modules.
Change-Id: I587ac951357af823a1bf5e06c15ff47ac6a9c2a0
- Always use sourceCropF instead of sourceCrop.
- Change it to sourceCropF at places where sourceCrop
used
Change-Id: Ia64050a41a174f3f038c9b88d527d70c2240f2d9
Increment hwc version to 1.3.
Create and use a converter from float source crop to integers.
Change-Id: I5e185195c975b3a9434c5d9dce9ae4757ff98739
(cherry picked from commit 7e5637c850bcdbe21784ca3bfa9668870306adff)
during actionsafe calculations, if downscale on ext is enabled, we need
to consider the physical display attributes.
Change-Id: Ia07218b0b8e47b91b0bf575c66478ebaeab2e2a4
CRs-fixed: 569152
BWC is always enabled on primary for yuv use cases. This is a
workaround for issues surrounding transitioning from non-BWC
to BWC when HDMI/WFD is disconnected.
Change-Id: I6952ef5572f925ce59cbb91c85609c1ad3172703
Add support for load based partial mdp comp.
This is used on geometry changes where a redraw is unavoidable.
We select a batch of layers, that has minimum pixels for FB comp,
the rest go to MDP.
Conflicts:
libhwcomposer/hwc_utils.cpp
libhwcomposer/hwc_utils.h
Change-Id: Ifc5eeb4785c75c37de97a2bb89ca81409d324691
update the source video width and height set by the video decoder
for secure video smooth streaming usecase from metadata.
Change-Id: I73a3804d90557034604142481a232787dbc08f23
1.Framework notifies HAL with "HWC_FORMAT_RB_SWAP" layer flag to handle
a limitation where R and B components were swapped in Rendering phase.
2.Add "R/B swap" in hwc query to enable framework to query for support
in display HAL, at run-time.
Change-Id: I3b44d15b51b4f24939048fee9d1bac2b9009c97c
While marking layers for cache, neglect the z-order when
possible, to improve the scope of mixed mode usage.
It is safe to neglect the z-order if a static layer
doesn't have any overlapping region with updating layers
in between static layer & contiguous static layers batch.
- if above layer doesn't have any overlapping with updating
layer in middle, push it to the batch.
- If above case fails, but layers below(existing batch) does not
have any overlapping region with the updating layer, bring the
batch to top and modify fb-zorder accordingly.
Change-Id: I4882a750d0a9a2e11272fcbb146202160673d04f
- Identify secure display layer in the hwc_list
- Need to set both SECURE_OVERLAY and SECURE_DISPLAY flags for the secure
display layer
- Disable idle timeout for secure display usecase, as GPU should not be
accessing secure display layer
Change-Id: I555910db77c466b5e103b24b4f0ec7f47bb210a5
This change adds support in HWC for MDP partial update applicable
only for command mode panels. Presence of MDP FB (GRAM) in
command mode panels allows MDP clients to update only the updating region
of the frame as rest of the frame will be cached in the GRAM.
HWC calculates the updating region of a frame (ROI) by deducing
outer bounds of its updating layer destinations. Layers not lying
within the calculated ROI will be dropped from the composition
since its illegal to program MDP pipes for non participating layers.
Change-Id: I890d98ff7960fe888787981803cac62f68471201
With in hwc list of layers if a layer above is opaque,
deduct the opaque layers crops from all the layers below
in z-order if deduction is possible with out creating
any hole.
Change-Id: I6391a13b0501cb972b134f72b58514cb807c7613
Stub implementation of VPU in HWC.
This commit passes through binder calls from HWC
to the VPU library. It also has stub prepare/draw calls
in the VPU client object which can be used to configure
VPU in the composition cycle.
Change-Id: I2606f2884e870448d29ef26e02faac92e157e2c6
- needsScaling does not check for scaling required in left & right
mixers when the crop values are sanitized. So it leads to issue
if DMA pipes are picked-up as high resolution layer does not need
scaling but left or right mixer configuration needs scaling after
the split.
- needsScalingWithSplit takes care of this with checking for the
sanitized cropped values.
Change-Id: I1f5b1952a59a84f5ccbaef123251b3c8cd46e4dd
Writeback for assertive display feature is needed only for
split displays and only if ro.qcom.ad is set to 2 by OEM.
This patch removes the unnecessary code and adds the relevant
conditional checks for split displays and property value
Change-Id: Ic36f28441d1a6e93132316b33fe1cf98a6e1efe4
A display could be split if its dimensions exceed 2048 or in case
of primary if we make it so via device tree property.
Add an API to find if a display is split. Use this API instead of
going through a set of conditions in various use cases.
Rename the HighRes, LowRes objects to a more appropriate Split and
NonSplit respectively
Change-Id: Id847c2bf36ea9250e1cdbc0259fdec64bd124537
For split source crop of YUV ensure that Left and Width
(thus Right) of each crop is even.
For split source crop of RGB and YUV ensure that Crops have
no gaps (i.e right of left-crop = left of right-crop)
Enable overfetch of pixels in the center, for split layers,
to get a smooth upscale
Change-Id: I8e4a91b637c840f75742580645c6468b5769432d
Enable sync-pt for rotator on B-family. The already existing
MSMFB_BUF_SYNC ioctl is used, with an extra member for session_id
from rotator.
Change-Id: Ib0ef6b1bc5cf1e6437090a217d7f731a3440f84b