summaryrefslogtreecommitdiff
path: root/tools/aapt2/ResourceValues.cpp
diff options
context:
space:
mode:
author Riddle Hsu <riddlehsu@google.com> 2024-09-13 15:45:41 +0800
committer Riddle Hsu <riddlehsu@google.com> 2024-09-16 07:10:00 +0000
commitab6bbad80961d06caad3fe55b1a0fb48102ae2c5 (patch)
tree7ce7976cc35d8bb1a3a73824e84f41b7f271b701 /tools/aapt2/ResourceValues.cpp
parent32f087ff2bb97556f0cffa4da46f7c78f1d97f56 (diff)
Use a color container surface to animate rotation with wallpaper
By default, WallpaperService has a 0.05f dim. And SystemUI's DefaultDeviceEffectsApplier may set 0.6f for battery saver mode. If the wallpaper surface is not opaque, it may be blending with the surface behind. E.g. Before animation starts: z=1 Wallpaper 0.6 alpha z=0 No other layer (black) Animation starts: z=2 Wallpaper 0.6 alpha <--- looks brighter z=1 Bright (assume the content is light color) background layer Animation ends: (flickering when removing the background layer) z=2 Wallpaper 0.6 alpha z=0 No other layer (black) So wrap the surface which contains the wallpaper into a surface with color that will animate from background color to black, then the translucent wallpaper can have a smoother transition. Bug: 326331384 Flag: EXEMPT bugfix Test: Enable home rotation. Set a white color wallpaper. adb shell cmd battery unplug \ && adb shell settings put global low_power 1 (or "adb shell cmd wallpaper set-dim-amount 0.5") Rotate device. The end frame should not flickering from light to dark. Change-Id: Ie869abf59ecd59c976a503aee14880759f4b42e2
Diffstat (limited to 'tools/aapt2/ResourceValues.cpp')
0 files changed, 0 insertions, 0 deletions