I'm using a component in Android 10 and 11, on the Pixel 4a, that is setting the screen brightness thusly:
WindowManager.LayoutParams lp = window.getAttributes();
lp.screenBrightness = FREObjectUtils.getDouble( args[0] ).floatValue();
window.setAttributes( lp );
...and though it works, it takes about a second to drop from full to 0, or rise in reverse. The backlight basically "fades" in or out for a one second duration. I was expecting an immediate change. Can anyone advise if this is normal behavior, or if there's something I can set to allow for instantaneous screen brightness changes?