Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 745dcaac authored by Leon Scroggins III's avatar Leon Scroggins III
Browse files

Pass display's colorTransform to RE even if HW handles it

Even if the DPU handles the colorTransform, RE needs to know about it
for A8 screen decorations layers. So pass the colorTransform to RE
always. Add a new boolean, specifying whether the DPU handles it, so
existing use cases can continue to ignore it.

RE uses a color matrix to turn transparent pixels in the A8 screen
decorations layer to black, providing antialiasing. If the DPU handles
the colorTransform, that black will then be converted to another color
(e.g. white, if the colorTransform comes from the "Color inversion"
accesibility feature). So RE needs to convert it to a color that the DPU
will then convert back to black, matching plastic next to the screen. Do
this by inverting the upper left 3x3 of the matrix and applying it to
black. If the color matrix is not invertible (note that the one used for
"Color inversion" *is*), leave black unchanged.

If the DPU does not handle the colorTransform, concat the A8 layer's
color matrix with the colorTransform.

Update libcompositionengine_test to use the proper colorTransform.

Add GTEST_SKIP if R8 buffers are not supported (follow-up from
I340de485fd62bea12a5a097f09073c4f7d58fa90).

Bug: 215706351
Bug: 216178319
Test: librenderengine_test
Test: libcompositionengine_test
Test: manual

Change-Id: Ib127620be4e5fc400ac2525c90dea1b9a29bd1f7
parent e7c51c66
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment