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

Skip to content
Commit 191b877e authored by Leon Scroggins III's avatar Leon Scroggins III
Browse files

Improve printing of Display- and Layer- Settings

In order to add any shaders to our cache warming code, we need to look
at the logcat to see what settings created a particular shader. Update
the PrintTo methods to be simpler and provide more information.

Add fields that were missing from operator==, and add operator!= where
necessary.

Add tests for the missing fields.

LayerSettings:
- If a matrix is Identity, simply print "I". This cuts down on a lot of
  noise. Do the same for DisplaySettings.
- Similarly, if the ShadowSettings or StretchEffect is the default, skip
  it.
- PixelSource: only print the Buffer OR the SolidColor; only one is
  respected anyway.
- Reorder printing to line up with the order of declaration.
- Remove 'Defining PrintTo helps with Google Tests.' This method is more
  generally useful.

SkiaGLRenderEngine:
- Set kFlushAfterEveryLayer to kPrintLayerSettings. These are
  compile-time constants, and they're typically modified together.
- The LayerSettings include several lines of text. Instead of splitting
  them up at an arbitrary boundary, splitting words, break them up based
  on the newline character. This makes the logs much easier to read.
- Move this into a common function so that we can also print the
  DisplaySettings, which may impact what shaders are compiled.

Bug: 190487656
Bug: 222355787
Test: perfetto
Test: LayerSettingsTest and DisplaySettingsTest
Change-Id: Ifc464779ed368d2edad7fc6adab53e9b368fd7cb
parent c8c33325
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